[freeside-commits] freeside/httemplate/edit/process cust_main.cgi, 1.32.2.3, 1.32.2.4
Ivan,,,
ivan at wavetail.420.am
Thu Mar 27 15:04:05 PDT 2008
Update of /home/cvs/cvsroot/freeside/httemplate/edit/process
In directory wavetail.420.am:/tmp/cvs-serv28252
Modified Files:
Tag: FREESIDE_1_7_BRANCH
cust_main.cgi
Log Message:
fixes edit if routing code only, closes: #3085
Index: cust_main.cgi
===================================================================
RCS file: /home/cvs/cvsroot/freeside/httemplate/edit/process/cust_main.cgi,v
retrieving revision 1.32.2.3
retrieving revision 1.32.2.4
diff -u -d -r1.32.2.3 -r1.32.2.4
--- cust_main.cgi 13 Jan 2008 21:36:08 -0000 1.32.2.3
+++ cust_main.cgi 27 Mar 2008 22:04:01 -0000 1.32.2.4
@@ -180,8 +180,18 @@
if ($new->stateid =~ /^xxx/) {
$new->stateid($old->stateid);
}
- if ($new->payby =~ /^(CARD|DCRD|CHEK|DCHK)$/ && $new->payinfo =~ /xx/) {
+ if ($new->payby =~ /^(CARD|DCRD)$/ && $new->payinfo =~ /xx/) {
$new->payinfo($old->payinfo);
+ } elsif ($new->payby =~ /^(CHEK|DCHK)$/ && $new->payinfo =~ /xx/) {
+ #fix for #3085 "edit of customer's routing code only surprisingly causes
+ #nothing to happen...
+ # this probably won't do the right thing when we don't have the
+ # public key (can't actually get the real $old->payinfo)
+ my($new_account, $new_aba) = split('@', $new->payinfo);
+ my($old_account, $old_aba) = split('@', $old->payinfo);
+ $new_account = $old_account if $new_account =~ /xx/;
+ $new_aba = $old_aba if $new_aba =~ /xx/;
+ $new->payinfo($new_account.'@'.$new_aba);
}
$error ||= $new->replace($old, \@invoicing_list);
More information about the freeside-commits
mailing list