public class OrderStatusCmdImpl extends ControllerCommandImpl implements OrderStatusCmd
OrderStatus command (see interface for a detailed
description of the OrderStatus command).| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
CONFIG_GROUPING_SYNC_ORDER
Name of the configuration grouping for the sync order integration
flow.
|
static java.lang.String |
CONFIG_PROPERTY_FINALIZE_PAYMENT
Name of the configuration property for the finalize payment setting.
|
static java.lang.String |
COPYRIGHT
The internal copyright field.
|
static java.lang.String |
EMPTY_STRING
The empty string.
|
static java.lang.String |
UPDATEMODE_COMPLETE
The complete update mode
|
static java.lang.String |
UPDATEMODE_PARTIAL
The partial update mode
|
defaultCommandClassName, NAME| Constructor and Description |
|---|
OrderStatusCmdImpl() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
checkOrderStatusSequence(OrderFulfillmentStatusAccessBean orderStatusAB)
This method verifies that the sequence information of the order status to update
does not conflict with the order status currently in the ORDSTAT table.
|
void |
createOrderStatus()
This method creates a new entry in the ORDSTAT table based on the information that is
received through the request properties.
|
boolean |
doDOMPostProcess(TypedProperty aRequestProperty)
Works with
doDOMPreProcess(TypedProperty) to implement the following business logic. |
boolean |
doDOMPreProcess(TypedProperty aRequestProperty)
Works with
doDOMPostProcess(TypedProperty) to implement the following business logic. |
boolean |
doPostProcess(TypedProperty aRequestProperty)
This method performs a verification check after the command executes.
|
boolean |
doPreProcess(TypedProperty aRequestProperty)
This method performs a verification check before the command executes.
|
boolean |
doProcess(TypedProperty aRequestProperty)
This method performs the business logic for this command.
|
AccessVector |
getIAccessVector()
This method returns the
iAccessVector. |
java.lang.String |
getIMerchantOrderNumber()
This method returns the iMerchantOrderNumber.
|
java.lang.Short |
getInventorySystem()
Get the inventory system of the current online store.
|
java.lang.Long |
getIOrderId()
This method returns the iOrderId.
|
java.util.Vector |
getOsItems()
This method returns the
osItems. |
TypedProperty |
getOsProp()
This method returns the
osProp. |
AccessVector |
getResources()
This method gets the access vector accessed by this command.
|
boolean |
isReadyToCallExecute()
This method indicates whether the command is ready to execute.
|
static boolean |
isSyncWCSOrderStatusEnabled()
Check whether the sync WCS order status flag is enabled in the configuration files.
|
void |
performExecute()
Performs a precondition check on the request properties.
|
void |
propertySet(OrderFulfillmentStatusAccessBean ab,
TypedProperty aProp)
This method fills the OrderFulfillmentStatusAccessBean object with the values that are found
in the request properties.
|
void |
reset()
This method resets the output properties to the values they had before
calling the execute method.
|
void |
setRequestProperties(TypedProperty aRequestProperties)
This method binds the parameters received by the request properties to variables that are used
for determining the order to updated.
|
void |
updateOrder(OrderAccessBean abOrder)
This method updates the ORDSTAT table with the information given by the request properties.
|
void |
validateParameters()
This method performs parameter checking.
|
checkPermission, fulfills, getForUserId, getGeneric, getOwner, getRequestProperties, getResolvedRequestProperties, getResourceOwners, getResponseProperties, getRetriable, getViewInputProperties, isGeneric, isRetriable, mergeProperties, setForUserId, setGeneric, setOwner, setResponseProperties, setRetriable, setViewInputPropertiesaccessControlCheck, checkIsAllowed, checkResourcePermission, createCommandExecutionEvent, execute, getAccCheck, getCommandContext, getCommandIfName, getCommandName, getCommandStoreId, getDefaultProperties, getExceptionInvokeParameters, getObjectSize, getPostInvokeParameters, getPreInvokeParameters, getStoreId, getUser, getUserId, setAccCheck, setCommandContext, setCommandIfName, setCommandStoreId, setDefaultPropertiesexecuteFromCache, getCaller, getEntryInfo, getId, getSharingPolicy, postExecute, preExecute, setCaller, setObjectSize, unionDependencies, updateCachegetCommandTarget, getCommandTargetName, getTargetPolicy, hasOutputProperties, setCommandTarget, setCommandTargetName, setHasOutputProperties, setOutputProperties, setTargetPolicyequals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitcheckPermission, execute, getGeneric, getRequestProperties, getResolvedRequestProperties, getResponseProperties, getRetriable, getViewInputProperties, isGeneric, isRetriable, mergeProperties, setGeneric, setRetriable, setViewInputPropertiesexecuteFromCache, getCaller, getEntryInfo, getId, getSharingPolicy, postExecute, preExecute, setCaller, updateCachegetCommandTarget, getCommandTargetName, hasOutputProperties, setCommandTarget, setCommandTargetName, setOutputPropertiesaccessControlCheck, getAccCheck, getForUserId, getResourceOwners, setAccCheck, setForUserId, setOwnercheckIsAllowed, checkResourcePermission, createCommandExecutionEvent, getCommandContext, getCommandIfName, getCommandName, getCommandStoreId, getDefaultProperties, getExceptionInvokeParameters, getPostInvokeParameters, getPreInvokeParameters, getStoreId, getUser, getUserId, setCommandContext, setCommandIfName, setCommandStoreId, setDefaultPropertiesfulfills, getOwnerpublic static final java.lang.String COPYRIGHT
public static final java.lang.String EMPTY_STRING
public static final java.lang.String UPDATEMODE_PARTIAL
public static final java.lang.String UPDATEMODE_COMPLETE
public static final java.lang.String CONFIG_GROUPING_SYNC_ORDER
public static final java.lang.String CONFIG_PROPERTY_FINALIZE_PAYMENT
public boolean checkOrderStatusSequence(OrderFulfillmentStatusAccessBean orderStatusAB) throws ECException
orderStatusAB - The OrderFulfillmentStatusAccessBeanECExceptionpublic void createOrderStatus()
throws ECException
ECExceptionpublic boolean doPostProcess(TypedProperty aRequestProperty) throws ECException
getFinalizedPayment() returns true,
It invokes doDOMPostProcesses() for DOM to reserve and finalize payments for order
items those fulfillment statuses have been updated to D (deposited).
It currently always returns true.doPostProcess in interface OrderStatusCmdaRequestProperty - com.ibm.commerce.datatype.TypedPropertyECExceptionpublic boolean doDOMPreProcess(TypedProperty aRequestProperty) throws ECException
doDOMPostProcess(TypedProperty) to implement the following business logic.
This implementation reserves and finalizes payments for order items those fulfillment
statuses have been updated to D (deposited).
D (deposited):
getDepositedAmount(OrderFulfillmentStatusAccessBean) to find the amount already deposited.doDOMPostProcess(TypedProperty) calls getDepositedAmount(OrderFulfillmentStatusAccessBean) again to find the needed deposit amount.doDOMPostProcess(TypedProperty) calls getNextReleaseNumber(Long) to find the next available release number.doDOMPostProcess(TypedProperty) calls ReservePaymentCmd and FinalizePaymentCmd to reserve and finalize the
amount to be deposited (i.e. the needed deposit amount minus the amount already deposited), using a new release.aRequestProperty - com.ibm.commerce.datatype.TypedPropertyECExceptionpublic boolean doDOMPostProcess(TypedProperty aRequestProperty) throws ECException
doDOMPreProcess(TypedProperty) to implement the following business logic.
This implementation reserves and finalizes payments for order items those fulfillment
statuses have been updated to D (deposited).
D (deposited):
doDOMPreProcess(TypedProperty) calls getDepositedAmount(OrderFulfillmentStatusAccessBean) to find the amount already deposited.getDepositedAmount(OrderFulfillmentStatusAccessBean) again to find the needed deposit amount.getNextReleaseNumber(Long) to find the next available release number.ReservePaymentCmd and FinalizePaymentCmd to reserve and finalize the
amount to be deposited (i.e. the needed deposit amount minus the amount already deposited), using a new release.aRequestProperty - com.ibm.commerce.datatype.TypedPropertyECExceptionpublic boolean doPreProcess(TypedProperty aRequestProperty) throws ECException
getFinalizedPayment() returns true,
It invokes doDOMPreProcesses() for DOM to reserve and finalize payments for order
items those fulfillment statuses have been updated to D (deposited).
It currently always returns true.doPreProcess in interface OrderStatusCmdaRequestProperty - com.ibm.commerce.datatype.TypedPropertyECExceptionpublic boolean doProcess(TypedProperty aRequestProperty) throws ECException
doProcess in interface OrderStatusCmdaRequestProperty - The request propertyECExceptionpublic AccessVector getResources() throws ECException
getResources in interface ECCommandgetResources in class AbstractECTargetableCommandECExceptionpublic boolean isReadyToCallExecute()
isReadyToCallExecute in interface com.ibm.websphere.command.CommandisReadyToCallExecute in class AbstractECTargetableCommandpublic java.lang.Short getInventorySystem()
throws ECException
ECExceptionpublic void performExecute()
throws ECException
performExecute in interface ECCommandperformExecute in interface com.ibm.websphere.command.TargetableCommandperformExecute in class AbstractECTargetableCommandECExceptionpublic void propertySet(OrderFulfillmentStatusAccessBean ab, TypedProperty aProp) throws ECException
ab - The OrderFulfillmentStatusAccessBeanaProp - The TypedPropertyECExceptionpublic void reset()
CommandTarget.reset in interface com.ibm.websphere.command.Commandreset in class AbstractECTargetableCommandpublic void setRequestProperties(TypedProperty aRequestProperties) throws ECException
setRequestProperties in interface ControllerCommandsetRequestProperties in class ControllerCommandImplaRequestProperties - The request propertyECException - Raised with _ERR_INVALID_ORDER_REFNUM whenever the order ID is not contained in the request propertypublic void updateOrder(OrderAccessBean abOrder) throws ECException
abOrder - com.ibm.commerce.order.objects.OrderAccessBeanECExceptionpublic void validateParameters()
throws ECException
checkParameters() in previous product releases.
The default implementation of validateParameters() only checks if the order exists.
It is the responsibility of the command writers to implement this method if they want to perform
server side parameter checking.
validateParameters in interface ECCommandvalidateParameters in class AbstractECTargetableCommandECException - Raised if the order does not exist.public AccessVector getIAccessVector()
iAccessVector.public java.lang.String getIMerchantOrderNumber()
public java.lang.Long getIOrderId()
public java.util.Vector getOsItems()
osItems.public TypedProperty getOsProp()
osProp.public static boolean isSyncWCSOrderStatusEnabled()
wc-admin-component.xml.
Add a new property syncWCSOrderStatus for the config grouping SyncOrder.
The sample:
<_config:extendedconfiguration>
........
<_config:configgrouping name="SyncOrder">
...........
<_config:property name="syncWCSOrderStatus" value="true"/>
........
If this property is set to true, the WCS order and order item status will be synchronized
with the passed external order and order item status.
If not specified, this property is defaulted to false.