From 487980efc8315a0de443159142e5fce4af9f57cc Mon Sep 17 00:00:00 2001 From: levinse Date: Sun, 24 Apr 2011 17:05:02 +0000 Subject: add per-customer configurable billing date, RT10813 --- httemplate/edit/cust_main/billing.html | 39 ++++++++++++++++++++++++++++++++-- 1 file changed, 37 insertions(+), 2 deletions(-) (limited to 'httemplate/edit') diff --git a/httemplate/edit/cust_main/billing.html b/httemplate/edit/cust_main/billing.html index e6600e689..2301a0b9c 100644 --- a/httemplate/edit/cust_main/billing.html +++ b/httemplate/edit/cust_main/billing.html @@ -96,6 +96,14 @@ return true; } + function payauto_changed(payauto_field){ + var f = (payauto_field.name == 'CARD_payauto') ? 'card_billday' : 'chek_billday'; + f = document.getElementById(f); + if ( f == null) return; + if(payauto_field.checked) f.style.display = 'inline'; + else f.style.display = 'none'; + } + <% include('/elements/init_overlib.html') %> @@ -120,6 +128,19 @@ % : $payby eq 'CHEK' ? 'CHECKED' % : $disable_payauto ? '' : 'CHECKED'; % +% sub billday_options { +% my $curr_value = shift; +% my $ret = ''; +% for my $billday ( 1 .. 28 ) { +% my $sel = ''; +% $sel = "SELECTED='SELECTED'" if $curr_value == $billday; +% $ret .= ""; +% } +% $ret; +% } +% my $billday_card_display = $payby eq 'CARD' ? 'inline' : 'none'; +% my $billday_chek_display = $payby eq 'CHEK' ? 'inline' : 'none'; +% % my %payby = ( % % 'CARD' => @@ -171,7 +192,14 @@ % qq!${r}Exact name on card !. % qq!!. % -% qq! Charge future payments to this card automatically!. +% qq! Charge future payments to this card automatically!. +% +% ( $conf->exists('cust_main-select-billday') ? +% qq! +% Charge on the day of each month! +% : '' +% ). % % '', % @@ -209,7 +237,14 @@ % ). % % -% qq! Charge future payments to this electronic check automatically!. +% qq! Charge future payments to this electronic check automatically!. +% +% ( $conf->exists('cust_main-select-billday') ? +% qq! +% Charge on the day of each month! +% : '' +% ). % % ' '. % ' '. -- cgit v1.2.1