com.ibm.commerce.returns.commands
Class ReturnItemComponentUpdateCmdImpl
com.ibm.commerce.command.AbstractECTargetableCommand
|
+--com.ibm.commerce.command.ControllerCommandImpl
|
+--com.ibm.commerce.returns.commands.ReturnItemComponentUpdateCmdImpl
- All Implemented Interfaces:
- AccCommand, ControllerCommand, ECCommand, ECTargetableCommand, Protectable, ReturnItemComponentUpdateCmd
- public class ReturnItemComponentUpdateCmdImpl
- extends ControllerCommandImpl
- implements ReturnItemComponentUpdateCmd
Command to update the component of a return mechandise authorization (RMA) item.
Parameters
- RMAItemCmpId_i (mandatory)
- Identifier of the RMA item component is to be changed.
- receive_i
- Whether the item should be received from the customer ('N', 'Y'). Changes the SHOULDRECEIVE column
of table RMAITEMCMP.
- URL (mandatory)
- URL to redirect to.
- storeId (mandatory)
- Identifier of the store that owns the RMA.
All parameters ending with the same _i are grouped together. This way you can change multiple
RMA item components at once.
Behaviour
- For each RMA item component specified, the receive value of the component is set, if specified.
Method Summary |
protected java.lang.String |
getReceive(java.lang.Integer index)
Get the receive value for the specified index. |
AccessVector |
getResources()
Gets the vector of resources accessed by this command. |
protected RMAItemComponentAccessBean |
getRMAItemComponentAB(java.lang.Integer index)
Get the RMA item component access bean for the specified index. |
protected java.lang.Long |
getRMAItemComponentId(java.lang.Integer index)
Get the RMA item component id for the appropriate index. |
protected java.util.List |
getRMAs()
Get the RMAs related to the components. |
protected java.lang.String |
getURL()
Get the redirection URL. |
void |
performExecute()
Execute the command. |
void |
reset()
Reset the command. |
void |
setRequestProperties(TypedProperty aRequestProperties)
The WebController calls this method before invoking the execute method in this command to
set the request properties for this command. |
void |
validateParameters()
Check mandatory parameters. |
Methods inherited from class com.ibm.commerce.command.ControllerCommandImpl |
fulfills, getForUserId, getGeneric, getOwner, getRequestProperties, getResolvedRequestProperties, getResponseProperties, getRetriable, getViewInputProperties, isGeneric, isRetriable, mergeProperties, setForUserId, setGeneric, setOwner, setResponseProperties, setRetriable, setViewInputProperties |
Methods inherited from class com.ibm.commerce.command.AbstractECTargetableCommand |
accessControlCheck, checkIsAllowed, checkResourcePermission, execute, finalize, getAccCheck, getCommandContext, getCommandIfName, getCommandName, getDefaultProperties, getStoreId, getUser, getUserId, isReadyToCallExecute, setAccCheck, setCommandContext, setCommandIfName, setDefaultProperties |
Methods inherited from interface com.ibm.commerce.command.ControllerCommand |
execute, getGeneric, getRequestProperties, getResolvedRequestProperties, getResponseProperties, getRetriable, getViewInputProperties, isGeneric, isRetriable, mergeProperties, setGeneric, setRetriable, setViewInputProperties |
Methods inherited from interface com.ibm.commerce.command.ECCommand |
checkIsAllowed, checkResourcePermission, getCommandContext, getCommandIfName, getCommandName, getDefaultProperties, getStoreId, getUser, getUserId, setCommandContext, setCommandIfName, setDefaultProperties |
ReturnItemComponentUpdateCmdImpl
public ReturnItemComponentUpdateCmdImpl()
- ReturnItemComponentUpdateCmdImpl constructor.
getReceive
protected java.lang.String getReceive(java.lang.Integer index)
- Get the receive value for the specified index. If the receive value
is "" (empty string) then return null.
- Parameters:
index
- which instance of the retreive value to get- Returns:
- The receive value.
getResources
public AccessVector getResources()
throws ECException
- Gets the vector of resources accessed by this command.
- Specified by:
getResources
in interface ECCommand
- Overrides:
getResources
in class AbstractECTargetableCommand
- Returns:
- The vector of resource action pairs - RMA access beans.
getRMAItemComponentAB
protected RMAItemComponentAccessBean getRMAItemComponentAB(java.lang.Integer index)
- Get the RMA item component access bean for the specified index. The access
beans have already been created in validateParameters.
- Parameters:
index
- The index.- Returns:
- The RMA item component access bean.
getRMAItemComponentId
protected java.lang.Long getRMAItemComponentId(java.lang.Integer index)
throws InvalidParameterValueException
- Get the RMA item component id for the appropriate index.
- Parameters:
index
- which instance of the RMA component id value to get- Returns:
- The RMA item component id value.
getRMAs
protected java.util.List getRMAs()
throws ECSystemException
- Get the RMAs related to the components.
- Returns:
- The list of RMA access beans.
getURL
protected java.lang.String getURL()
- Get the redirection URL.
- Returns:
- The URL.
performExecute
public void performExecute()
throws ECException
- Execute the command.
- Specified by:
performExecute
in interface ECCommand
- Overrides:
performExecute
in class AbstractECTargetableCommand
- Following copied from interface:
com.ibm.commerce.command.ECCommand
- Throws:
com.ibm.commerce.command.CommandException
- The superclass for all ECExceptions.
reset
public void reset()
- Reset the command.
- Overrides:
reset
in class AbstractECTargetableCommand
setRequestProperties
public void setRequestProperties(TypedProperty aRequestProperties)
throws ECApplicationException
- Description copied from interface:
ControllerCommand
- The WebController calls this method before invoking the execute method in this command to
set the request properties for this command.
It is the responsibility of the implementer of the ControllerCommand to extract the
required input parameters from the request properties and perform parameter checking.
- Specified by:
setRequestProperties
in interface ControllerCommand
- Overrides:
setRequestProperties
in class ControllerCommandImpl
- Following copied from interface:
com.ibm.commerce.command.ControllerCommand
- Parameters:
requestProperties
- com.ibm.commerce.datatype.TypedProperty- Throws:
com.ibm.commerce.exception.ECException.
-
validateParameters
public void validateParameters()
throws ECException
- Check mandatory parameters.
- Specified by:
validateParameters
in interface ECCommand
- Overrides:
validateParameters
in class AbstractECTargetableCommand
- Following copied from interface:
com.ibm.commerce.command.ECCommand
- Throws:
ECException.
-