Package org.compiere.grid
Class PaymentForm
java.lang.Object
org.compiere.grid.PaymentForm
- All Implemented Interfaces:
IPaymentForm
- Direct Known Subclasses:
PaymentFormCash
,PaymentFormCheck
,PaymentFormCreditCard
,PaymentFormDirect
,PaymentFormMixedPOS
,PaymentFormOnCredit
- Author:
- Elaine
-
Field Summary
Modifier and TypeFieldDescriptionprotected CLogger
Loggerprotected int
protected int
protected BigDecimal
protected int
protected int
Invoice Currencyprotected boolean
protected Timestamp
Start Acct Dateprotected String
protected boolean
Is SOTrxprotected boolean
protected boolean
Only allow changing Ruleprotected String
Start Payment Rule -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected abstract void
afterSave
(boolean success) after save and trx committed/rollbackboolean
dynInit()
dynamic initializationprotected MBankAccountProcessor
getBankAccountProcessor
(Properties ctx, String tender, String CCType, int AD_Client_ID, int C_Currency_ID, BigDecimal PayAmt, String trxName) Get online payment processor configurationprotected int
getInvoiceID
(int C_Order_ID) Get Invoice ID for Orderint
boolean
protected boolean
isBankAccountProcessorExist
(Properties ctx, String tender, String CCType, int AD_Client_ID, int C_Currency_ID, BigDecimal PayAmt, String trxName) boolean
boolean
needSave()
Need to save the calling window (order, invoice)void
online payment processing (for e.g credit card)boolean
Save Changesvoid
setBankAccountProcessor
(MBankAccountProcessor bankAccountProcessor) Set online payment processor configurationvoid
setCustomizeValues
(PO po) Make additional changes to PO before write to DBMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.compiere.grid.IPaymentForm
checkMandatory, closeWindow, getWindow, loadData, saveChangesInTrx, showWindow
-
Field Details
-
log
Logger -
m_DocStatus
-
m_PaymentRule
Start Payment Rule -
m_DateAcct
Start Acct Date -
m_C_Currency_ID
protected int m_C_Currency_IDInvoice Currency -
m_AD_Client_ID
protected int m_AD_Client_ID -
m_Cash_As_Payment
protected boolean m_Cash_As_Payment -
m_AD_Org_ID
protected int m_AD_Org_ID -
m_C_BPartner_ID
protected int m_C_BPartner_ID -
m_Amount
-
m_needSave
protected boolean m_needSave -
m_onlyRule
protected boolean m_onlyRuleOnly allow changing Rule -
m_isSOTrx
protected boolean m_isSOTrxIs SOTrx
-
-
Constructor Details
-
PaymentForm
- Parameters:
WindowNo
-mTab
-
-
-
Method Details
-
dynInit
Description copied from interface:IPaymentForm
dynamic initialization- Specified by:
dynInit
in interfaceIPaymentForm
- Returns:
- false if there are errors, true otherwise
- Throws:
Exception
-
saveChanges
public boolean saveChanges()Description copied from interface:IPaymentForm
Save Changes- Specified by:
saveChanges
in interfaceIPaymentForm
- Returns:
- true, if Window can exit
-
afterSave
protected abstract void afterSave(boolean success) after save and trx committed/rollback- Parameters:
success
-
-
needSave
public boolean needSave()Description copied from interface:IPaymentForm
Need to save the calling window (order, invoice)- Specified by:
needSave
in interfaceIPaymentForm
- Returns:
- true if changes have been to the calling window
-
getInvoiceID
protected int getInvoiceID(int C_Order_ID) Get Invoice ID for Order- Parameters:
C_Order_ID
- order- Returns:
- C_Invoice_ID or 0 if not found
-
processOnline
public void processOnline()Description copied from interface:IPaymentForm
online payment processing (for e.g credit card)- Specified by:
processOnline
in interfaceIPaymentForm
-
isBankAccountProcessorExist
protected boolean isBankAccountProcessorExist(Properties ctx, String tender, String CCType, int AD_Client_ID, int C_Currency_ID, BigDecimal PayAmt, String trxName) - Parameters:
ctx
-tender
-CCType
-AD_Client_ID
-C_Currency_ID
-PayAmt
-trxName
-- Returns:
- true if online payment processor have been configured for bank account
-
getBankAccountProcessor
protected MBankAccountProcessor getBankAccountProcessor(Properties ctx, String tender, String CCType, int AD_Client_ID, int C_Currency_ID, BigDecimal PayAmt, String trxName) Get online payment processor configuration- Parameters:
ctx
-tender
- tender typeCCType
- credit card typeAD_Client_ID
-C_Currency_ID
-PayAmt
-trxName
-- Returns:
MBankAccountProcessor
-
getGridTab
- Returns:
GridTab
-
isOnlyRule
public boolean isOnlyRule()- Specified by:
isOnlyRule
in interfaceIPaymentForm
- Returns:
- true if only show payment rule and doesn't save changes to DB
-
isApproved
public boolean isApproved()- Specified by:
isApproved
in interfaceIPaymentForm
- Returns:
- true if payment transaction have been approved by payment gateway
-
getWindowNo
public int getWindowNo()- Returns:
- window no
-
setCustomizeValues
Description copied from interface:IPaymentForm
Make additional changes to PO before write to DB- Specified by:
setCustomizeValues
in interfaceIPaymentForm
-
setBankAccountProcessor
Description copied from interface:IPaymentForm
Set online payment processor configuration- Specified by:
setBankAccountProcessor
in interfaceIPaymentForm
-