{ field => 'confirmed',
type => 'hidden',
},
+ { field => 'received',
+ type => 'hidden',
+ },
+ { field => 'submitted',
+ type => 'hidden',
+ },
{ field => 'stock_or_customer',
type => 'radio',
options => [ 'Stock', 'Customer', ],
'name' => 'Bulk DID Order',
'field_callback' => $field_callback,
'html_bottom' => $javascript,
+ 'body_etc' => 'onLoad="stockcust_changed()"',
)
%>
<%init>
my($cgi, $object) = @_;
#process_o2m fields in process/did_order.html
- my @fields = qw( msa npa latanum ratecenter state quantity );
+ my @fields = qw( msanum npa latanum ratecenternum state quantity );
my @gfields = ( '', map "_$_", @fields );
map {
if ( f.stock_or_customer_Stock.checked ) {
custnum_search.disabled = true;
custnum_select.disabled = true;
+ custnum.value = '';
}
else if ( f.stock_or_customer_Customer.checked ) {
custnum_search.disabled = false;
custnum_select.disabled = false;
}
- custnum.value = '';
- custnum_search.value = '';
+ }
+
+ /* o2m or something else is broken, can't put this in the actual
+ component because random JS and other crap is rendered
+ onto the final output page */
+ function ratecenter_changed(rc) {
+ var idbase = rc.id.substring(0,rc.id.indexOf('_'));
+ var div = document.getElementById(idbase+'_rc_div');
+ var input = document.getElementById(idbase+'_rc_new');
+ if(rc.options[rc.selectedIndex].value == '0') {
+ div.style.display = 'inline';
+ }
+ else {
+ div.style.display = 'none';
+ }
+ input.value = '';
}
</SCRIPT>
END