IDEMPIERE-60 - Bizidium must not save credit card number

This commit is contained in:
Elaine Tan 2013-02-01 11:57:45 +08:00
parent c130793fff
commit 2238b7d737
1 changed files with 13 additions and 2 deletions

View File

@ -181,8 +181,19 @@ public class MBPBankAccount extends X_C_BP_BankAccount
if (isACH() && getBank() != null) if (isACH() && getBank() != null)
setRoutingNo(null); setRoutingNo(null);
// //
if (getCreditCardNumber() != null)
{
String encrpytedCCNo = PaymentUtil.encrpytCreditCard(getCreditCardNumber());
if (!encrpytedCCNo.equals(getCreditCardNumber()))
setCreditCardNumber(encrpytedCCNo);
}
if (getCreditCardVV() != null) if (getCreditCardVV() != null)
setCreditCardVV(PaymentUtil.encrpytCvv(getCreditCardVV())); {
String encrpytedCvv = PaymentUtil.encrpytCvv(getCreditCardVV());
if (!encrpytedCvv.equals(getCreditCardVV()))
setCreditCardVV(encrpytedCvv);
}
return true; return true;
} // beforeSave } // beforeSave