X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=httemplate%2Fedit%2Felements%2Fpart_export%2Fbroadband_snmp.html;h=b4d57edd50647a1a501aae134661c397ff031ed1;hb=3a02a1bce4190ce0d94883709e0a6c362bcb0af3;hp=4c0367c5a0e3865fa8c726e2ef7c4d0edc5fffb0;hpb=3d0a1bb06b895c5be6e3f0517d355442a6b1e125;p=freeside.git diff --git a/httemplate/edit/elements/part_export/broadband_snmp.html b/httemplate/edit/elements/part_export/broadband_snmp.html index 4c0367c5a..b4d57edd5 100644 --- a/httemplate/edit/elements/part_export/broadband_snmp.html +++ b/httemplate/edit/elements/part_export/broadband_snmp.html @@ -11,7 +11,7 @@ <& /elements/tr-input-text.html, label => 'Community', field => 'community', - curr_value => $part_export->option('community'), + curr_value => $part_export->option('community') || $opt{'export_info'}->{'options'}->{'community'}->{'default'}, &> <& /elements/tr-checkbox.html, label => 'Send IP address changes to new address', @@ -29,8 +29,8 @@ function open_select_mib(obj) { nd(1); // if there's already one open, close it var rownum = obj.rownum; - var curr_oid = obj.value || ''; - var url = '<%$fsurl%>/elements/select-mib-popup.html?' + + var curr_oid = obj.form.elements['oid' + rownum].value || ''; + var url = '<%$fsurl%>misc/select-mib-popup.html?' + 'callback=receive_mib;' + 'arg=' + rownum + ';curr_value=' + curr_oid; @@ -45,8 +45,10 @@ function open_select_mib(obj) { function receive_mib(obj, rownum) { //console.log(JSON.stringify(obj)); // we don't really need the numeric OID or any of the other properties - document.getElementById('oid'+rownum).value = obj.fullname; + var oidfield = document.getElementById('oid'+rownum); + oidfield.value = obj.fullname; document.getElementById('datatype'+rownum).value = obj.type; + oidfield.onchange(); //should be same as datatype, only need to run one } @@ -66,10 +68,11 @@ function receive_mib(obj, rownum) { - + + - +