public class CartModifierFormHandler extends PurchaseProcessFormHandler
GenericFormHandler
,
PurchaseProcessFormHandler
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
CLASS_VERSION |
static java.lang.String |
MSG_AMBIGUOUS_INPUT_FOR_ADD |
static java.lang.String |
MSG_ERROR_ADDING_TO_ORDER |
static java.lang.String |
MSG_ERROR_MOVE_TO_PURCHASE_INFO |
static java.lang.String |
MSG_ERROR_REMOVING_ITEM |
static java.lang.String |
MSG_ERROR_UPDATE_ORDER |
static java.lang.String |
MSG_INVALID_QUANTITY |
static java.lang.String |
MSG_NO_ITEMS_TO_ADD |
static java.lang.String |
MSG_NO_ORDER_TO_MODIFY |
static java.lang.String |
MSG_QUANTITY_LESSTHAN_OR_EQUALTO_ZERO |
static java.lang.String |
MSG_QUANTITY_LESSTHAN_ZERO |
static java.lang.String |
MSG_UNSUPPORTED_RELATIONSHIP |
LOCK_NAME_ATTRIBUTE_NAME, PARAM_TRANSACTION_CREATED, PARAM_VALUE_TRUE
PARAM_DEFER_FORWARD_OR_REDIRECT, PARAM_USE_FORWARDS
SERVICE_INFO_KEY
DEFAULT_LOG_TRACE_STATUS
DEFAULT_LOG_DEBUG_STATUS, DEFAULT_LOG_ERROR_STATUS, DEFAULT_LOG_INFO_STATUS, DEFAULT_LOG_WARNING_STATUS
Constructor and Description |
---|
CartModifierFormHandler() |
Modifier and Type | Method and Description |
---|---|
protected void |
addConfigurableItemToOrder(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
Adds one or more commerce items to the order (the shopping cart), using
configurableItemTypeName as the default commerce item type. |
protected void |
addConfigurableItemToOrder(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse,
boolean pIsGift)
Deprecated.
replaced by addConfigurableItemToOrder(DynamoHttpServletRequest, DynamoHttpServletResponse)
|
protected void |
addItemToOrder(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
Adds one or more commerce items to the order (the shopping cart), using
commerceItemType as the default commerce item type. |
protected void |
addItemToOrder(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse,
boolean pIsGift)
Deprecated.
replaced by addItemToOrder(DynamoHttpServletRequest, DynamoHttpServletResponse)
|
protected void |
addItemToShippingGroup(CommerceItem pItem,
int pItemIndex)
Associate a commerce item with the shipping group specified by
the
shippingGroup property. |
protected void |
addMultipleItemsToOrder(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
Adds commerce items to the order (the shopping cart).
|
protected void |
addMultipleItemsToOrder(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse,
boolean pIsGift)
Deprecated.
replaced by addConfigurableItemToOrder(DynamoHttpServletRequest, DynamoHttpServletResponse)
|
protected void |
applyValueDictionary(java.lang.Object pBean,
java.util.Dictionary pValues,
java.lang.String pPropertyPathPrefix)
Copy properties from the value dictionary or one of its descendents.
|
protected CommerceItem |
createCommerceItem(int pItemIndex,
java.lang.String pCatalogKey)
Create a commerce item and add it to the order.
|
protected void |
createConfigurableSubitems(CommerceItem pItem,
int pItemIndex)
Create subitems for a base configurable commerce item.
|
protected void |
createInStorePickupShippingGroups(Order pOrder)
When an item is added to the cart if it contains a locationId in the AddCommerceItemInfo object then
create an InStorePickupShippingGroup for the item to be added to automatically.
|
protected void |
deleteItems(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
This method first validates the elements in RemovalCommerceIds array by calling
prepareLineItemsForRemoval() method.
|
protected void |
deleteItemsByRelationshipId(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
This method is responsible for deleting items from the order by shipping group
commerce item relationship id.
|
protected void |
doAddItemsToOrder(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
Add one or more items to the order (the shopping cart).
|
int |
getAddItemCount()
Returns the number of elements to allocate in the items array
|
java.lang.String |
getAddItemInfoClass()
Returns the name of the class to be used for elements in the items array
|
java.util.List<CommerceItem> |
getAddItemsToOrderResult()
Gets the results of addItemsToOrder.
|
java.lang.String |
getAddItemToOrderChainId()
Returns property AddItemToOrderChainId
|
java.lang.String |
getAddItemToOrderErrorURL()
Returns property AddItemToOrderErrorURL
|
java.lang.String |
getAddItemToOrderPricingOp()
Returns the pricing operation that should be performed when an item is added to the order
|
java.lang.String |
getAddItemToOrderSuccessURL()
Returns property AddItemToOrderSuccessURL
|
java.lang.String |
getAddMultipleItemsToOrderErrorURL()
Returns property AddMultipleItemsToOrderErrorURL
|
java.lang.String |
getAddMultipleItemsToOrderSuccessURL()
Returns property AddMultipleItemsToOrderSuccessURL
|
protected java.lang.String |
getCatalogKey(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
Get a string that will be used to identify the catalog to use when obtaining
a catalogRef and productRef for the creation of a commerce item.
|
java.lang.String[] |
getCatalogRefIds()
Returns property CatalogRefIds
|
java.lang.String[] |
getCommerceIds()
Return the list of CommerceIds to be operated on.
|
java.lang.String |
getCommerceItemType()
Returns the default item type for added commerce items
|
java.lang.String |
getConfigurableItemTypeName()
Returns the configurableItemTypeName
|
CreditCard |
getCreditCard()
Returns credit card bean to use for modifying of billing groups
|
java.lang.String |
getDefaultInStorePickupShippingGroupType()
Gets the defaultInStorePickupShippingGroupType.
|
protected java.util.List |
getDeletedSkus() |
java.lang.String |
getDeleteItemsFromOrderPricingOp()
Returns the pricing operation that should be performed when an item is deleted from the order
|
GiftCertificate |
getGiftCertificate()
Returns gift certificate bean to use for modifying of billing grps
|
java.lang.String |
getGiftlistId()
The giftlist that an item was added from
|
java.lang.String |
getGiftlistItemId()
The giftlist item being added
|
HardgoodShippingGroup |
getHardgoodShippingGroup()
Returns hardgood shipping group bean
|
java.lang.String |
getInputDelimiter()
Returns property InputDelimiter.
|
boolean |
getInvalidQuantityCancelsAdd()
Determine if the FormHandler should treat invalid quantities as errors
when adding multiple items to an order in a single form submission.
|
AddCommerceItemInfo[] |
getItems()
Returns items array of property holders for add operations
|
java.lang.String |
getLocationId() |
java.lang.String |
getModifyOrderPricingOp()
Returns the pricing operation that should be performed when the order is updated
|
java.lang.String |
getMoveToPurchaseInfoByRelIdErrorURL()
Return the moveToPurchaseInfoByRelIdErrorURL property.
|
java.lang.String |
getMoveToPurchaseInfoByRelIdSuccessURL()
Return the moveToPurchaseInfoByRelIdSuccessURL property.
|
java.lang.String |
getMoveToPurchaseInfoChainId()
Returns property MoveToPurchaseInfoChainId
|
java.lang.String |
getMoveToPurchaseInfoErrorURL()
Returns property MoveToPurchaseInfoErrorURL
|
java.lang.String |
getMoveToPurchaseInfoSuccessURL()
Returns property MoveToPurchaseInfoSuccessURL
|
PaymentGroup |
getPaymentGroup()
Returns property PaymentGroup
|
java.lang.String |
getProductId()
Returns property ProductId
|
java.lang.String[] |
getProductIds()
Returns productIds
|
long |
getQuantity()
Returns property Quantity
|
long |
getQuantity(java.lang.String pKey,
DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
Retrieve the total quantity that should be used for the given catalog reference id, commerce item id or relationship id.
|
long |
getQuantityByCatalogRefId(java.lang.String pCatalogRefId,
DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
Retrieve the quantity that should be used for the given catalog reference id
|
long |
getQuantityByCommerceId(java.lang.String pCommerceId,
DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
Retrieve the quantity that should be used for the given commerce item id
|
long |
getQuantityByRelationshipId(java.lang.String pRelationshipId,
DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
Retrieve the quantity that should be used for the given relationship id
|
java.lang.String[] |
getRemovalCatalogRefIds()
Returns property RemovalCatalogRefIds
|
java.lang.String[] |
getRemovalCommerceIds()
Returns property RemovalCommerceIds
|
java.lang.String[] |
getRemovalRelationshipIds()
Return the removalRelationshipIds property.
|
java.lang.String |
getRemoveAndAddItemToOrderErrorURL()
Returns property RemoveAndAddItemToOrderErrorURL
|
java.lang.String |
getRemoveAndAddItemToOrderSuccessURL()
Returns property RemoveAndAddItemToOrderSuccessURL
|
java.lang.String |
getRemoveItemFromOrderByRelationshipIdErrorURL()
Return the RemoveItemFromOrderByRelationshipIdErrorURL property.
|
java.lang.String |
getRemoveItemFromOrderByRelationshipIdSuccessURL()
Return the RemoveItemFromOrderByRelationshipIdSuccessURL property.
|
java.lang.String |
getRemoveItemFromOrderErrorURL()
Returns property RemoveItemFromOrderErrorURL
|
java.lang.String |
getRemoveItemFromOrderSuccessURL()
Returns property RemoveItemFromOrderSuccessURL
|
java.lang.String |
getRepriceOrderErrorURL()
Return the RepriceOrderErrorURL property.
|
java.lang.String |
getRepriceOrderSuccessURL()
Return the RepriceOrderSuccessURL property.
|
java.lang.String |
getSetOrderByRelationshipIdErrorURL()
Return the SetOrderByRelationshipIdErrorURL property.
|
java.lang.String |
getSetOrderByRelationshipIdSuccessURL()
Return the setOrderByRelationshipIdSuccessURL property.
|
java.lang.String |
getSetOrderChainId()
Returns property SetOrderChainId
|
java.lang.String |
getSetOrderErrorURL()
Returns property SetOrderErrorURL
|
java.lang.String |
getSetOrderSuccessURL()
Returns property SetOrderSuccessURL
|
ShippingGroup |
getShippingGroup()
Returns property ShippingGroup.
|
protected java.util.List |
getShippingGroupCommerceItemRelationships(Order pOrder)
Get a list of all the shippingGroupCommerceItemRelationships that are
contained within a particular order.
|
java.lang.String |
getSiteId()
Returns property SiteId
|
java.util.Dictionary |
getValue()
Returns property Value
|
boolean |
handleAddConfigurableItemToOrder(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
This method is used to add configurable items to the order.
|
boolean |
handleAddItemToOrder(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
This method is used to add items to the order.
|
boolean |
handleAddMultipleItemsToOrder(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
This method is used to add items to the order.
|
boolean |
handleMoveToPurchaseInfo(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
This method is called when the user wants to starts the CHECKOUT process
for an order.
|
boolean |
handleMoveToPurchaseInfoByCommerceId(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
This method is called when the user wants to starts the CHECKOUT process for an order.
|
boolean |
handleMoveToPurchaseInfoByRelId(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
This method is called when the user wants to starts the CHECKOUT process
for an order.
|
boolean |
handleRemoveAndAddItemToOrder(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
This method is meant to be used on a page where a user wants to both remove an item
from the order as well as add an item to an order.
|
boolean |
handleRemoveItemFromOrder(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
This will make calls to the preRemoveItemFromOrder method and then will
call the deleteItems method.
|
boolean |
handleRemoveItemFromOrderByRelationshipId(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
This method is similiar to the handleRemoveItemFromOrder method, except that it removes
items from the order via ShippingGroupCommerceItemRelationship object Ids.
|
boolean |
handleSetOrder(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
This method handles all of the work necessary to save
an Order.
|
boolean |
handleSetOrderByCommerceId(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
This method is responsible for adjusting the quantities of commerce items that exist in
a users shopping cart.
|
boolean |
handleSetOrderByRelationshipId(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
This method is responsible for adjusting the quantities of commerce items that exist in
a users shopping cart.
|
boolean |
isCheckForChangedQuantity()
Determine if the FormHandler should check for changes in quantities
of commerce items.
|
protected boolean |
mergeItemInputForAdd(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse,
java.lang.String pCommerceItemType,
boolean pUseProductIds)
Construct or fill in default values in an
items array containing
input values for the methods involved in adding items to orders. |
protected boolean |
mergeValueDictionaries(java.util.Dictionary pCommonValues,
java.util.Dictionary pItemValues,
int pItemIndex,
DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse,
java.lang.String pPropertyPathPrefix)
Merges the common value dictionary into one item-specific value dictionary.
|
protected boolean |
modifyCommerceItemsProperties(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse,
java.util.Map pQuantityChangedItems,
java.util.Map pRemovedItems)
This method is invoked from the modifyOrder*() methods in order
to allow subclasses an opportunity to implement additional
processing after the quantity of items in the order has been
changed.
|
protected void |
modifyOrder(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
Modify the order (accessed from the
order property) based on the changes in the request. |
protected void |
modifyOrderByCommerceId(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
Modify the order (accessed from the
order property) based on the changes in
the request. |
protected void |
modifyOrderByRelationshipId(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
This method causes the contents of a users order to be adjusted by quantity.
|
protected void |
modifyOrderPostReprice(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse,
java.util.Map pQuantityChangedItems,
java.util.Map pRemovedItems) |
void |
postAddItemToOrder(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
Called after all work is done by the handleAddItemToOrder method.
|
void |
postAddMultipleItemsToOrder(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
Called after all work is done by the handleAddMultipleItemsToOrder method.
|
void |
postMoveToPurchaseInfo(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
Called after all processing is done by the moveToPurchaseInfo method.
|
void |
postRemoveAndAddItemToOrder(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
Called after all processing is done by the handleRemoveAndAddItemToOrder method.
|
void |
postRemoveItemFromOrder(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
Called after all processing is done by the removeItemFromOrder method.
|
void |
postRemoveItemFromOrderByRelationshipId(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
This method is currently empty.
|
void |
postSetOrder(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
This is called after all processing is done by the handleSetOrder method.
|
void |
postSetOrderByCommerceId(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
This is called after all processing is done by the
handleSetOrderByCommerceId method.
|
void |
postSetOrderByRelationshipId(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
This is called after all processing is done by the
handleSetOrderByRelationshipId method.
|
void |
preAddItemToOrder(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
Called before any work is done by the handleAddItemToOrder method.
|
void |
preAddMultipleItemsToOrder(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
Called before any work is done by the handleAddMultipleItemsToOrder method.
|
void |
preMoveToPurchaseInfo(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
Called before any processing is done by the moveToPurchaseInfo method.
|
protected java.lang.String[] |
prepareLineItemsForRemoval(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse,
java.lang.String[] pRemovalIDArray,
java.util.Map<java.lang.String,java.lang.Long> pIdToCurrentQuantityMap,
java.util.Map<java.lang.String,java.lang.Long> pRemovalLineItems)
This method will accept the array that has elements to be validated.
|
void |
preRemoveAndAddItemToOrder(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
Called before any processing is done by the handleRemoveAndAddItemToOrder method.
|
void |
preRemoveItemFromOrder(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
Called before any processing is done by the removeItemFromOrder method.
|
void |
preRemoveItemFromOrderByRelationshipId(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
This method is currently empty.
|
void |
preSetOrder(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
This is called before any processing is done by the handleSetOrder method.
|
void |
preSetOrderByCommerceId(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
This is called before any processing is done by the
handleSetOrderByCommerceId method.
|
void |
preSetOrderByRelationshipId(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
This is called before any processing is done by the
handleSetOrderByRelationshipId method.
|
protected void |
processGiftAddition(CommerceItem pItem,
int pItemIndex)
Perform giftlist related processing for an item being ordered
from a giftlist.
|
protected void |
removeInStorePickupShippingGroups(Order pOrder)
Searches through the order and removes any InStorePickupShippingGroups that are no longer associated with any
items on the order.
|
protected void |
runProcessAddItemToOrder(Order pOrder,
CommerceItem pCommerceItem,
PricingModelHolder pPricingModels,
java.util.Locale pLocale,
RepositoryItem pProfile,
java.util.Map pExtraParameters)
Run the pipeline which should be executed when the
handleAddItemToOrder method is invoked
This method will add pCommerceItem to pExtraParameters unless the key
PipelineConstants.COMMERCEITEM is already in the map |
protected void |
runProcessAddItemToOrder(Order pOrder,
PricingModelHolder pPricingModels,
java.util.Locale pLocale,
RepositoryItem pProfile,
java.util.Map pExtraParameters)
Deprecated.
Use runProcessAddItemToOrder(Order, CommerceItem, PricingModelHolder, Locale, RepositoryItem, Map) instead
|
protected void |
runProcessMoveToPurchaseInfo(Order pOrder,
PricingModelHolder pPricingModels,
java.util.Locale pLocale,
RepositoryItem pProfile,
java.util.Map pExtraParameters)
Run the pipeline which should be executed when the
handleMoveToPurchaseInfo method is invoked |
protected void |
runProcessSendScenarioEvent(Order pOrder,
CommerceItem pItem,
long pQuantity,
java.lang.String pType)
The
runProcessSendScenarioEvent method sends a scenario event. |
protected void |
runProcessSendScenarioEvent(Order pOrder,
CommerceItem pItem,
long pQuantity,
java.lang.String pType,
java.lang.String pSiteId)
The
runProcessSendScenarioEvent method sends a scenario event. |
protected void |
runProcessSendScenarioEvent(Order pOrder,
CommerceItem pItem,
java.lang.String pType,
java.util.Map pParams)
The
runProcessSendScenarioEvent method sends a
scenario event . |
protected void |
runProcessSendScenarioEvent(Order pOrder,
CommerceItem pItem,
java.lang.String pType,
java.lang.String pSiteId,
java.util.Map pParams)
The
runProcessSendScenarioEvent method sends a
scenario event . |
protected void |
runProcessSetOrder(Order pOrder,
PricingModelHolder pPricingModels,
java.util.Locale pLocale,
RepositoryItem pProfile,
java.util.Map pExtraParameters)
Run the pipeline which should be executed when the
handleSetOrder method is invoked |
void |
setAddItemCount(int pAddItemCount)
Sets the number of elements to allocate in the items array
and allocates the array
|
void |
setAddItemInfoClass(java.lang.String pAddItemInfoClass)
Sets the name of the class to be used for elements in the items array
|
void |
setAddItemsToOrderResult(java.util.List<CommerceItem> pAddItemsToOrderResult)
Sets the list of items returned from addItemsToOrder.
|
void |
setAddItemToOrderChainId(java.lang.String pAddItemToOrderChainId)
Sets property AddItemToOrderChainId
|
void |
setAddItemToOrderErrorURL(java.lang.String pAddItemToOrderErrorURL)
Sets property AddItemToOrderErrorURL
|
void |
setAddItemToOrderPricingOp(java.lang.String pAddItemToOrderPricingOp)
This property should be set to the type of pricing operation that should be executed when
an item is added to the order.
|
void |
setAddItemToOrderSuccessURL(java.lang.String pAddItemToOrderSuccessURL)
Sets property AddItemToOrderSuccessURL
|
void |
setAddMultipleItemsToOrderErrorURL(java.lang.String pAddMultipleItemsToOrderErrorURL)
Sets property AddMultipleItemsToOrderErrorURL
|
void |
setAddMultipleItemsToOrderSuccessURL(java.lang.String pAddMultipleItemsToOrderSuccessURL)
Sets property AddMultipleItemsToOrderSuccessURL
|
void |
setCatalogRefIds(java.lang.String[] pCatalogRefIds)
Sets property CatalogRefIds
|
void |
setCheckForChangedQuantity(boolean pCheckForChangedQuantity)
Set the checkForChangedQuantity property.
|
void |
setCommerceIds(java.lang.String[] pCommerceIds)
Sets the CommerceIds property which is a list of the CommerceItems to be operated on.
|
protected void |
setCommerceItemProperties(CommerceItem pItem,
int pItemIndex)
Fill in "extra" commerce item properties.
|
void |
setCommerceItemType(java.lang.String pCommerceItemType)
Sets the default item type for added commerce items
|
void |
setConfigurableItemTypeName(java.lang.String pConfigurableItemTypeName)
Sets the configurableItemTypeName
|
void |
setCreditCard(CreditCard pCreditCard)
Sets credit card bean to use for modifying of billing groups
|
void |
setDefaultInStorePickupShippingGroupType(java.lang.String pDefaultInStorePickupShippingGroupType)
Sets the defaultInStorePickupShippingGroupType.
|
protected void |
setDeletedSkus(java.util.List pDeletedSkus)
Deleted skus is a list that maintains which items were removed by the deleteItems call and
is consulted in the addItemToOrder call to determine whether a quantity of 0 is being
added or whether it is simply an artifact of a design that calls handleAddItemToOrder in
the handleRemoveAndAddItem.
|
void |
setDeleteItemsFromOrderPricingOp(java.lang.String pDeleteItemsFromOrderPricingOp)
This property should be set to the type of pricing operation that should be executed when
an item is deleted from the order.
|
void |
setGiftCertificate(GiftCertificate pGiftCertificate)
Sets gift certificate bean to use for modifying of billing grps
|
void |
setGiftlistId(java.lang.String pGiftlistId)
Specifies the id of the Giftlist.
|
void |
setGiftlistItemId(java.lang.String pGiftlistItemId)
Specifies the id of the Giftlist Item
|
void |
setHardgoodShippingGroup(HardgoodShippingGroup pHardgoodShippingGroup)
Sets hardgood shipping group bean
|
void |
setInputDelimiter(java.lang.String pInputDelimiter)
Sets property RemovalSeparator
|
void |
setInvalidQuantityCancelsAdd(boolean pInvalidQuantityCancelsAdd)
Set the invalidQuantityCancelsAdd property.
|
void |
setLocationId(java.lang.String pLocationId) |
void |
setModifyOrderPricingOp(java.lang.String pModifyOrderPricingOp)
This property should be set to the type of pricing operation that should be executed when
the order is updated without adding or removing an item (e.g.
|
void |
setMoveToPurchaseInfoByRelIdErrorURL(java.lang.String pMoveToPurchaseInfoByRelIdErrorURL)
Set the moveToPurchaseInfoByRelIdErrorURL property.
|
void |
setMoveToPurchaseInfoByRelIdSuccessURL(java.lang.String pMoveToPurchaseInfoByRelIdSuccessURL)
Set the moveToPurchaseInfoByRelIdSuccessURL property.
|
void |
setMoveToPurchaseInfoChainId(java.lang.String pMoveToPurchaseInfoChainId)
Sets property MoveToPurchaseInfoChainId
|
void |
setMoveToPurchaseInfoErrorURL(java.lang.String pMoveToPurchaseInfoErrorURL)
Sets property MoveToPurchaseInfoErrorURL
|
void |
setMoveToPurchaseInfoSuccessURL(java.lang.String pMoveToPurchaseInfoSuccessURL)
Sets property MoveToPurchaseInfoSuccessURL
|
void |
setPaymentGroup(PaymentGroup pPaymentGroup)
Sets payment group bean to use for modifying payment groups
|
void |
setProductId(java.lang.String pProductId)
Sets property ProductId
|
void |
setProductIds(java.lang.String[] pProductIds)
Sets productIds
|
void |
setQuantity(long pQuantity)
Sets property Quantity
|
void |
setRemovalCatalogRefIds(java.lang.String[] pRemovalCatalogRefIds)
Sets property RemovalCatalogRefIds
|
void |
setRemovalCommerceIds(java.lang.String[] pRemovalCommerceIds)
Sets property RemovalCommerceIds
|
void |
setRemovalRelationshipIds(java.lang.String[] pRemovalRelationshipIds)
Set the removalRelationshipIds property.
|
void |
setRemoveAndAddItemToOrderErrorURL(java.lang.String pRemoveAndAddItemToOrderErrorURL)
Sets property RemoveAndAddItemToOrderErrorURL
|
void |
setRemoveAndAddItemToOrderSuccessURL(java.lang.String pRemoveAndAddItemToOrderSuccessURL)
Sets property RemoveAndAddItemToOrderSuccessURL
|
void |
setRemoveItemFromOrderByRelationshipIdErrorURL(java.lang.String pRemoveItemFromOrderByRelationshipIdErrorURL)
Set the RemoveItemFromOrderByRelationshipIdErrorURL property.
|
void |
setRemoveItemFromOrderByRelationshipIdSuccessURL(java.lang.String pRemoveItemFromOrderByRelationshipIdSuccessURL)
Set the RemoveItemFromOrderByRelationshipIdSuccessURL property.
|
void |
setRemoveItemFromOrderErrorURL(java.lang.String pRemoveItemFromOrderErrorURL)
Sets property RemoveItemFromOrderErrorURL
|
void |
setRemoveItemFromOrderSuccessURL(java.lang.String pRemoveItemFromOrderSuccessURL)
Sets property RemoveItemFromOrderSuccessURL
|
void |
setRepriceOrderErrorURL(java.lang.String pRepriceOrderErrorURL)
Set the RepriceOrderErrorURL property.
|
void |
setRepriceOrderSuccessURL(java.lang.String pRepriceOrderSuccessURL)
Set the RepriceOrderSuccessURL property.
|
void |
setSetOrderByRelationshipIdErrorURL(java.lang.String pSetOrderByRelationshipIdErrorURL)
Set the SetOrderByRelationshipIdErrorURL property.
|
void |
setSetOrderByRelationshipIdSuccessURL(java.lang.String pSetOrderByRelationshipIdSuccessURL)
Set the setOrderByRelationshipIdSuccessURL property.
|
void |
setSetOrderChainId(java.lang.String pSetOrderChainId)
Sets property SetOrderChainId
|
void |
setSetOrderErrorURL(java.lang.String pSetOrderErrorURL)
Sets property SetOrderErrorURL
|
void |
setSetOrderSuccessURL(java.lang.String pSetOrderSuccessURL)
Sets property SetOrderSuccessURL
|
void |
setShippingGroup(ShippingGroup pShippingGroup)
Sets shipping group bean to use for modifying the shipping groups
|
void |
setSiteId(java.lang.String pSiteId)
Sets property SiteId
|
protected void |
updateOrder(Order pOrder,
java.lang.String pMsgId,
DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
Utility method to update an order and process any exception
that happens during the update.
|
protected boolean |
validateShippingGroupForAdd(DynamoHttpServletRequest pRequest,
DynamoHttpServletResponse pResponse)
Validate shipping information for add operations.
|
acquireTransactionLock, acquireTransactionLock, afterSet, beforeSet, checkFormRedirect, commitTransaction, copyConfiguration, createRepriceParameterMap, defaultLocalLockManager, defaultUserProfile, doStartService, ensureTransaction, formatUserMessage, formatUserMessage, formatUserMessage, formatUserMessage, generatePropertyPath, getClaimableManager, getCommerceIdentifierPaymentInfoContainer, getCommerceItemManager, getCommerceItemShippingInfoContainer, getCommerceProfileTools, getCommercePropertyManager, getConfiguration, getCurrentTransaction, getDefaultLocale, getGiftlistManager, getHandlingInstructionManager, getLocalLockManager, getOrder, getOrderManager, getPaymentGroupManager, getPaymentGroupMapContainer, getPipelineManager, getPriceList, getPriceListId, getPriceListManager, getProfile, getProfileRepository, getPurchaseProcessHelper, getRepeatingRequestMonitor, getRepriceOrderChainId, getResourceBundle, getResourceBundle, getResourceBundleName, getSessionExpirationURL, getShippingGroupManager, getShippingGroupMapContainer, getShoppingCart, getTransactionManager, getUserLocale, getUserLocale, getUserPricingModels, handlePipelineError, isConcurrentUpdate, isEnsureTransaction, isFormSubmission, isTransactionCreated, isTransactionMarkedAsRollBack, isUseLocksAroundTransactions, isUseRequestLocale, processException, processPipelineErrors, releaseTransactionLock, releaseTransactionLock, runProcess, runProcess, runProcess, runProcessRepriceOrder, runProcessRepriceOrder, runRepricingProcess, setClaimableManager, setCommerceIdentifierPaymentInfoContainer, setCommerceItemManager, setCommerceItemShippingInfoContainer, setCommerceProfileTools, setCommercePropertyManager, setConfiguration, setCurrentTransaction, setDefaultLocale, setEnsureTransaction, setGiftlistManager, setHandlingInstructionManager, setLocalLockManager, setOrder, setOrderManager, setPaymentGroupManager, setPaymentGroupMapContainer, setPipelineManager, setPriceListId, setPriceListManager, setProfile, setProfileRepository, setPurchaseProcessHelper, setRepeatingRequestMonitor, setRepriceOrderChainId, setSessionExpirationURL, setShippingGroupManager, setShippingGroupMapContainer, setShoppingCart, setTransactionCreated, setTransactionManager, setTransactionToRollbackOnly, setUseLocksAroundTransactions, setUseRequestLocale, setUserLocale, setUserPricingModels, transactionLockName, unsetTransactionCreated
addFormException, addUncheckedFormException, createFormSubmissionMessage, getCancelURL, getCheckForValidSession, getFormError, getFormExceptions, getFormName, getMessagePort, getMessageSource, getMessageType, getPropertyExceptions, getSendMessages, getUncheckedFormExceptions, handleCancel, handleFormException, handleUncheckedFormException, hasUncheckedFormExceptions, isDeferForwardsAndRedirects, isRestorableForm, isUseForwards, isValidSession, redirectOrForward, resetFormExceptions, setCancelURL, setCheckForValidSession, setDeferForwardsAndRedirects, setFormName, setMessagePort, setMessageSource, setMessageType, setRestorableForm, setSendMessages, setUseForwards
afterGet, beforeGet
addLogListener, createAdminServlet, doStopService, getAbsoluteName, getAdminServlet, getAdminServletOutputStreamEncoding, getLoggingForVlogging, getLogListenerCount, getLogListeners, getName, getNameContext, getNucleus, getRoot, getServiceConfiguration, getServiceInfo, isAdminServletUseServletOutputStream, isLoggingDebug, isLoggingError, isLoggingInfo, isLoggingTrace, isLoggingWarning, isRunning, logDebug, logDebug, logDebug, logError, logError, logError, logInfo, logInfo, logInfo, logTrace, logTrace, logTrace, logWarning, logWarning, logWarning, nameContextElementBound, nameContextElementUnbound, removeLogListener, reResolveThis, resolveName, resolveName, resolveName, resolveName, sendLogEvent, setAdminServletOutputStreamEncoding, setAdminServletUseServletOutputStream, setLoggingDebug, setLoggingError, setLoggingInfo, setLoggingTrace, setLoggingWarning, setNucleus, setServiceInfo, startService, stopService
vlogDebug, vlogDebug, vlogDebug, vlogDebug, vlogDebugTrace, vlogError, vlogError, vlogError, vlogError, vlogInfo, vlogInfo, vlogInfo, vlogInfo, vlogTrace, vlogTrace, vlogTrace, vlogTrace, vlogWarning, vlogWarning, vlogWarning, vlogWarning
public static final java.lang.String CLASS_VERSION
public static final java.lang.String MSG_INVALID_QUANTITY
public static final java.lang.String MSG_ERROR_UPDATE_ORDER
public static final java.lang.String MSG_ERROR_MOVE_TO_PURCHASE_INFO
public static final java.lang.String MSG_ERROR_REMOVING_ITEM
public static final java.lang.String MSG_UNSUPPORTED_RELATIONSHIP
public static final java.lang.String MSG_NO_ITEMS_TO_ADD
public static final java.lang.String MSG_QUANTITY_LESSTHAN_OR_EQUALTO_ZERO
public static final java.lang.String MSG_QUANTITY_LESSTHAN_ZERO
public static final java.lang.String MSG_NO_ORDER_TO_MODIFY
public static final java.lang.String MSG_ERROR_ADDING_TO_ORDER
public static final java.lang.String MSG_AMBIGUOUS_INPUT_FOR_ADD
protected void setDeletedSkus(java.util.List pDeletedSkus)
pDeletedSkus
- - the list of skus that were removedprotected java.util.List getDeletedSkus()
public void setCommerceItemType(java.lang.String pCommerceItemType)
public java.lang.String getCommerceItemType()
public java.lang.String getConfigurableItemTypeName()
public void setConfigurableItemTypeName(java.lang.String pConfigurableItemTypeName)
public void setCatalogRefIds(java.lang.String[] pCatalogRefIds)
pCatalogRefIds
- a String[]
valuepublic java.lang.String[] getCatalogRefIds()
String[]
valuepublic void setCommerceIds(java.lang.String[] pCommerceIds)
pCommerceIds
- a String[]
value of the commerce items to be operated on.public java.lang.String[] getCommerceIds()
String[]
value of the CommerceItem ids to be operated on.public void setProductIds(java.lang.String[] pProductIds)
pProductIds
- a String[]
valuepublic java.lang.String[] getProductIds()
String[]
valuepublic void setProductId(java.lang.String pProductId)
pProductId
- a String
valuepublic java.lang.String getProductId()
String
valuepublic void setSiteId(java.lang.String pSiteId)
pSiteId
- a String
valuepublic java.lang.String getSiteId()
String
valuepublic java.lang.String getLocationId()
public void setLocationId(java.lang.String pLocationId)
pLocationId
- the Location Id to setpublic void setDefaultInStorePickupShippingGroupType(java.lang.String pDefaultInStorePickupShippingGroupType)
public java.lang.String getDefaultInStorePickupShippingGroupType()
public java.util.Dictionary getValue()
Dictionary
containing item level
properties for add operationspublic AddCommerceItemInfo[] getItems()
public void setAddItemInfoClass(java.lang.String pAddItemInfoClass)
public java.lang.String getAddItemInfoClass()
public void setAddItemCount(int pAddItemCount)
pAddItemCount
- an int
valuepublic int getAddItemCount()
int
valuepublic void setQuantity(long pQuantity)
pQuantity
- a long
valuepublic long getQuantity()
long
valuepublic boolean getInvalidQuantityCancelsAdd()
public void setInvalidQuantityCancelsAdd(boolean pInvalidQuantityCancelsAdd)
pInvalidQuantityCancelsAdd
- false if formhandler should add some
items even when others have invalid quantities.public void setPaymentGroup(PaymentGroup pPaymentGroup)
pPaymentGroup
- a PaymentGroup
valuepublic PaymentGroup getPaymentGroup()
PaymentGroup
valuepublic void setCreditCard(CreditCard pCreditCard)
pCreditCard
- a CreditCard
valuepublic CreditCard getCreditCard()
CreditCard
valuepublic void setGiftCertificate(GiftCertificate pGiftCertificate)
pGiftCertificate
- a GiftCertificate
valuepublic GiftCertificate getGiftCertificate()
GiftCertificate
valuepublic void setHardgoodShippingGroup(HardgoodShippingGroup pHardgoodShippingGroup)
pHardgoodShippingGroup
- a HardgoodShippingGroup
valuepublic HardgoodShippingGroup getHardgoodShippingGroup()
HardgoodShippingGroup
valuepublic void setShippingGroup(ShippingGroup pShippingGroup)
pShippingGroup
- a ShippingGroup
valuepublic ShippingGroup getShippingGroup()
ShippingGroup
valuepublic void setGiftlistId(java.lang.String pGiftlistId)
pGiftlistId
- a String
valuepublic java.lang.String getGiftlistId()
String
valuepublic void setGiftlistItemId(java.lang.String pGiftlistItemId)
pGiftlistItemId
- a String
valuepublic java.lang.String getGiftlistItemId()
String
valuepublic void setAddItemToOrderPricingOp(java.lang.String pAddItemToOrderPricingOp)
atg.commerce.pricing.PricingConstants
interface. They include:
ORDER_TOTAL
ORDER_SUBTOTAL
ORDER_SUBTOTAL_SHIPPING
ORDER_SUBTOTAL_TAX
ITEMS
SHIPPING
ORDER
TAX
NO_REPRICE
pAddItemToOrderPricingOp
- a String
valuepublic java.lang.String getAddItemToOrderPricingOp()
String
valuepublic void setAddItemToOrderSuccessURL(java.lang.String pAddItemToOrderSuccessURL)
pAddItemToOrderSuccessURL
- a String
valuepublic java.lang.String getAddItemToOrderSuccessURL()
String
valuepublic void setAddItemToOrderErrorURL(java.lang.String pAddItemToOrderErrorURL)
pAddItemToOrderErrorURL
- a String
valuepublic java.lang.String getAddItemToOrderErrorURL()
String
valuepublic void setAddMultipleItemsToOrderSuccessURL(java.lang.String pAddMultipleItemsToOrderSuccessURL)
pAddMultipleItemsToOrderSuccessURL
- a String
valuepublic java.lang.String getAddMultipleItemsToOrderSuccessURL()
String
valuepublic void setAddMultipleItemsToOrderErrorURL(java.lang.String pAddMultipleItemsToOrderErrorURL)
pAddMultipleItemsToOrderErrorURL
- a String
valuepublic java.lang.String getAddMultipleItemsToOrderErrorURL()
String
valuepublic void setAddItemToOrderChainId(java.lang.String pAddItemToOrderChainId)
pAddItemToOrderChainId
- a String
valuepublic java.lang.String getAddItemToOrderChainId()
String
valuepublic void setRemoveItemFromOrderSuccessURL(java.lang.String pRemoveItemFromOrderSuccessURL)
pRemoveItemFromOrderSuccessURL
- a String
valuepublic java.lang.String getRemoveItemFromOrderSuccessURL()
String
valuepublic void setRemoveItemFromOrderErrorURL(java.lang.String pRemoveItemFromOrderErrorURL)
pRemoveItemFromOrderErrorURL
- a String
valuepublic java.lang.String getRemoveItemFromOrderErrorURL()
String
valuepublic void setRemoveItemFromOrderByRelationshipIdSuccessURL(java.lang.String pRemoveItemFromOrderByRelationshipIdSuccessURL)
pRemoveItemFromOrderByRelationshipIdSuccessURL
- a String
valuepublic java.lang.String getRemoveItemFromOrderByRelationshipIdSuccessURL()
String
valuepublic void setRemoveItemFromOrderByRelationshipIdErrorURL(java.lang.String pRemoveItemFromOrderByRelationshipIdErrorURL)
pRemoveItemFromOrderByRelationshipIdErrorURL
- a String
valuepublic java.lang.String getRemoveItemFromOrderByRelationshipIdErrorURL()
String
valuepublic void setRemoveAndAddItemToOrderErrorURL(java.lang.String pRemoveAndAddItemToOrderErrorURL)
pRemoveAndAddItemToOrderErrorURL
- a String
valuepublic java.lang.String getRemoveAndAddItemToOrderErrorURL()
String
valuepublic void setRemoveAndAddItemToOrderSuccessURL(java.lang.String pRemoveAndAddItemToOrderSuccessURL)
pRemoveAndAddItemToOrderSuccessURL
- a String
valuepublic java.lang.String getRemoveAndAddItemToOrderSuccessURL()
String
valuepublic void setDeleteItemsFromOrderPricingOp(java.lang.String pDeleteItemsFromOrderPricingOp)
atg.commerce.pricing.PricingConstants
interface. They include:
ORDER_TOTAL
ORDER_SUBTOTAL
ORDER_SUBTOTAL_SHIPPING
ORDER_SUBTOTAL_TAX
ITEMS
SHIPPING
ORDER
TAX
NO_REPRICE
pDeleteItemsFromOrderPricingOp
- a String
valuepublic java.lang.String getDeleteItemsFromOrderPricingOp()
String
valuepublic void setModifyOrderPricingOp(java.lang.String pModifyOrderPricingOp)
atg.commerce.pricing.PricingConstants
interface. They include:
ORDER_TOTAL
ORDER_SUBTOTAL
ORDER_SUBTOTAL_SHIPPING
ORDER_SUBTOTAL_TAX
ITEMS
SHIPPING
ORDER
TAX
NO_REPRICE
pModifyOrderPricingOp
- a String
valuepublic java.lang.String getModifyOrderPricingOp()
String
valuepublic void setMoveToPurchaseInfoChainId(java.lang.String pMoveToPurchaseInfoChainId)
pMoveToPurchaseInfoChainId
- a String
valuepublic java.lang.String getMoveToPurchaseInfoChainId()
String
valuepublic void setSetOrderChainId(java.lang.String pSetOrderChainId)
pSetOrderChainId
- a String
valuepublic java.lang.String getSetOrderChainId()
String
valuepublic void setRepriceOrderErrorURL(java.lang.String pRepriceOrderErrorURL)
pRepriceOrderErrorURL
- a String
valuepublic java.lang.String getRepriceOrderErrorURL()
String
valuepublic void setRepriceOrderSuccessURL(java.lang.String pRepriceOrderSuccessURL)
pRepriceOrderSuccessURL
- a String
valuepublic java.lang.String getRepriceOrderSuccessURL()
String
valuepublic void setSetOrderByRelationshipIdSuccessURL(java.lang.String pSetOrderByRelationshipIdSuccessURL)
pSetOrderByRelationshipIdSuccessURL
- a String
valuepublic java.lang.String getSetOrderByRelationshipIdSuccessURL()
String
valuepublic void setSetOrderByRelationshipIdErrorURL(java.lang.String pSetOrderByRelationshipIdErrorURL)
pSetOrderByRelationshipIdErrorURL
- a String
valuepublic java.lang.String getSetOrderByRelationshipIdErrorURL()
String
valuepublic void setSetOrderSuccessURL(java.lang.String pSetOrderSuccessURL)
pSetOrderSuccessURL
- a String
valuepublic java.lang.String getSetOrderSuccessURL()
String
valuepublic void setSetOrderErrorURL(java.lang.String pSetOrderErrorURL)
pSetOrderErrorURL
- a String
valuepublic java.lang.String getSetOrderErrorURL()
String
valuepublic boolean isCheckForChangedQuantity()
public void setCheckForChangedQuantity(boolean pCheckForChangedQuantity)
pCheckForChangedQuantity
- true if formhandler should check for changed
quantities.public void setRemovalCatalogRefIds(java.lang.String[] pRemovalCatalogRefIds)
pRemovalCatalogRefIds
- a String[]
valuepublic java.lang.String[] getRemovalCatalogRefIds()
String[]
valuepublic void setRemovalRelationshipIds(java.lang.String[] pRemovalRelationshipIds)
pRemovalRelationshipIds
- a String[]
valuepublic java.lang.String[] getRemovalRelationshipIds()
String[]
valuepublic void setRemovalCommerceIds(java.lang.String[] pRemovalCommerceIds)
pRemovalCommerceIds
- a String[]
valuepublic java.lang.String[] getRemovalCommerceIds()
String[]
valuepublic java.lang.String getInputDelimiter()
The InputDelimiter can be used to separate two strings within a cascaded string. For example: The String "ci000001#5" has default InputDelimiter separating the CommerceId and the quantity.
String
input delimiter valuepublic void setInputDelimiter(java.lang.String pInputDelimiter)
pRemovalSeparator
- a String
valuepublic void setMoveToPurchaseInfoByRelIdSuccessURL(java.lang.String pMoveToPurchaseInfoByRelIdSuccessURL)
pMoveToPurchaseInfoByRelIdSuccessURL
- a String
valuepublic java.lang.String getMoveToPurchaseInfoByRelIdSuccessURL()
String
valuepublic void setMoveToPurchaseInfoByRelIdErrorURL(java.lang.String pMoveToPurchaseInfoByRelIdErrorURL)
pMoveToPurchaseInfoByRelIdErrorURL
- a String
valuepublic java.lang.String getMoveToPurchaseInfoByRelIdErrorURL()
String
valuepublic void setMoveToPurchaseInfoSuccessURL(java.lang.String pMoveToPurchaseInfoSuccessURL)
pMoveToPurchaseInfoSuccessURL
- a String
valuepublic java.lang.String getMoveToPurchaseInfoSuccessURL()
String
valuepublic void setMoveToPurchaseInfoErrorURL(java.lang.String pMoveToPurchaseInfoErrorURL)
pMoveToPurchaseInfoErrorURL
- a String
valuepublic java.lang.String getMoveToPurchaseInfoErrorURL()
String
valuepublic java.util.List<CommerceItem> getAddItemsToOrderResult()
doAddItemsToOrder(DynamoHttpServletRequest, DynamoHttpServletResponse)
public void setAddItemsToOrderResult(java.util.List<CommerceItem> pAddItemsToOrderResult)
pAddItemsToOrderResult
- The list of items that were returned from addItemsToOrder.doAddItemsToOrder(DynamoHttpServletRequest, DynamoHttpServletResponse)
public boolean handleAddConfigurableItemToOrder(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
pRequest
- the servlet's requestpResponse
- the servlet's responsejavax.servlet.ServletException
- if there was an error while executing the codejava.io.IOException
- if there was an error with servlet ioprotected void addConfigurableItemToOrder(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
configurableItemTypeName
as the default commerce item type.
The list of catalog items to be added comes from the catalogRefIds array
and productId or from the items array.pRequest
- the servlet's requestpResponse
- the servlet's responsejavax.servlet.ServletException
- if there was an error while executing the codejava.io.IOException
- if there was an error with servlet iomergeItemInputForAdd(atg.servlet.DynamoHttpServletRequest, atg.servlet.DynamoHttpServletResponse, java.lang.String, boolean)
,
doAddItemsToOrder(atg.servlet.DynamoHttpServletRequest, atg.servlet.DynamoHttpServletResponse)
protected void addConfigurableItemToOrder(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse, boolean pIsGift) throws javax.servlet.ServletException, java.io.IOException
configurableItemTypeName
as the default commerce item type.
The list of catalog items to be added comes from the catalogRefIds array
and productId or from the items array.pRequest
- the servlet's requestpResponse
- the servlet's responsepIsGift
- ignored, covered by the giftlistId
and
giftlistItemId
propertiesjavax.servlet.ServletException
- if there was an error while executing the codejava.io.IOException
- if there was an error with servlet iopublic long getQuantity(java.lang.String pKey, DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException, java.lang.NumberFormatException
Looks for a request parameter(s) whose key is pKey. The value of the parameter is the quantity. For example:
ci10001=2
If the parameter has more than one value then all those values corresponding to that id will be added up for obtaining the total quantity.
pKey
- a String
value of the sku id, commerce id, relationship id or some other id.pRequest
- a DynamoHttpServletRequest
valuepResponse
- a DynamoHttpServletResponse
valuelong
valuejavax.servlet.ServletException
- if an error occursjava.io.IOException
- if an error occursjava.lang.NumberFormatException
- if an error occurspublic long getQuantityByCatalogRefId(java.lang.String pCatalogRefId, DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException, java.lang.NumberFormatException
Looks for a request parameter whose key is pKey. The value of the parameter is the quantity. For example:
xsku10043=2
pKey
- a String
value of the sku id, commerce id, relationship id or some other id.pRequest
- a DynamoHttpServletRequest
valuepResponse
- a DynamoHttpServletResponse
valuelong
valuejavax.servlet.ServletException
- if an error occursjava.io.IOException
- if an error occursjava.lang.NumberFormatException
- if an error occurspublic long getQuantityByCommerceId(java.lang.String pCommerceId, DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException, java.lang.NumberFormatException
Looks for a request parameter whose key is pKey. The value of the parameter is the quantity. For example:
ci100002=2
pKey
- a String
value of the sku id, commerce id, relationship id or some other id.pRequest
- a DynamoHttpServletRequest
valuepResponse
- a DynamoHttpServletResponse
valuelong
valuejavax.servlet.ServletException
- if an error occursjava.io.IOException
- if an error occursjava.lang.NumberFormatException
- if an error occurspublic long getQuantityByRelationshipId(java.lang.String pRelationshipId, DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException, java.lang.NumberFormatException
Looks for a request parameter whose key is pKey. The value of the parameter is the quantity. For example:
r100002=2
pKey
- a String
value of the sku id, commerce id, relationship id or some other id.pRequest
- a DynamoHttpServletRequest
valuepResponse
- a DynamoHttpServletResponse
valuelong
valuejavax.servlet.ServletException
- if an error occursjava.io.IOException
- if an error occursjava.lang.NumberFormatException
- if an error occursprotected java.lang.String getCatalogKey(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
pRequest
- servlet request objectpResponse
- servlet response objectjavax.servlet.ServletException
- if an error occursjava.io.IOException
- if an error occursCatalogTools
public void preSetOrder(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
pRequest
- the request objectpResponse
- the response objectjavax.servlet.ServletException
- if an error occursjava.io.IOException
- if an error occurspublic void postSetOrder(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
pRequest
- the request objectpResponse
- the response objectjavax.servlet.ServletException
- if an error occursjava.io.IOException
- if an error occurspublic boolean handleSetOrder(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
pRequest
- the servlet's requestpResponse
- the servlet's responseboolean
valuejavax.servlet.ServletException
- if there was an error while executing the codejava.io.IOException
- if there was an error with servlet iomodifyOrder(DynamoHttpServletRequest, DynamoHttpServletResponse)
protected void modifyOrder(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException, CommerceException, RunProcessException
order
property) based on the changes in the request.
This method iterates over each of the current CommerceItems in the order and finds the current
quantity submitted. The quantity values are passed as query parameters with the catalog ref (sku) id
as the key and the quantity as the value like this:
sku100001=2&sku10002=0 *
In addition we check to make sure that the item should even be included in the order any longer. If the quantity is greater than zero we adjust the quantity in the CommerceItem and the ShippingGroupCommerceItemRelationship. Otherwise we remove the CommerceItem and the relationships. Items are identified by their catalogRefId (Sku).
pRequest
- a DynamoHttpServletRequest
valuepResponse
- a DynamoHttpServletResponse
valuejavax.servlet.ServletException
- if an error occursjava.io.IOException
- if an error occursCommerceException
- if an error occursRunProcessException
- if an error occurspublic void preSetOrderByRelationshipId(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
pRequest
- a value of type 'DynamoHttpServletRequest'pResponse
- a value of type 'DynamoHttpServletResponse'javax.servlet.ServletException
- if an error occursjava.io.IOException
- if an error occurspublic void postSetOrderByRelationshipId(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
pRequest
- a value of type 'DynamoHttpServletRequest'pResponse
- a value of type 'DynamoHttpServletResponse'javax.servlet.ServletException
- if an error occursjava.io.IOException
- if an error occurspublic boolean handleSetOrderByRelationshipId(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
pRequest
- the request objectpResponse
- the response objectjavax.servlet.ServletException
- if an error occursjava.io.IOException
- if an error occursmodifyOrderByRelationshipId(DynamoHttpServletRequest, DynamoHttpServletResponse)
public void preSetOrderByCommerceId(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
pRequest
- a value of type 'DynamoHttpServletRequest'pResponse
- a value of type 'DynamoHttpServletResponse'javax.servlet.ServletException
- if an error occursjava.io.IOException
- if an error occurspublic void postSetOrderByCommerceId(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
pRequest
- a value of type 'DynamoHttpServletRequest'pResponse
- a value of type 'DynamoHttpServletResponse'javax.servlet.ServletException
- if an error occursjava.io.IOException
- if an error occurspublic boolean handleSetOrderByCommerceId(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
pRequest
- the request objectpResponse
- the response objectjavax.servlet.ServletException
- if an error occursjava.io.IOException
- if an error occursmodifyOrderByCommerceId(DynamoHttpServletRequest, DynamoHttpServletResponse)
public void preMoveToPurchaseInfo(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
pRequest
- the request objectpResponse
- the response objectjavax.servlet.ServletException
- if an error occursjava.io.IOException
- if an error occurspublic void postMoveToPurchaseInfo(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
pRequest
- the request objectpResponse
- the response objectjavax.servlet.ServletException
- if an error occursjava.io.IOException
- if an error occurspublic boolean handleMoveToPurchaseInfo(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
pRequest
- the servlet's requestpResponse
- the servlet's responseboolean
valuejavax.servlet.ServletException
- if there was an error while executing the codejava.io.IOException
- if there was an error with servlet iopublic boolean handleMoveToPurchaseInfoByRelId(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
pRequest
- the servlet's requestpResponse
- the servlet's responseboolean
valuejavax.servlet.ServletException
- if there was an error while executing the codejava.io.IOException
- if there was an error with servlet ioprotected void modifyOrderByRelationshipId(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException, CommerceException, RunProcessException
xcr100001=2&xcr10002=0
If the quantity is now 0, or the item appears in the removalRelationshipIds array then the quantity will be put to 0. If the original quantity of the shipping group commerce item relationship is equal to the quantity of the commerce item then the commerce item and the relationship are removed from the order. If the quantity is less than the quantity of the commerce item then the relationship is removed and the quantity of the commerce item is adjusted appropriately.
This assumes that the type of relationship being used on the ShippingGroupCommerceItemRelationship is of type SHIPPINGQUANTITY. If it is not, an exception wil be thrown.
pRequest
- a DynamoHttpServletRequest
valuepResponse
- a DynamoHttpServletResponse
valuejavax.servlet.ServletException
- if an error occursjava.io.IOException
- if an error occursCommerceException
- if an error occursRunProcessException
- if an error occurspublic boolean handleMoveToPurchaseInfoByCommerceId(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
pRequest
- the servlet's requestpResponse
- the servlet's responseboolean
valuejavax.servlet.ServletException
- if there was an error while executing the codejava.io.IOException
- if there was an error with servlet ioprotected boolean modifyCommerceItemsProperties(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse, java.util.Map pQuantityChangedItems, java.util.Map pRemovedItems) throws java.io.IOException, CommerceException, javax.servlet.ServletException, RunProcessException
pRequest
- the requestpResponse
- the responsepQuantityChangedItems
- a map of items who's quantities have
been changed. The map key is the commerce item, and the value is
the old quantity.pRemovedItems
- a map of items that have been removed from
the order because their quantity was set to something less than
or equal to zero. 1. The key is the commerce item and the value
is the old quantity. This parameter may be null.java.io.IOException
CommerceException
javax.servlet.ServletException
RunProcessException
protected void modifyOrderPostReprice(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse, java.util.Map pQuantityChangedItems, java.util.Map pRemovedItems) throws java.io.IOException, CommerceException, javax.servlet.ServletException, RunProcessException
pRequest
- the requestpResponse
- the responsepQuantityChangedItems
- a map of items who's quantities have
been changed. The map key is the commerce item, and the value is
the old quantity.pRemovedItems
- a map of items that have been removed from
the order because their quantity was set to something less than
zero. 1. The key is the commerce item and the value is the old
quantity. This parameter may be null.java.io.IOException
CommerceException
javax.servlet.ServletException
RunProcessException
protected void modifyOrderByCommerceId(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException, CommerceException, RunProcessException
order
property) based on the changes in
the request. The quantity values are passed as query parameters with the commerce item id
as the key and the quantity as the value like this:
ci100001=2&ci10002=0
This method iterates over each of the current CommerceItems in the order and finds the current quantity submitted. Note, this replaces the use of modifyOrder method because that method made use of the catalogRefId to identify the commerce item to be modified instead of using the commerce item id itself. In addition we check to make sure that the item should even be included in the order any longer. If the quantity is greater than zero we adjust the quantity in the CommerceItem and the ShippingGroupCommerceItemRelationship. Otherwise we remove the CommerceItem and the relationships.
pRequest
- a DynamoHttpServletRequest
valuepResponse
- a DynamoHttpServletResponse
valuejavax.servlet.ServletException
- if an error occursjava.io.IOException
- if an error occursCommerceException
- if an error occursRunProcessException
- if an error occursprotected java.util.List getShippingGroupCommerceItemRelationships(Order pOrder) throws CommerceException
pOrder
- the order whose relationships will be obtainedCommerceException
- if an error occursprotected void deleteItemsByRelationshipId(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException, CommerceException
pRequest
- the request objectpResponse
- the response objectjavax.servlet.ServletException
- if an error occursjava.io.IOException
- if an error occursCommerceException
- if an error occursprotected void deleteItems(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
pRequest
- servlet request objectpResponse
- servlet response objectjavax.servlet.ServletException
- if an error occursjava.io.IOException
- if an error occursprotected java.lang.String[] prepareLineItemsForRemoval(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse, java.lang.String[] pRemovalIDArray, java.util.Map<java.lang.String,java.lang.Long> pIdToCurrentQuantityMap, java.util.Map<java.lang.String,java.lang.Long> pRemovalLineItems) throws javax.servlet.ServletException, java.io.IOException
pRequest
- The servlet request object. The method needs reference to this object to
be able to Format the user message if an exception is caught.pResponse
- The servlet response object. The method needs reference to this object to
be able to Format the user message if an exception is caught.pRemovalArray
- The array holding string-ids that are to be validated
to check if the corresponding item needs to be removed completely
from order or needs to be removed partially (i.e. quantity adjustment)pIdToCurrentQuantityMap
- The map that holds IDs (commerceId or catalogRefId or relationshipId)
as values and the current quantity in Order corresponding to that ID.pRemovalLineItems
- The map that prepareLineItemsForRemoval() method will update with the ID (as value)
and quantity (as value) by which the current quantity corrsponding to that ID in Order
needs to be decreased. This map is expected to be EMPTY when passed-in.javax.servlet.ServletException
java.io.IOException
public void preAddItemToOrder(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
pRequest
- the request objectpResponse
- the response objectjavax.servlet.ServletException
- if an error occursjava.io.IOException
- if an error occurspublic void postAddItemToOrder(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
pRequest
- the request objectpResponse
- the response objectjavax.servlet.ServletException
- if an error occursjava.io.IOException
- if an error occurspublic boolean handleAddItemToOrder(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
pRequest
- the servlet's requestpResponse
- the servlet's responseboolean
valuejavax.servlet.ServletException
- if there was an error while executing the codejava.io.IOException
- if there was an error with servlet ioprotected void addItemToOrder(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
commerceItemType
as the default commerce item type.
The list of catalog items to be added comes from the catalogRefIds array
and productId or from the items array.pRequest
- the servlet's requestpResponse
- the servlet's responsejavax.servlet.ServletException
- if there was an error while executing the codejava.io.IOException
- if there was an error with servlet iomergeItemInputForAdd(atg.servlet.DynamoHttpServletRequest, atg.servlet.DynamoHttpServletResponse, java.lang.String, boolean)
,
doAddItemsToOrder(atg.servlet.DynamoHttpServletRequest, atg.servlet.DynamoHttpServletResponse)
protected void addItemToOrder(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse, boolean pIsGift) throws javax.servlet.ServletException, java.io.IOException
commerceItemType
as the default commerce item type.
The list of catalog items to be added comes from the catalogRefIds array
and productId or from the items array.pRequest
- the servlet's requestpResponse
- the servlet's responsepIsGift
- ignored, covered by the giftlistId
and
giftlistItemId
propertiesjavax.servlet.ServletException
- if there was an error while executing the codejava.io.IOException
- if there was an error with servlet ioprotected boolean mergeItemInputForAdd(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse, java.lang.String pCommerceItemType, boolean pUseProductIds) throws javax.servlet.ServletException, java.io.IOException
items
array containing
input values for the methods involved in adding items to orders.
Most input validation occurs here, for example:
validateShippingGroup
is called.invalidQuantityCancelsAdd
is true
.
pRequest
- the servlet's requestpResponse
- the servlet's responsepCommerceItemType
- the type to use for creating new commerce itemspUseProductIds
- true
if input comes from
productIds
rather than productId
true
if inputs are valid, false
if notjavax.servlet.ServletException
- if there was an error while executing the codejava.io.IOException
- if there was an error with servlet iovalidateShippingGroupForAdd(atg.servlet.DynamoHttpServletRequest, atg.servlet.DynamoHttpServletResponse)
protected boolean mergeValueDictionaries(java.util.Dictionary pCommonValues, java.util.Dictionary pItemValues, int pItemIndex, DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse, java.lang.String pPropertyPathPrefix) throws javax.servlet.ServletException, java.io.IOException
pCommonValues
- the common dictionarypItemValues
- the item-specific dictionarypItemIndex
- the index of the items
array element that
owns the item-specific dictionarypRequest
- the servlet's requestpResponse
- the servlet's responsepPropertyPathPrefix
- the name prefix for entries in child dictionaries
(null
for the top level dictionaries)javax.servlet.ServletException
- if there was an error while executing the codejava.io.IOException
- if there was an error with servlet ioprotected boolean validateShippingGroupForAdd(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
pRequest
- the servlet's requestpResponse
- the servlet's responsetrue
if inputs are valid, false
if notjavax.servlet.ServletException
- if there was an error while executing the codejava.io.IOException
- if there was an error with servlet ioprotected void doAddItemsToOrder(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
items
array. Items with a quantity
of 0 or less are not added.
This method makes 2 calls:
createInStorePickupShippingGroups(atg.commerce.order.Order)
- create an InStorePickupShippingGroup for the item if it
contains a locationIdPurchaseProcessHelper.addItemsToOrder(atg.commerce.order.Order,
atg.commerce.order.ShippingGroup,
atg.repository.RepositoryItem,
AddCommerceItemInfo[],
java.util.Locale,
String,
atg.commerce.pricing.PricingModelHolder,
atg.commerce.util.PipelineErrorHandler,
java.util.Map)
- add the items to the orderInput property validation is the caller's responsibility.
pRequest
- the servlet's requestpResponse
- the servlet's responsejavax.servlet.ServletException
- if there was an error while executing the codejava.io.IOException
- if there was an error with servlet ioprotected void createInStorePickupShippingGroups(Order pOrder) throws CommerceException
pOrder
- The orderCommerceException
protected void removeInStorePickupShippingGroups(Order pOrder) throws CommerceException
pOrder
- The orderCommerceException
protected CommerceItem createCommerceItem(int pItemIndex, java.lang.String pCatalogKey) throws CommerceException
pItemIndex
- the index of the items
array element that
supplies input for the new itempCatalogKey
- the catalog key reference (locale) for the new itemCommerceException
- if there was an error while executing the codeprotected void setCommerceItemProperties(CommerceItem pItem, int pItemIndex) throws CommerceException
pItem
- the CommerceItempItemIndex
- the index of the items
array element that
supplies input for the commerce itemCommerceException
- if there was an error while executing the codeprotected void applyValueDictionary(java.lang.Object pBean, java.util.Dictionary pValues, java.lang.String pPropertyPathPrefix) throws CommerceException
pBean
- the object to which to copy dictionary valuespValues
- the dictionary from which to copy valuespPropertyPathPrefix
- the name prefix for dictionary entries
(null
for the top level dictionary)CommerceException
- if there was an error while executing the codeprotected void addItemToShippingGroup(CommerceItem pItem, int pItemIndex) throws CommerceException
shippingGroup
property.pItem
- the CommerceItempItemIndex
- the index of the items
array element that
supplies input for the commerce itemCommerceException
- if there was an error while executing the codeprotected void createConfigurableSubitems(CommerceItem pItem, int pItemIndex) throws CommerceException
pItem
- the base CommerceItempItemIndex
- the index of the items
array element that
supplies input for the base commerce itemCommerceException
- if there was an error while executing the codeprotected void processGiftAddition(CommerceItem pItem, int pItemIndex) throws CommerceException
pItem
- the CommerceItempItemIndex
- the index of the items
array element that
supplies input for the commerce itemCommerceException
- if there was an error while executing the codepublic void preAddMultipleItemsToOrder(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
pRequest
- the request objectpResponse
- the response objectjavax.servlet.ServletException
- if an error occursjava.io.IOException
- if an error occurspublic void postAddMultipleItemsToOrder(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
pRequest
- the request objectpResponse
- the response objectjavax.servlet.ServletException
- if an error occursjava.io.IOException
- if an error occurspublic boolean handleAddMultipleItemsToOrder(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
pRequest
- the servlet's requestpResponse
- the servlet's responseboolean
valuejavax.servlet.ServletException
- if there was an error while executing the codejava.io.IOException
- if there was an error with servlet ioprotected void addMultipleItemsToOrder(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
pRequest
- the servlet's requestpResponse
- the servlet's responsejavax.servlet.ServletException
- if there was an error while executing the codejava.io.IOException
- if there was an error with servlet iomergeItemInputForAdd(atg.servlet.DynamoHttpServletRequest, atg.servlet.DynamoHttpServletResponse, java.lang.String, boolean)
,
doAddItemsToOrder(atg.servlet.DynamoHttpServletRequest, atg.servlet.DynamoHttpServletResponse)
protected void addMultipleItemsToOrder(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse, boolean pIsGift) throws javax.servlet.ServletException, java.io.IOException
pRequest
- the servlet's requestpResponse
- the servlet's responsepIsGift
- ignored, covered by the giftlistId
and
giftlistItemId
propertiesjavax.servlet.ServletException
- if there was an error while executing the codejava.io.IOException
- if there was an error with servlet iopublic void preRemoveItemFromOrder(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
pRequest
- the request objectpResponse
- the response objectjavax.servlet.ServletException
- if an error occursjava.io.IOException
- if an error occurspublic void postRemoveItemFromOrder(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
pRequest
- the request objectpResponse
- the response objectjavax.servlet.ServletException
- if an error occursjava.io.IOException
- if an error occurspublic boolean handleRemoveItemFromOrder(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws java.io.IOException, javax.servlet.ServletException
pRequest
- the request objectpResponse
- the resonse objectjava.io.IOException
- if an error occursjavax.servlet.ServletException
- if an error occurspublic void preRemoveItemFromOrderByRelationshipId(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
pRequest
- the request objectpResponse
- the response objectjavax.servlet.ServletException
- if an error occursjava.io.IOException
- if an error occurspublic void postRemoveItemFromOrderByRelationshipId(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
pRequest
- a value of type 'DynamoHttpServletResponse'pResponse
- a value of type 'DynamoHttpServletResponse'javax.servlet.ServletException
- if an error occursjava.io.IOException
- if an error occurspublic boolean handleRemoveItemFromOrderByRelationshipId(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws java.io.IOException, javax.servlet.ServletException
This method will just make a call to the deleteItemsByRelationshipId.
pRequest
- the request objectpResponse
- the response objectjava.io.IOException
- if an error occursjavax.servlet.ServletException
- if an error occurspublic void preRemoveAndAddItemToOrder(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
pRequest
- the request objectpResponse
- the response objectjavax.servlet.ServletException
- if an error occursjava.io.IOException
- if an error occurspublic void postRemoveAndAddItemToOrder(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
pRequest
- the request objectpResponse
- the response objectjavax.servlet.ServletException
- if an error occursjava.io.IOException
- if an error occurspublic boolean handleRemoveAndAddItemToOrder(DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
This method checks to see if any objects have been added to the RemovalCommerceIds property. If they have, then remove them. After removing them call the handleAddItemToOrder method to handle the adding of an item to the order.
pRequest
- servlet's requestpResponse
- servlet's responsejavax.servlet.ServletException
- if an error occursjava.io.IOException
- if an error occursprotected void updateOrder(Order pOrder, java.lang.String pMsgId, DynamoHttpServletRequest pRequest, DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
pOrder
- the order to updatepMsgId
- the message ID to use in case of an exceptionpRequest
- a DynamoHttpServletRequest
valuepResponse
- a DynamoHttpServletResponse
valuejavax.servlet.ServletException
java.io.IOException
protected void runProcessAddItemToOrder(Order pOrder, PricingModelHolder pPricingModels, java.util.Locale pLocale, RepositoryItem pProfile, java.util.Map pExtraParameters) throws RunProcessException
handleAddItemToOrder
method is invokedpOrder
- the order to repricepPricingModels
- the set of all pricing models for the user (item, order, shipping, tax)pLocale
- the locale that the order should be priced withinpProfile
- the user who owns the orderpExtraParameters
- A Map of extra parameters to be used in the pricingRunProcessException
- if an error occursprotected void runProcessAddItemToOrder(Order pOrder, CommerceItem pCommerceItem, PricingModelHolder pPricingModels, java.util.Locale pLocale, RepositoryItem pProfile, java.util.Map pExtraParameters) throws RunProcessException
handleAddItemToOrder
method is invoked
This method will add pCommerceItem to pExtraParameters unless the key
PipelineConstants.COMMERCEITEM is already in the mappOrder
- the order to repricepPricingModels
- the set of all pricing models for the user (item, order, shipping, tax)pLocale
- the locale that the order should be priced withinpProfile
- the user who owns the orderpExtraParameters
- A Map of extra parameters to be used in the pricingRunProcessException
protected void runProcessSendScenarioEvent(Order pOrder, CommerceItem pItem, long pQuantity, java.lang.String pType) throws RunProcessException
runProcessSendScenarioEvent
method sends a scenario event.pOrder
- an Order
valuepItem
- a CommerceItem
valuepQuantity
- the quantity affectedpType
- a String
valueRunProcessException
- if an error occursprotected void runProcessSendScenarioEvent(Order pOrder, CommerceItem pItem, long pQuantity, java.lang.String pType, java.lang.String pSiteId) throws RunProcessException
runProcessSendScenarioEvent
method sends a scenario event.pOrder
- an Order
valuepItem
- a CommerceItem
valuepQuantity
- the quantity affectedpType
- a String
valuepSiteId
- The site ID associated with a scenario eventRunProcessException
- if an error occursprotected void runProcessSendScenarioEvent(Order pOrder, CommerceItem pItem, java.lang.String pType, java.util.Map pParams) throws RunProcessException
runProcessSendScenarioEvent
method sends a
scenario event .pOrder
- an Order
valuepItem
- a CommerceItem
valuepType
- a String
valuepParams
- a map with event specific parametersRunProcessException
- if an error occursprotected void runProcessSendScenarioEvent(Order pOrder, CommerceItem pItem, java.lang.String pType, java.lang.String pSiteId, java.util.Map pParams) throws RunProcessException
runProcessSendScenarioEvent
method sends a
scenario event .pOrder
- an Order
valuepItem
- a CommerceItem
valuepType
- a String
valuepSiteId
- The site ID associated with a scenario eventpParams
- a map with event specific parametersRunProcessException
- if an error occursprotected void runProcessSetOrder(Order pOrder, PricingModelHolder pPricingModels, java.util.Locale pLocale, RepositoryItem pProfile, java.util.Map pExtraParameters) throws RunProcessException
handleSetOrder
method is invokedpOrder
- the order to repricepPricingModels
- the set of all pricing models for the user (item, order, shipping, tax)pLocale
- the locale that the order should be priced withinpProfile
- the user who owns the orderpExtraParameters
- A Map of extra parameters to be used in the pricingRunProcessException
- if an error occursprotected void runProcessMoveToPurchaseInfo(Order pOrder, PricingModelHolder pPricingModels, java.util.Locale pLocale, RepositoryItem pProfile, java.util.Map pExtraParameters) throws RunProcessException
handleMoveToPurchaseInfo
method is invokedpOrder
- the order to repricepPricingModels
- the set of all pricing models for the user (item, order, shipping, tax)pLocale
- the locale that the order should be priced withinpProfile
- the user who owns the orderpExtraParameters
- A Map of extra parameters to be used in the pricingRunProcessException
- if an error occurs