com.ibm.commerce.returns.commands

Class CreditReturnItemCmdImpl

  • All Implemented Interfaces:
    com.ibm.commerce.command.CacheableECCommand, ECCommand, ECTargetableCommand, TaskCommand, CreditReturnItemCmd, com.ibm.websphere.cache.Sizeable, com.ibm.websphere.command.CacheableCommand, com.ibm.websphere.command.Command, com.ibm.websphere.command.CommandCaller, com.ibm.websphere.command.TargetableCommand, java.io.Serializable


    public class CreditReturnItemCmdImpl
    extends TaskCommandImpl
    implements CreditReturnItemCmd
    Default implementation of the CreditReturnItemCmdImpl interface. Activate the refund for a return merchandise authorization (RMA) and its items if there is one and it is approved.

    Behaviour

    • If there is a refund for the RMA then the business policy command ApproveRefundPolicyCmd is called to see if the refund is approved. If it is, the task command FinalizeRefundCmd is called to do the refund.
    • If FinalizeRefundCmd does not raise an exception then the CREDITDATE field of each RMA item is filled in with the current timestamp.

    Utilizes these access beans

    See Also:
    Serialized Form
    • Constructor Detail

      • CreditReturnItemCmdImpl

        public CreditReturnItemCmdImpl()
        CreditReturnItemCmdImpl constructor.
    • Method Detail

      • reset

        public void reset()
        Reset the command.
        Specified by:
        reset in interface com.ibm.websphere.command.Command
        Overrides:
        reset in class AbstractECTargetableCommand
      • setRMAItemABs

        public void setRMAItemABs(java.util.Vector anRMAItemABList)
        Set the RMA items being credited.
        Specified by:
        setRMAItemABs in interface CreditReturnItemCmd
        Parameters:
        anRMAItemABList - The RMA item access bean vector.
      • validateParameters

        public void validateParameters()
                                throws ECException
        Check mandatory parameters. Checks the following parameters:

        Parameters

        • RMAAB
          • RMAAccessBean of the RMA
        • RMAItemAB
          • Vector RMAItemAccessBeans

        Specified by:
        validateParameters in interface ECCommand
        Overrides:
        validateParameters in class AbstractECTargetableCommand
        Throws:
        ECException - If there is no RMAABean or there is no vector of RMAItemAccessBean, throws com.ibm.commerce.exception.ECApplicationException with ECMessage._ERR_BAD_MISSING_CMD_PARAMETER