X-Git-Url: http://git.freeside.biz/gitweb/?p=freeside.git;a=blobdiff_plain;f=httemplate%2Fview%2Fcust_main.cgi;h=c49efa653f47fd7b6eb67b71dd111eecb98f23a7;hp=25260fa3c2eaf16ed759a62751ae5bbade56a911;hb=789c34c5251f4b831a7cb27bd2a9af700ccf2ced;hpb=b97ccb2b958567490841cfc93d2c4a401d98cdb0 diff --git a/httemplate/view/cust_main.cgi b/httemplate/view/cust_main.cgi index 25260fa3c..c49efa653 100755 --- a/httemplate/view/cust_main.cgi +++ b/httemplate/view/cust_main.cgi @@ -83,9 +83,13 @@ print '', $cust_main->country, '', ; - print 'Day Phone', + my $daytime_label = FS::Msgcat::_gettext('daytime') || 'Day Phone'; + my $night_label = FS::Msgcat::_gettext('night') || 'Night Phone'; + print ''. $daytime_label. + '', $cust_main->daytime || ' ', '', - 'Night Phone', + ''. $night_label. + '', $cust_main->night || ' ', '', 'Fax', $cust_main->fax || ' ', '', @@ -122,10 +126,10 @@ print '', $cust_main->get("${pre}country"), '', ; - print 'Day Phone', + print ''. $daytime_label. '', '', $cust_main->get("${pre}daytime") || ' ', '', - 'Night Phone'. + ''. $night_label. ''. '', $cust_main->get("${pre}night") || ' ', '', 'Fax', @@ -217,6 +221,23 @@ if ( $conf->config('payby-default') ne 'HIDE' ) { 'Name on card', $cust_main->payname, '' ; + } elsif ( $cust_main->payby eq 'CHEK' ) { + my( $account, $aba ) = split('@', $cust_main->payinfo ); + print 'Electronic check', + 'Account number', + $account, '', + 'ABA/Routing code', + $aba, '', + 'Bank name', + $cust_main->payname, '' + ; + } elsif ( $cust_main->payby eq 'LECB' ) { + $cust_main->payinfo =~ /^(\d{3})(\d{3})(\d{4})$/; + my $payinfo = "$1-$2-$3"; + print 'Phone bill billing', + 'Phone number', + $payinfo, '', + ; } elsif ( $cust_main->payby eq 'BILL' ) { print 'Billing'; print 'P.O. ', @@ -456,6 +477,11 @@ function cust_pay_areyousure(href) { == true) window.location.href = href; } +function cust_pay_unapply_areyousure(href) { + if (confirm("Are you sure you want to unapply this payment?") + == true) + window.location.href = href; +} END @@ -510,8 +536,12 @@ if ( $conf->config('payby-default') ne 'HIDE' ) { my $delete = $payment->closed !~ /^Y/i && $conf->exists('deletepayments') ? qq! (delete)! : ''; + my $unapply = + $payment->closed !~ /^Y/i && $conf->exists('unapplypayments') + ? qq! (unapply)! + : ''; push @history, - "$date\tPayment, Invoice #$invnum ($payby$payinfo)$delete\t\t$paid\t\t\t$target"; + "$date\tPayment, Invoice #$invnum ($payby$payinfo)$delete$unapply\t\t$paid\t\t\t$target"; } my(@cust_credit_bill)=