public class OrderCalculateCmdImpl extends OrderBaseCmdImpl implements OrderCalculateCmd
Name | Description |
---|---|
orderId | The reference number of the order to be displayed. If this parameter is omitted, this command behaves as if all of the customer's orders with the specified status for the specified store were specified. Abbreviations may be used, but only with pending orders (status is P for standard orders or NEW for advanced orders). This parameter can be repeated. |
calculationUsageId | Predefined codes for calculation of discounts (-1), shipping (-2), sales tax (-3), shipping tax, (-4) coupons (-5), surcharge (-6), shipping adjustment (-7). This parameter can be repeated. |
outOrderName | Specifies the names of name-value pairs to be passed to a JSP. The value of each added name-value pair is the reference number of the order to be displayed. If the name is not provided, the default name orderId is used. This parameter can be repeated. |
updatePrices | the flag to indicate whether the price of order item will be refreshed in this command. if the flag is "1", price will be updated. others will not. |
doPrice | Specifies whether the command should perform the price calculation subtasks. Set to either do the price tasks (Y), or not (N). Turning off these tasks might result in better performance, but customers might not get the most current price, or product entitlement, when changes occur. |
doFreeGift | Specifies whether the command should perform the free gift handling logic. Set to either do the free gift handling (Y), or not (N). The default value is (Y). Only set it to (N) when free gift processing isn't required for Order recalculation. |
Name | Description |
---|---|
istrOutOrderNames | the order IDs to be displayed |
outOfInventoryCatalogEntryId | the catalog entrys which are intended to add to the order as free gift but has no inventory now. |
nonBuyableCatalogEntryId | the catalog entrys which are intended to add to the order as free gift but are non-buyable now. |
Modifier and Type | Field and Description |
---|---|
static java.lang.String | COPYRIGHT
The IBM copyright notice field.
|
Constructor and Description |
---|
OrderCalculateCmdImpl()
Constructor for OrderCalculateCmdImpl.
|
Modifier and Type | Method and Description |
---|---|
protected void | addCatalogEntriesToOrder(OrderAccessBean aabOrder, java.util.Map amapCatalogEntryQuantitiesToAdd)
Deprecated.
This method has been deprecated and the logic is moved to CalculateOrderCmd.
|
protected DiscountContext | createDiscountContext(OrderAccessBean aabOrder)
This method creates the DiscountContext.
|
protected java.util.Map | getCatalogEntryQuantitiesToAdd(OrderAccessBean aabOrder, java.util.HashMap ahshCustomProperties)
Deprecated.
This method has been deprecated and the logic is moved to CalculateOrderCmd.
|
java.util.HashMap | getCustomProperties()
This method returns the customer properties.
|
protected java.util.Map | getFreebies(Discount[] aDiscounts)
Deprecated.
This method has been deprecated and the logic is moved to CalculateOrderCmd.
|
protected OrderItemAccessBean[] | getOrderItems(OrderAccessBean aabOrder)
This method returns the OrderItems of the specified Order.
|
protected OrderAccessBean[] | getOrders()
This method returns the Orders specified to be processed by this command.
|
java.lang.Long[] | getOutOfInventoryCatalogEntryIds()
This method returns the list of catEntryIds of the items that are out of inventory.
|
protected java.util.Set | getOutOfInventoryCatalogEntryIds(java.util.Map amapCatalogEntryQuantitiesToAdd)
Deprecated.
This method has been deprecated and the logic is moved to CalculateOrderCmd.
|
AccessVector | getResources()
Returns an AccessVector containing the OrderAccessBeans to be processed.
|
protected java.lang.Integer[] | getUsageIds()
This method returns the CalculationUsages specified to be recalculated by this command.
|
protected void | invokeRuleService(DiscountContext aDiscountContext)
Deprecated.
This method is used for Blaze implementation only, which has been deprecated.
|
void | performExecute()
This method executes the main business logic of the command implementation.
|
protected void | removeExcessFreebies(java.util.Map amapFreebies, OrderAccessBean aabOrder)
Deprecated.
This method has been deprecated and the logic is moved to CalculateOrderCmd.
|
void | reset()
This method resets instance variables to their initial values.
|
void | setCustomProperties(java.util.HashMap newhshCustomProperties)
This method sets the customer properties.
|
void | setOrders(OrderAccessBean[] aabOrders)
This method sets the orders to be calculated.
|
protected void | setOutOfInventoryCatalogEntryIds(java.lang.Long[] anOutOfInventoryCatalogEntryIds)
Sets the CatalogEntries that are out of inventory.
|
void | setRequestProperties(TypedProperty aRequestProperties)
This method sets the request properties.
|
protected void | setResponseProperties()
This method sets the response properties:
For each name that was specified by the outOrderName request property, add a response property with that name.
|
void | setUsageIds(java.lang.Integer[] anUsageIds)
This method sets the calculation usages.
|
protected void | updateOrderItemProductTotal(OrderItemAccessBean aabOrderItem, java.lang.String astrCurrency)
This method calculates the productTotal of the specified OrderItem.
|
protected void | updateOrderProductTotal(OrderAccessBean aabOrder, OrderItemAccessBean[] aabOrderItems)
This method calls ResolveOrderItemPriceCmd to resolve price and update the product total of the specified Order and OrderItems, if updatePrices=1.
|
void | validateParameters()
Resolve the orders to be processed from the request.
|
public static final java.lang.String COPYRIGHT
public OrderCalculateCmdImpl()
public void setOrders(OrderAccessBean[] aabOrders)
public void setUsageIds(java.lang.Integer[] anUsageIds)
protected void setOutOfInventoryCatalogEntryIds(java.lang.Long[] anOutOfInventoryCatalogEntryIds)
public void setCustomProperties(java.util.HashMap newhshCustomProperties)
protected OrderAccessBean[] getOrders()
protected java.lang.Integer[] getUsageIds()
public java.lang.Long[] getOutOfInventoryCatalogEntryIds()
public java.util.HashMap getCustomProperties()
public AccessVector getResources() throws ECException
protected OrderItemAccessBean[] getOrderItems(OrderAccessBean aabOrder) throws ECException
protected DiscountContext createDiscountContext(OrderAccessBean aabOrder) throws ECException
protected void invokeRuleService(DiscountContext aDiscountContext) throws ECException
protected java.util.Map getFreebies(Discount[] aDiscounts)
protected void removeExcessFreebies(java.util.Map amapFreebies, OrderAccessBean aabOrder) throws ECException
protected java.util.Map getCatalogEntryQuantitiesToAdd(OrderAccessBean aabOrder, java.util.HashMap ahshCustomProperties) throws ECException
protected java.util.Set getOutOfInventoryCatalogEntryIds(java.util.Map amapCatalogEntryQuantitiesToAdd) throws ECException
protected void addCatalogEntriesToOrder(OrderAccessBean aabOrder, java.util.Map amapCatalogEntryQuantitiesToAdd) throws ECException
protected void updateOrderProductTotal(OrderAccessBean aabOrder, OrderItemAccessBean[] aabOrderItems) throws ECException
public void validateParameters() throws ECException
public void performExecute() throws ECException
public void setRequestProperties(TypedProperty aRequestProperties) throws ECException
protected void setResponseProperties() throws ECException
public void reset()
protected void updateOrderItemProductTotal(OrderItemAccessBean aabOrderItem, java.lang.String astrCurrency) throws ECException