public class StoreCartProcessHelper extends StorePurchaseProcessHelper
Extends the StorePurchaseProcessHelper to implement cart processing helper methods.
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
CLASS_VERSION
Class version string
|
protected atg.userprofiling.ProfileTools |
mProfileTools
property: profileTools
|
static java.lang.String |
MSG_ERROR_ADDING_TO_GIFTLIST
Error adding to giftlist message resource key.
|
static java.lang.String |
MSG_ERROR_MODIFYING_ORDER
Error modifying order message resource key.
|
static java.lang.String |
MSG_INVALID_ITEMS
Invalid items message resource key.
|
static java.lang.String |
MSG_INVALID_RECIPIENT_EMAIL
Invalid recipient e-mail address resource key.
|
static java.lang.String |
MSG_INVALID_SENDER_EMAIL
Invalid sender e-mail address.
|
static java.lang.String |
MSG_NO_ITEMS_SELECT
No items selected message resource key.
|
ADDRESS_PROP_NAME, CITY_PROP_NAME, COUNTRY_PROP_NAME, FIRST_NAME_PROP_NAME, LAST_NAME_PROP_NAME, MSG_MISSING_REQUIRED_ADDRESS_PROPERTY, MSG_MULTIPLE_COUPONS_PER_ORDER, MSG_UNCLAIMABLE_COUPON, POSTAL_CODE_PROP_NAME, PRICING_ERROR, PRICING_ERROR_ADDRESS, STATE_PROP_NAME
ERROR_FETCHING_PROFILE, MSG_ERROR_ADDING_CREDIT_CARD, MSG_ERROR_ADDING_SHIPPINGGROUP, MSG_ERROR_ADDING_TO_ORDER, MSG_ERROR_CHANGING_ITEM_QUANTITY, MSG_ERROR_CREATING_ORDER, MSG_ERROR_MOVING_ITEM_BETWEEN_SHIPPING_GROUPS, MSG_ERROR_PROCESS_ADD_ITEM_CHAIN, MSG_ERROR_REMOVING_ITEM, MSG_ERROR_REMOVING_ITEM_FROM_SHIPPING_GROUP, MSG_ERROR_REPRICING_ORDER_AFTER_ADD_ITEM, MSG_ERROR_SETTING_ORDER_AMOUNT, MSG_INVALID_PROFILE_ID
Constructor and Description |
---|
StoreCartProcessHelper() |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
addItemsToGiftlist(java.lang.String pGiftlistId,
atg.commerce.order.purchase.AddCommerceItemInfo[] pItems,
atg.commerce.gifts.GiftlistManager pGiftlistManager)
Adds the given item(s) to the selected gift list.
|
void |
addRemoveGiftServices(StoreOrderImpl pStoreOrder,
boolean pAddGiftWrap,
boolean pAddGiftMessage,
java.lang.String pGiftWrapSkuId,
java.lang.String pGiftWrapProductId)
This method can be used by form handlers to add / remove gift message or
gift-wrap from the order.
|
boolean |
areItemsInCatalog(atg.commerce.order.Order pOrder)
Check if all items on the order are in the catalog.
|
atg.userprofiling.PropertyManager |
getProfilePropertyManager() |
atg.userprofiling.ProfileTools |
getProfileTools() |
int |
getSecurityStatus(atg.repository.RepositoryItem pProfile)
Get the current security status from the provided profile.
|
boolean |
isAllGiftWrap(StoreOrderImpl pOrder)
Check to see if the order contains only gift wrap items.
|
boolean |
isAuthorizedUser(atg.repository.RepositoryItem pProfile)
Check the security status of the profile to see if the user is authorized.
|
boolean |
isGiftWrapAddedOrRemoved(StoreOrderImpl pOrder,
boolean pGiftWrapSelected)
Check to see if gift-wrap has been added or removed from the order.
|
boolean |
isLoginUser(atg.repository.RepositoryItem pProfile)
Check the security status of the profile to see if the user is logged in.
|
void |
rollbackTransaction(javax.transaction.TransactionManager pTransactionManager)
Rollback the provided transaction.
|
void |
setProfilePropertyManager(atg.userprofiling.PropertyManager pProfilePropertyManager) |
void |
setProfileTools(atg.userprofiling.ProfileTools pProfileTools) |
checkForRequiredAddressProperties, claimCoupon, claimCoupon, getAddressPropertyNameMap, getClaimableManager, getMandatoryStateCountryList, getPlaceUtils, getPricingTools, getRequiredAddressPropertyNames, getStoreConfiguration, getStoreOrderTools, removeCoupon, removeCoupon, repriceOrder, setAddressPropertyNameMap, setClaimableManager, setPlaceUtils, setPricingTools, setRequiredAddressPropertyNames, setStoreConfiguration, setStoreOrderTools, tenderCoupon
addCreditCardToOrder, addItemsToOrder, addItemsToOrder, addItemToOrder, addItemToShippingGroup, addShippingAddressToOrder, addShippingAddressToOrder, adjustItemRelationshipsForQuantityChange, adjustNonGiftHandlingInstructionsForQuantityDecrease, adjustNonGiftHandlingInstructionsForQuantityIncrease, applyValueDictionary, changeItemQuantity, changeItemQuantity, copyCreditCardInfo, createCommerceItem, createConfigurableSubitems, createOrder, decreaseRelationshipQuantity, deleteItem, deleteItems, deleteItems, getAddItemToOrderChainId, getAddItemToOrderPricingOp, getCommerceItemManager, getDefaultHardgoodShippingGroupType, getDeleteItemsFromOrderPricingOp, getFirstShippingGroup, getGiftlistManager, getInStorePickupShippingGroupForItem, getOrderManager, getPipelineManager, getRepriceOrderChainId, getShippingGroupForItem, getShippingGroupManager, getTransactionManager, increaseRelationshipQuantity, isAddItemToDefaultShippingGroup, isInStorePickupShippingGroupValidForItem, isTransactionMarkedAsRollBack, moveItemBetweenShippingGroups, postAddItemsToOrder, postDeleteItem, postDeleteItem, postDeleteItem, postDeleteItem, processGiftAddition, processPipelineErrors, removeEntireRelationshipQuantity, removeItemQuantityFromShippingGroup, runProcess, runProcess, runProcess, runProcessAddItemToOrder, runProcessRepriceOrder, runProcessSendScenarioEvent, runProcessSendScenarioEvent, runProcessSendScenarioEvent, runProcessSendScenarioEvent, runProcessSendScenarioEvent, runRepricingProcess, setAddItemToDefaultShippingGroup, setAddItemToOrderChainId, setAddItemToOrderPricingOp, setCommerceItemManager, setCommerceItemProperties, setDefaultHardgoodShippingGroupType, setDeleteItemsFromOrderPricingOp, setGiftlistManager, setOrderAmountToPaymentGroup, setOrderManager, setPipelineManager, setRepriceOrderChainId, setShippingGroupManager, setTransactionManager
addLogListener, createAdminServlet, doStartService, 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, toString
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_ERROR_MODIFYING_ORDER
public static final java.lang.String MSG_ERROR_ADDING_TO_GIFTLIST
public static final java.lang.String MSG_NO_ITEMS_SELECT
public static final java.lang.String MSG_INVALID_ITEMS
public static final java.lang.String MSG_INVALID_RECIPIENT_EMAIL
public static final java.lang.String MSG_INVALID_SENDER_EMAIL
protected atg.userprofiling.ProfileTools mProfileTools
public atg.userprofiling.ProfileTools getProfileTools()
public void setProfileTools(atg.userprofiling.ProfileTools pProfileTools)
pProfileTools
- - the profile tools to set.public void setProfilePropertyManager(atg.userprofiling.PropertyManager pProfilePropertyManager)
pProfilePropertyManager
- - the property manager for profiles, used to see if the user is logged in.public atg.userprofiling.PropertyManager getProfilePropertyManager()
public java.lang.String addItemsToGiftlist(java.lang.String pGiftlistId, atg.commerce.order.purchase.AddCommerceItemInfo[] pItems, atg.commerce.gifts.GiftlistManager pGiftlistManager) throws javax.servlet.ServletException, java.io.IOException, atg.commerce.CommerceException
Adds the given item(s) to the selected gift list.
This method uses the AddCommerceItemInfo items to determine which SKUs and quantities to add to the gift list.
pGiftlistId
- - A String
value.pItems
- - The items to add to the gift list, a AddCommerceItemInfo[]
value.pGiftlistManager
- - The gift list manager, a GiftlistManager
value.javax.servlet.ServletException
- if there was an error while executing the code.java.io.IOException
- if there was an error with servlet io.atg.commerce.CommerceException
- indicates that a severe error occurred while performing a commerce operation.public boolean areItemsInCatalog(atg.commerce.order.Order pOrder)
pOrder
- - the Order
to process.pOrderManager
- - the order manager object.public int getSecurityStatus(atg.repository.RepositoryItem pProfile)
pProfile
- - the profile to get the security status of.int
value.public boolean isGiftWrapAddedOrRemoved(StoreOrderImpl pOrder, boolean pGiftWrapSelected)
pOrder
- - the Order
to process.pGiftWrapSelected
- - value for whether or not gift-wrap is selected, a boolean
value.boolean
value.public boolean isAllGiftWrap(StoreOrderImpl pOrder)
pOrder
- - An Order
value.boolean
value.public boolean isAuthorizedUser(atg.repository.RepositoryItem pProfile)
pProfile
- - the profile to be checked.boolean
value.public boolean isLoginUser(atg.repository.RepositoryItem pProfile)
pProfile
- - the profile to be checked.boolean
value.public void rollbackTransaction(javax.transaction.TransactionManager pTransactionManager)
pTransactionManager
- - Transaction Manager containing the transaction to roll-back,public void addRemoveGiftServices(StoreOrderImpl pStoreOrder, boolean pAddGiftWrap, boolean pAddGiftMessage, java.lang.String pGiftWrapSkuId, java.lang.String pGiftWrapProductId) throws atg.commerce.CommerceException
pStoreOrder
- - the order.pAddGiftWrap
- - boolean value indicating whether or not to add gift wrap.pAddGiftMessage
- - boolean value indicating whether or not to add gift message.pGiftWrapSkuId
- - String value indicating Sku Id of the gift wrapped.pGiftWrapProductId
- - String value indicating Product Id of the gift wrapped.atg.commerce.CommerceException