freeside/FS/FS cust_pay.pm,1.38,1.39
ivan
ivan at pouncequick.420.am
Tue May 3 02:57:15 PDT 2005
Update of /home/cvs/cvsroot/freeside/FS/FS
In directory pouncequick:/tmp/cvs-serv23486
Modified Files:
cust_pay.pm
Log Message:
on receipts, show "Electronic Check" instead of "Chek" for payby = CHEK transactions
Index: cust_pay.pm
===================================================================
RCS file: /home/cvs/cvsroot/freeside/FS/FS/cust_pay.pm,v
retrieving revision 1.38
retrieving revision 1.39
diff -u -d -r1.38 -r1.39
--- cust_pay.pm 21 Mar 2005 22:13:36 -0000 1.38
+++ cust_pay.pm 3 May 2005 09:56:41 -0000 1.39
@@ -183,7 +183,8 @@
my $payby = $self->payby;
my $payinfo = $self->payinfo;
$payby =~ s/^BILL$/Check/ if $payinfo;
- $payinfo = $self->payinfo_masked if $payby eq 'CARD';
+ $payinfo = $self->payinfo_masked if $payby eq 'CARD' || $payby eq 'CHEK';
+ $payby =~ s/^CHEK$/Electronic check/;
my $error = send_email(
'from' => $conf->config('invoice_from'), #??? well as good as any
@@ -464,8 +465,16 @@
sub payinfo_masked {
my $self = shift;
- my $payinfo = $self->payinfo;
- 'x'x(length($payinfo)-4). substr($payinfo,(length($payinfo)-4));
+ #some false laziness w/cust_main::paymask
+ if ( $self->payby eq 'CARD' ) {
+ my $payinfo = $self->payinfo;
+ 'x'x(length($payinfo)-4). substr($payinfo,(length($payinfo)-4));
+ } elsif ( $self->payby eq 'CHEK' ) {
+ my( $account, $aba ) = split('@', $self->payinfo );
+ 'x'x(length($account)-2). substr($account,(length($account)-2)). "@". $aba;
+ } else {
+ $self->payinfo;
+ }
}
=back
More information about the freeside-commits
mailing list