diff options
author | Ivan Kohler <ivan@freeside.biz> | 2012-05-03 14:35:11 -0700 |
---|---|---|
committer | Ivan Kohler <ivan@freeside.biz> | 2012-05-03 14:35:11 -0700 |
commit | 5e8073ffe5707504751b8df36f645b325a895f87 (patch) | |
tree | 887209f29c217dd597744a1e74c749631eebc31a /httemplate/edit/cust_main | |
parent | 79ca46c249e58be3b7c70df57a8fc75a60ceb622 (diff) |
add cust_main-require_locale configuration setting, RT#17594
Diffstat (limited to 'httemplate/edit/cust_main')
-rw-r--r-- | httemplate/edit/cust_main/billing.html | 33 |
1 files changed, 19 insertions, 14 deletions
diff --git a/httemplate/edit/cust_main/billing.html b/httemplate/edit/cust_main/billing.html index 9f4cb74cd..0194d31a6 100644 --- a/httemplate/edit/cust_main/billing.html +++ b/httemplate/edit/cust_main/billing.html @@ -570,20 +570,25 @@ function toggle(obj) { %my @available_locales = $conf->config('available-locales'); %if ( scalar(@available_locales) ) { -% push @available_locales, ''; -% my %locale_labels = map { -% my %ll; -% my %info = FS::Locales->locale_info($_); -% $ll{$_} = $info{name} . " (" . $info{country} . ")"; -% %ll; -% } FS::Locales->locales; - <& /elements/tr-select.html, - 'label' => emt('Invoicing locale'), - 'field' => 'locale', - 'options' => \@available_locales, - 'labels' => \%locale_labels, - 'curr_value' => $cust_main->locale, - &> +% push @available_locales, '' +% unless $cust_main->locale && $conf->exists('cust_main-require_locale'); +% my %locale_labels = map { +% my %ll; +% my %info = FS::Locales->locale_info($_); +% $ll{$_} = $info{name} . " (" . $info{country} . ")"; +% %ll; +% } FS::Locales->locales; +% +% my $label = ( $conf->exists('cust_main-require_locale') ? $r : '' ). +% emt('Invoicing locale'); + + <& /elements/tr-select.html, + 'label' => $label, + 'field' => 'locale', + 'options' => \@available_locales, + 'labels' => \%locale_labels, + 'curr_value' => $cust_main->locale, + &> % } </TABLE> |