diff options
author | Jonathan Prykop <jonathan@freeside.biz> | 2015-06-30 03:24:08 -0500 |
---|---|---|
committer | Jonathan Prykop <jonathan@freeside.biz> | 2015-07-02 00:26:11 -0500 |
commit | 7a7cbbf2d1afbbfb90c409b98ffa579e61dd865b (patch) | |
tree | 8ce86143cc537a7d4cc19dc485e39704cb233356 /httemplate/elements/standardize_locations.js | |
parent | efcf47213599cf4da16c390dccdf26b2473edaf3 (diff) |
RT#29285: State field not needed for New Zealand
Diffstat (limited to 'httemplate/elements/standardize_locations.js')
-rw-r--r-- | httemplate/elements/standardize_locations.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/httemplate/elements/standardize_locations.js b/httemplate/elements/standardize_locations.js index ff7183b26..1a01daa6f 100644 --- a/httemplate/elements/standardize_locations.js +++ b/httemplate/elements/standardize_locations.js @@ -13,7 +13,7 @@ function form_address_info() { % } % for my $pre (@prefixes) { % # normal case -% for my $field (qw(address1 address2 city state zip country)) { +% for my $field (qw(address1 address2 state zip country), ($conf->exists('cust_main-no_city_in_address') ? () : 'city')) { returnobj['<% $pre %><% $field %>'] = cf.elements['<% $pre %><% $field %>'].value; % } #for $field % if ( $withcensus ) { @@ -145,7 +145,7 @@ function replace_address() { var clean = newaddr['<% $pre %>addr_clean'] == 'Y'; var error = newaddr['<% $pre %>error']; if ( clean ) { -% foreach my $field (qw(address1 address2 city state zip addr_clean )) { +% foreach my $field (qw(address1 address2 state zip addr_clean ),($conf->exists('cust_main-no_city_in_address') ? () : 'city')) { cf.elements['<% $pre %><% $field %>'].value = newaddr['<% $pre %><% $field %>']; % } #foreach $field |