public class EditCmdImpl extends AEDPPaymentTaskCmdImpl implements EditCmd
commandContext | The command context. |
orderId | The order id. |
orderAmount | The order amount. |
pis | The payment instructions. |
Constructor and Description |
---|
EditCmdImpl() |
Modifier and Type | Method and Description |
---|---|
protected void | executeEditPaymentTCs()
Executes the required terms and conditions (TCs) before calling the event-driven payments edit API.
|
AccountAccessBean | getAccount()
This method returns the AccountAccessBean representing the business account if an account ID is present.
|
java.lang.Long | getAccountId()
This method returns the business account ID if one is specified by the trading agreements used by the order items of the order being processed.
|
java.lang.Long | getBuyerPOId()
Do nothing
|
EDPEditResults | getEditResults()
This method returns the edit results.
|
OrderAccessBean | getOrderAccessBean()
This method returns the order access bean associated with this command.
|
java.math.BigDecimal | getOrderAmount()
This method returns the total order amount.
|
java.util.ArrayList | getPaymentInstructions()
This method returns the list of payment instructions affected by this payment instruction edit operation.
|
java.lang.String | getPONumber()
This method returns null
|
boolean | isReadyToCallExecute()
This method is called by the Command Framework to check if all basic mandatory parameters have been set for this command.
|
void | performExecute()
This method executes the business logic of this command implementation.
|
protected void | preparePIsForEdit()
This method invokes the PreparePIsForEditPolicyCmd business policy command for each set of PIs sharing the same payment method/payment policy.
|
void | processBG()
This command executes a list of lists of payment actions by invoking executeHashOfListsOfActions(HashMap actionLists).
|
void | processFG()
This method is the main method to process the current payment instruction edit operation.
|
void | reset()
This command resets the command fields.
|
void | setAccountId(java.lang.Long n)
This method sets the business account ID.
|
void | setBuyerPOId(java.lang.Long n)
Do nothing
|
void | setEditResults(EDPEditResults localEditResults)
This method sets the edit results.
|
void | setForcedPaymentInstructionChangeFlag(boolean forcedChange)
This method sets the forced flag indicating if the payment instruction edit operation will be forced or not.
|
void | setOrderAmount(java.math.BigDecimal paramOrderAmount)
This method sets the total order amount.
|
void | setPaymentInstructions(java.util.ArrayList paramPIs)
This method sets the payment instructions affected by this payment instruction edit operation.
|
void | setPONumber(java.lang.String sPONumber)
This method sets the purchase order number.
|
void | systemEditableAddOrderAmount(java.lang.Long edpOrderId, java.math.BigDecimal addToPIAmount)
This method increases a payment instruction amount as a systemEditable operation.
|
java.lang.String | toString()
This method converts this payment instruction edit operation data into a human-readable string.
|
void | validateInsideProcessFG()
This method validates all parameters for this payment instruction edit operation.
|
public AccountAccessBean getAccount()
public void setAccountId(java.lang.Long n)
public java.lang.Long getAccountId()
public final void setEditResults(EDPEditResults localEditResults)
public final EDPEditResults getEditResults()
public void setBuyerPOId(java.lang.Long n)
public java.lang.Long getBuyerPOId()
public void setForcedPaymentInstructionChangeFlag(boolean forcedChange)
public OrderAccessBean getOrderAccessBean()
public void setOrderAmount(java.math.BigDecimal paramOrderAmount)
public java.math.BigDecimal getOrderAmount()
public void setPONumber(java.lang.String sPONumber)
public java.lang.String getPONumber()
public void setPaymentInstructions(java.util.ArrayList paramPIs)
public java.util.ArrayList getPaymentInstructions()
public boolean isReadyToCallExecute()
public void performExecute() throws ECException
public void reset()
protected void executeEditPaymentTCs() throws ECException
Executes the required terms and conditions (TCs) before calling the event-driven payments edit API.
It performs the following:
protected void preparePIsForEdit() throws ECException
public void processBG() throws EDPException, ECException
public void processFG() throws EDPException, ECException
This method is the main method to process the current payment instruction edit operation.
It not only edits the payment instructions in payment rules, but also edits the payment instructions in payment processing. Also, it edits the EDP order.
public void systemEditableAddOrderAmount(java.lang.Long edpOrderId, java.math.BigDecimal addToPIAmount) throws EDPException, ECException
This method increases a payment instruction amount as a systemEditable operation.
This is a public method to be invoked for ReservePayment. This seems a hack but it is working so far. This has a good potential for refactoring in the future...
A wrapper for editAddOrderAmount. Invokes editAddOrderAmount if the systemEditable flag is true, throws an exception otherwise.
public java.lang.String toString()
public void validateInsideProcessFG() throws EDPException