X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=httemplate%2Felements%2Ftr-select-cust_location.html;h=7ffbd6c14a53720f2b806616379d94a577593a91;hb=468c9e660eb0edb2033f0f8dbb4458f20280082c;hp=b804f4548bfd96864359d3aa4d52b521332da32b;hpb=7acc76e0ead0d88cb225c88016c778c8feb9a075;p=freeside.git diff --git a/httemplate/elements/tr-select-cust_location.html b/httemplate/elements/tr-select-cust_location.html index b804f4548..7ffbd6c14 100644 --- a/httemplate/elements/tr-select-cust_location.html +++ b/httemplate/elements/tr-select-cust_location.html @@ -52,10 +52,11 @@ Example: if( ftype != 'SELECT') what.form.<%$_%>.style.backgroundColor = '#ffffff'; % } % if ( $opt{'alt_format'} ) { - if ( what.form.location_type.options[what.form.location_type.selectedIndex].value ) { + if ( what.form.location_type && + what.form.location_type.options[what.form.location_type.selectedIndex].value ) { what.form.location_number.disabled = false; what.form.location_number.style.backgroundColor = '#ffffff'; - } + } % } } @@ -281,6 +282,8 @@ if ( $locationnum && $locationnum > 0 ) { } } +$cust_location->coord_auto('Y'); + my $location_sort = sub { $a->country cmp $b->country or lc($a->city) cmp lc($b->city)