+ location_enable(what);
+ return;
+ }
+ if ( locationnum == -3 ) { //service address location for qualificaitons
+ what.form.address1.value = <% $cust_location->address1 |js_string %>;
+ what.form.address2.value = <% $cust_location->address2 |js_string %>;
+ what.form.city.value = <% $cust_location->city |js_string %>;
+ what.form.zip.value = <% $cust_location->zip |js_string %>;
+% if ( $opt{'alt_format'} ) {
+ what.form.location_number.value = <% $cust_location->location_number |js_string %>;
+ changeSelect(what.form.location_kind, <% $cust_location->location_kind |js_string %> );
+ changeSelect(what.form.location_type, <% $cust_location->location_type |js_string %> );
+% }
+
+ changeSelect(what.form.country, <% $cust_location->country | js_string %> );
+
+ country_changed( what.form.country,
+ fix_state_factory( <% $cust_location->state | js_string %>,
+ <% $cust_location->county | js_string %>
+ )
+ );
+ location_enable(what);
+ return;
+ }
+
+ if ( locationnum == 0 ) { //(default service address)
+% if ( $cust_main ) {
+ what.form.address1.value = <% $cust_main->get($prefix.'address1') |js_string %>;
+ what.form.address2.value = <% $cust_main->get($prefix.'address2') |js_string %>;
+ what.form.city.value = <% $cust_main->get($prefix.'city') |js_string %>;
+ what.form.zip.value = <% $cust_main->get($prefix.'zip') |js_string %>;
+
+ changeSelect(what.form.country, <% $cust_main->get($prefix.'country') | js_string %> );
+
+ country_changed( what.form.country,
+ fix_state_factory( <% $cust_main->get($prefix.'state') | js_string %>,
+ <% $cust_main->get($prefix.'county') | js_string %>
+ )
+ );
+% }
+