atg.commerce.csr.order
Class CSRShippingGroupFormHandler

java.lang.Object
  extended by atg.nucleus.logging.VariableArgumentApplicationLoggingImpl
      extended by atg.nucleus.GenericService
          extended by atg.droplet.EmptyFormHandler
              extended by atg.droplet.GenericFormHandler
                  extended by atg.commerce.order.purchase.PurchaseProcessFormHandler
                      extended by atg.commerce.order.purchase.ShippingGroupFormHandler
                          extended by atg.commerce.csr.order.CSRShippingGroupFormHandler
All Implemented Interfaces:
atg.commerce.util.PipelineErrorHandler, atg.droplet.DropletFormHandler, atg.naming.NameContextBindingListener, atg.naming.NameContextElement, atg.naming.NameResolver, atg.nucleus.AdminableService, atg.nucleus.logging.ApplicationLogging, atg.nucleus.logging.ApplicationLoggingSender, atg.nucleus.logging.TraceApplicationLogging, atg.nucleus.logging.VariableArgumentApplicationLogging, atg.nucleus.naming.ComponentNameResolver, atg.nucleus.Service, atg.nucleus.ServiceListener, java.util.EventListener

public class CSRShippingGroupFormHandler
extends atg.commerce.order.purchase.ShippingGroupFormHandler

The CSRShippingGroupFormHandler adds audit-logging capabilities to the ShippingGroupFormHandler

See Also:
ShippingGroupFormHandler

Field Summary
static java.lang.String CLASS_VERSION
           
static java.lang.String COULD_NOT_ADD_SHIPPING_GROUP
           
static java.lang.String ERROR_WHILE_APPLYING_EXCG_ORDER_PMTS
           
static java.lang.String ERROR_WHILE_FETCHING_PRICE_LIST
           
static java.lang.String ERROR_WHILE_PERSISTING_ORDER
           
static java.lang.String ERROR_WHILE_REPRICING_ORDER
           
static java.lang.String HARD_GOOD
           
static java.lang.String JSON_ERROR_ATTRIBUTE
           
protected  CSRAgentTools mCSRAgentTools
           
protected  java.lang.String mPostApplyShippingGroupsPricingOp
           
static java.lang.String MSG_ERROR_DURING_PAYMENT_GROUPS_VALIDATION
           
static java.lang.String MY_RESOURCE_NAME
           
static java.lang.String NULL_SHIPPING_GROUP_NAME
           
 
Fields inherited from class atg.commerce.order.purchase.ShippingGroupFormHandler
mAllHardgoodCommerceItemShippingInfos, mConsolidateShippingInfosBeforeApply, mElectronicShippingGroups, MSG_ERROR_UPDATE_SHIPPINGGROUP, MSG_INVALID_SHIPPING_SPLIT_NUMBER, MSG_NO_DEFAULT_SHIPPING_GROUP, mValidateShippingGroups
 
Fields inherited from class atg.commerce.order.purchase.PurchaseProcessFormHandler
LOCK_NAME_ATTRIBUTE_NAME, PARAM_TRANSACTION_CREATED, PARAM_VALUE_TRUE
 
Fields inherited from class atg.droplet.GenericFormHandler
PARAM_DEFER_FORWARD_OR_REDIRECT, PARAM_USE_FORWARDS
 
Fields inherited from class atg.nucleus.GenericService
SERVICE_INFO_KEY
 
Fields inherited from interface atg.nucleus.logging.TraceApplicationLogging
DEFAULT_LOG_TRACE_STATUS
 
Fields inherited from interface atg.nucleus.logging.ApplicationLogging
DEFAULT_LOG_DEBUG_STATUS, DEFAULT_LOG_ERROR_STATUS, DEFAULT_LOG_INFO_STATUS, DEFAULT_LOG_WARNING_STATUS
 
Constructor Summary
CSRShippingGroupFormHandler()
           
 
Method Summary
 void addShippingGroupValidationErrors(java.util.Collection pFormExceptions)
          The form errors are not added to the request.
 java.lang.String applyExchangeProcessPayments(java.lang.String pHandlerSuccessURL)
          This method calls ReturnManager.applyExchangeProcessPayments() and applies the payment between the original order and replacement order.
 void applyShippingMethods(atg.servlet.DynamoHttpServletRequest pRequest, atg.servlet.DynamoHttpServletResponse pResponse)
          applyShippingMethods is used in the multiple shipping functionality.
protected  void changeShippingGroupForCommerceItemShippingInfos(java.util.Collection pCommerceItemShippingInfos, java.lang.String pShippingGroupName, java.lang.String pShippingMethod)
          Changes the shipping group name and shipping method for a collection of items in the CommerceItemShippingInfoContainer
 java.util.Map createRepriceParameterMap()
          Creates the extra parameter map that is used when the order is repriced after form handler modifications to the order.
 CSRAgentMessagingTools getAgentMessagingTools()
          Returns component for sending agent messages
 java.lang.String getApplyShippingMethodsErrorURL()
           
 java.lang.String getApplyShippingMethodsSuccessURL()
           
 java.lang.String getCompleteOrderPageURL()
          Returns the completeOrderPageURL.
 CSRCreateHardgoodShippingGroupFormHandler getCreateHardgoodShippingGroupFormHandler()
           
 CSRAgentTools getCSRAgentTools()
           
 java.lang.String getModifyOrderPricingOp()
          Returns the pricing operation that should be performed when the order is updated
 java.lang.String getNewAddressNickname()
           
 java.lang.String getPostApplyShippingGroupsPricingOp()
          Returns the pricing operation used after apply shipping groups
protected  atg.repository.RepositoryItem getPriceList()
          This method over-rides the core commerce form handler method.
 java.lang.String getRefundMethodsPageURL()
          Returns the refundMethodsPageURL.
 ReturnManager getReturnManager()
          Returns the returnManager.
 java.lang.String getShippingMethod()
           
 java.lang.String getShipToAddressNickname()
           
 java.lang.String getSingleShippingGroupCheckoutErrorURL()
           
 java.lang.String getSingleShippingGroupCheckoutSuccessURL()
           
 atg.commerce.pricing.PricingModelHolder getSubmittedOrderPricingModels()
          Returns property SubmittedOrderPricingModels
 java.lang.String getTicketId()
          Returns the Id of the current ticket
 java.util.Locale getUserLocale(atg.servlet.DynamoHttpServletRequest pRequest, atg.servlet.DynamoHttpServletResponse pResponse)
          This method over-rides the core commerce method and calls CSRAgentTools.getActiveCustomerPricingLocale() to get the locale.
 atg.commerce.pricing.PricingModelHolder getUserPricingModels()
          Returns the userPricingModels if the order is in one of the incomplete states define by CSRAgentTools.
 boolean handleApplyShippingMethods(atg.servlet.DynamoHttpServletRequest pRequest, atg.servlet.DynamoHttpServletResponse pResponse)
          This method is used in the multiple shipping functionality.
 boolean handlePreserveUserInputOnServerSide(atg.servlet.DynamoHttpServletRequest pRequest, atg.servlet.DynamoHttpServletResponse pResponse)
          This method is used to preserve any user inputs in the server's memeory.
 boolean handleSingleShippingGroupCheckout(atg.servlet.DynamoHttpServletRequest pRequest, atg.servlet.DynamoHttpServletResponse pResponse)
          This method is specifically used single shipping pages.
 boolean isMultipleNonGiftHardgoodItems()
          Determines if the total quantity of all non-gift hardgood items is more than one.
 boolean isPersistOrder()
           
 void postApplyShippingGroups(atg.servlet.DynamoHttpServletRequest pRequest, atg.servlet.DynamoHttpServletResponse pResponse)
          postApplyShippingGroups is for work that must happen after the ShippingGroups are applied.
 void postApplyShippingMethods(atg.servlet.DynamoHttpServletRequest pRequest, atg.servlet.DynamoHttpServletResponse pResponse)
          postApplyShippingMethods is for work that must happen after the user selections are saved.
 void postPreserveUserInputOnServerSide(atg.servlet.DynamoHttpServletRequest pRequest, atg.servlet.DynamoHttpServletResponse pResponse)
          postPreserveUserInputOnServerSide is for work that must happen after the user selections are saved.
 void postSingleShippingGroupCheckout(atg.servlet.DynamoHttpServletRequest pRequest, atg.servlet.DynamoHttpServletResponse pResponse)
          This method is used for ShippingGroupCheckout post processing.
 void preApplyShippingMethods(atg.servlet.DynamoHttpServletRequest pRequest, atg.servlet.DynamoHttpServletResponse pResponse)
          preApplyShippingMethods is for work that must happen before the user selections are retained.
 void prePreserveUserInputOnServerSide(atg.servlet.DynamoHttpServletRequest pRequest, atg.servlet.DynamoHttpServletResponse pResponse)
          prePreserveUserInputOnServerSide is for work that must happen before the user selections are retained.
 void preSingleShippingGroupCheckout(atg.servlet.DynamoHttpServletRequest pRequest, atg.servlet.DynamoHttpServletResponse pResponse)
          This method is used for ShippingGroupCheckout pre processing.
 void runProcessValidatePaymentGroups(atg.commerce.order.Order pOrder, java.util.Locale pLocale, java.util.Map pExtraParameters)
          runProcessValidatePaymentGroups runs a configurable Pipeline chain to validate PaymentGroups or to prepare for the next checkout phase.
 void setAgentMessagingTools(CSRAgentMessagingTools pAgentMessagingTools)
          Sets the component for sending agent messages
 void setApplyShippingMethodsErrorURL(java.lang.String pApplyShippingMethodsErrorURL)
           
 void setApplyShippingMethodsSuccessURL(java.lang.String pApplyShippingMethodsSuccessURL)
           
 void setCompleteOrderPageURL(java.lang.String pCompleteOrderPageURL)
          Sets the completeOrderPageURL.
 void setCreateHardgoodShippingGroupFormHandler(CSRCreateHardgoodShippingGroupFormHandler pCreateHardgoodShippingGroupFormHandler)
           
 void setCSRAgentTools(CSRAgentTools pCSRAgentTools)
          Sets the property CSRAgentTools.
 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 setNewAddressNickname(java.lang.String pNewAddressNickname)
           
 void setPersistOrder(boolean pPersistOrder)
           
 void setPostApplyShippingGroupsPricingOp(java.lang.String pPostApplyShippingGroupsPricingOp)
           
 void setRefundMethodsPageURL(java.lang.String pRefundMethodsPageURL)
          Sets the refundMethodsPageURL.
 void setReturnManager(ReturnManager pReturnManager)
          Sets the returnManager.
 void setShippingMethod(java.lang.String pShippingMethod)
           
 void setShipToAddressNickname(java.lang.String pShipToAddressNickname)
           
 void setSingleShippingGroupCheckoutErrorURL(java.lang.String pSingleShippingGroupCheckoutErrorURL)
           
 void setSingleShippingGroupCheckoutSuccessURL(java.lang.String pSingleShippingGroupCheckoutSuccessURL)
           
 void setSubmittedOrderPricingModels(atg.commerce.pricing.PricingModelHolder pSubmittedOrderPricingModels)
          Sets property SubmittedOrderPricingModels
 void singleShippingGroupCheckout(atg.servlet.DynamoHttpServletRequest pRequest, atg.servlet.DynamoHttpServletResponse pResponse)
          In CSC application, in single shipping page, agnet could add a shipping group or select an existing address and shipping methods.
protected  void splitCommerceItemShippingInfoByQuantity(atg.commerce.order.purchase.CommerceItemShippingInfo pCommerceItemShippingInfo, long pSplitQuantity)
          splitCommerceItemShippingInfoByQuantity extends the corresponding method in ShippingGroupFormHandler.
 
Methods inherited from class atg.commerce.order.purchase.ShippingGroupFormHandler
addShippingGroupToMap, applyCommerceItemShippingInfo, applyDefaultShippingGroup, applyShippingGroups, consolidateShippingInfos, getAllHardgoodCommerceItemShippingInfos, getApplyShippingGroupsErrorURL, getApplyShippingGroupsSuccessURL, getCurrentList, getCurrentShippingGroup, getDefaultShippingGroupName, getElectronicShippingGroups, getFirstNonGiftHardgoodShippingGroupWithRels, getGiftShippingGroups, getListId, getLocale, getNonGiftHardgoodShippingGroupCount, getNonGiftHardgoodShippingGroups, getShippingGroup, getShippingGroupId, getShippingGroupInitializers, getSpecifyDefaultShippingGroupErrorURL, getSpecifyDefaultShippingGroupSuccessURL, getSplitShippingInfosErrorURL, getSplitShippingInfosSuccessURL, getValidateShippingGroupsChainId, handleApplyShippingGroups, handleSpecifyDefaultShippingGroup, handleSplitShippingInfos, isAnyElectronicShippingGroups, isAnyHardgoodShippingGroups, isAnyNonGiftHardgoodShippingGroups, isApplyDefaultShippingGroup, isConsolidateShippingInfosBeforeApply, isMultipleHardgoodShippingGroupsWithRelationships, isMultipleNonGiftHardgoodShippingGroups, isShippingGroupInOrder, isValidateShippingGroups, mergeCommerceItemShippingInfos, postSpecifyDefaultShippingGroup, postSplitShippingInfos, preApplyShippingGroups, preSpecifyDefaultShippingGroup, preSplitShippingInfos, removeShippingGroupFromMap, runProcessValidateShippingGroups, setApplyDefaultShippingGroup, setApplyShippingGroupsErrorURL, setApplyShippingGroupsSuccessURL, setConsolidateShippingInfosBeforeApply, setCurrentList, setCurrentShippingGroup, setDefaultShippingGroupName, setListId, setLocale, setShippingGroupId, setShippingGroupInitializers, setSpecifyDefaultShippingGroupErrorURL, setSpecifyDefaultShippingGroupSuccessURL, setSplitShippingInfosErrorURL, setSplitShippingInfosSuccessURL, setValidateShippingGroups, setValidateShippingGroupsChainId, specifyDefaultShippingGroup, splitShippingInfos
 
Methods inherited from class atg.commerce.order.purchase.PurchaseProcessFormHandler
acquireTransactionLock, acquireTransactionLock, afterSet, beforeSet, checkFormRedirect, commitTransaction, copyConfiguration, 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, getPriceListId, getPriceListManager, getProfile, getProfileRepository, getPurchaseProcessHelper, getRepeatingRequestMonitor, getRepriceOrderChainId, getResourceBundle, getResourceBundleName, getSessionExpirationURL, getShippingGroupManager, getShippingGroupMapContainer, getShoppingCart, getTransactionManager, getUserLocale, handlePipelineError, 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
 
Methods inherited from class atg.droplet.GenericFormHandler
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
 
Methods inherited from class atg.droplet.EmptyFormHandler
afterGet, beforeGet
 
Methods inherited from class atg.nucleus.GenericService
addLogListener, createAdminServlet, doStopService, getAbsoluteName, getAdminServlet, getLoggingForVlogging, getLogListenerCount, getLogListeners, getName, getNameContext, getNucleus, getRoot, getServiceConfiguration, getServiceInfo, isLoggingDebug, isLoggingError, isLoggingInfo, isLoggingTrace, isLoggingWarning, isRunning, logDebug, logDebug, logDebug, logError, logError, logError, logInfo, logInfo, logInfo, logTrace, logTrace, logTrace, logWarning, logWarning, logWarning, nameContextElementBound, nameContextElementUnbound, removeLogListener, resolveName, resolveName, resolveName, resolveName, sendLogEvent, setLoggingDebug, setLoggingError, setLoggingInfo, setLoggingTrace, setLoggingWarning, setNucleus, setServiceInfo, startService, stopService
 
Methods inherited from class atg.nucleus.logging.VariableArgumentApplicationLoggingImpl
vlogDebug, vlogDebug, vlogDebug, vlogDebug, vlogError, vlogError, vlogError, vlogError, vlogInfo, vlogInfo, vlogInfo, vlogInfo, vlogTrace, vlogTrace, vlogTrace, vlogTrace, vlogWarning, vlogWarning, vlogWarning, vlogWarning
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CLASS_VERSION

public static final java.lang.String CLASS_VERSION
See Also:
Constant Field Values

MY_RESOURCE_NAME

public static final java.lang.String MY_RESOURCE_NAME
See Also:
Constant Field Values

JSON_ERROR_ATTRIBUTE

public static final java.lang.String JSON_ERROR_ATTRIBUTE
See Also:
Constant Field Values

COULD_NOT_ADD_SHIPPING_GROUP

public static final java.lang.String COULD_NOT_ADD_SHIPPING_GROUP
See Also:
Constant Field Values

NULL_SHIPPING_GROUP_NAME

public static final java.lang.String NULL_SHIPPING_GROUP_NAME
See Also:
Constant Field Values

ERROR_WHILE_PERSISTING_ORDER

public static final java.lang.String ERROR_WHILE_PERSISTING_ORDER
See Also:
Constant Field Values

ERROR_WHILE_REPRICING_ORDER

public static final java.lang.String ERROR_WHILE_REPRICING_ORDER
See Also:
Constant Field Values

ERROR_WHILE_FETCHING_PRICE_LIST

public static final java.lang.String ERROR_WHILE_FETCHING_PRICE_LIST
See Also:
Constant Field Values

ERROR_WHILE_APPLYING_EXCG_ORDER_PMTS

public static final java.lang.String ERROR_WHILE_APPLYING_EXCG_ORDER_PMTS
See Also:
Constant Field Values

MSG_ERROR_DURING_PAYMENT_GROUPS_VALIDATION

public static final java.lang.String MSG_ERROR_DURING_PAYMENT_GROUPS_VALIDATION
See Also:
Constant Field Values

HARD_GOOD

public static final java.lang.String HARD_GOOD
See Also:
Constant Field Values

mPostApplyShippingGroupsPricingOp

protected java.lang.String mPostApplyShippingGroupsPricingOp

mCSRAgentTools

protected CSRAgentTools mCSRAgentTools
Constructor Detail

CSRShippingGroupFormHandler

public CSRShippingGroupFormHandler()
Method Detail

getPostApplyShippingGroupsPricingOp

public java.lang.String getPostApplyShippingGroupsPricingOp()
Returns the pricing operation used after apply shipping groups

Default is PricingConstants.OP_REPRICE_ORDER_TOTAL

Returns:

setPostApplyShippingGroupsPricingOp

public void setPostApplyShippingGroupsPricingOp(java.lang.String pPostApplyShippingGroupsPricingOp)

getCompleteOrderPageURL

public java.lang.String getCompleteOrderPageURL()
Returns the completeOrderPageURL.

Returns:
completeOrderPageURL

setCompleteOrderPageURL

public void setCompleteOrderPageURL(java.lang.String pCompleteOrderPageURL)
Sets the completeOrderPageURL.

Parameters:
pCompleteOrderPageURL -

getRefundMethodsPageURL

public java.lang.String getRefundMethodsPageURL()
Returns the refundMethodsPageURL.

Returns:
refundMethodsPageURL

setRefundMethodsPageURL

public void setRefundMethodsPageURL(java.lang.String pRefundMethodsPageURL)
Sets the refundMethodsPageURL.

Parameters:
pRefundMethodsPageURL -

getReturnManager

public ReturnManager getReturnManager()
Returns the returnManager.

Returns:
returnManager

setReturnManager

public void setReturnManager(ReturnManager pReturnManager)
Sets the returnManager.

Parameters:
pReturnManager -

getApplyShippingMethodsErrorURL

public java.lang.String getApplyShippingMethodsErrorURL()
Returns:
the applyShippingMethodsErrorURL

setApplyShippingMethodsErrorURL

public void setApplyShippingMethodsErrorURL(java.lang.String pApplyShippingMethodsErrorURL)
Parameters:
pApplyShippingMethodsErrorURL - The applyShippingMethodsErrorURL to set.

getApplyShippingMethodsSuccessURL

public java.lang.String getApplyShippingMethodsSuccessURL()
Returns:
the applyShippingMethodsSuccessURL

setApplyShippingMethodsSuccessURL

public void setApplyShippingMethodsSuccessURL(java.lang.String pApplyShippingMethodsSuccessURL)
Parameters:
pApplyShippingMethodsSuccessURL - The applyShippingMethodsSuccessURL to set.

isPersistOrder

public boolean isPersistOrder()
Returns:
the persistOrder

setPersistOrder

public void setPersistOrder(boolean pPersistOrder)
Parameters:
pPersistOrder - The persistOrder to set.

getSingleShippingGroupCheckoutErrorURL

public java.lang.String getSingleShippingGroupCheckoutErrorURL()
Returns:
Returns the singleShippingGroupCheckoutErrorURL.

setSingleShippingGroupCheckoutErrorURL

public void setSingleShippingGroupCheckoutErrorURL(java.lang.String pSingleShippingGroupCheckoutErrorURL)
Parameters:
pSingleShippingGroupCheckoutErrorURL - The singleShippingGroupCheckoutErrorURL to set.

getSingleShippingGroupCheckoutSuccessURL

public java.lang.String getSingleShippingGroupCheckoutSuccessURL()
Returns:
Returns the singleShippingGroupCheckoutSuccessURL.

setSingleShippingGroupCheckoutSuccessURL

public void setSingleShippingGroupCheckoutSuccessURL(java.lang.String pSingleShippingGroupCheckoutSuccessURL)
Parameters:
pSingleShippingGroupCheckoutSuccessURL - The singleShippingGroupCheckoutSuccessURL to set.

getCreateHardgoodShippingGroupFormHandler

public CSRCreateHardgoodShippingGroupFormHandler getCreateHardgoodShippingGroupFormHandler()
Returns:
Returns the createHardgoodShippingGroupFormHandler.

setCreateHardgoodShippingGroupFormHandler

public void setCreateHardgoodShippingGroupFormHandler(CSRCreateHardgoodShippingGroupFormHandler pCreateHardgoodShippingGroupFormHandler)
Parameters:
pCreateHardgoodShippingGroupFormHandler - The createHardgoodShippingGroupFormHandler to set.

getShippingMethod

public java.lang.String getShippingMethod()
Returns:
Returns the shippingMethod.

setShippingMethod

public void setShippingMethod(java.lang.String pShippingMethod)
Parameters:
pShippingMethod - The shippingMethod to set.

setModifyOrderPricingOp

public 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. quantity change). The operations which are acceptable are defined in the atg.commerce.pricing.PricingConstants interface. They include: If this value is null, then the system will default to ORDER_TOTAL.

Parameters:
pModifyOrderPricingOp - a String value

getModifyOrderPricingOp

public java.lang.String getModifyOrderPricingOp()
Returns the pricing operation that should be performed when the order is updated

Returns:
a String value

getUserPricingModels

public atg.commerce.pricing.PricingModelHolder getUserPricingModels()
Returns the userPricingModels if the order is in one of the incomplete states define by CSRAgentTools. Otherwise, the value of submittedOrderPricingModels is returned.

Overrides:
getUserPricingModels in class atg.commerce.order.purchase.PurchaseProcessFormHandler
Returns:
a PricingModelHolder value

setSubmittedOrderPricingModels

public void setSubmittedOrderPricingModels(atg.commerce.pricing.PricingModelHolder pSubmittedOrderPricingModels)
Sets property SubmittedOrderPricingModels

Parameters:
pSubmittedOrderPricingModels - a SubmittedOrderPricingModels value

getSubmittedOrderPricingModels

public atg.commerce.pricing.PricingModelHolder getSubmittedOrderPricingModels()
Returns property SubmittedOrderPricingModels

Returns:
a SubmittedOrderPricingModels value

setCSRAgentTools

public void setCSRAgentTools(CSRAgentTools pCSRAgentTools)
Sets the property CSRAgentTools.


getCSRAgentTools

public CSRAgentTools getCSRAgentTools()
Returns:
The value of the property CSRAgentTools.

setAgentMessagingTools

public void setAgentMessagingTools(CSRAgentMessagingTools pAgentMessagingTools)
Sets the component for sending agent messages

Parameters:
pAgentMessagingTools -

getAgentMessagingTools

public CSRAgentMessagingTools getAgentMessagingTools()
Returns component for sending agent messages

Returns:
AgentMessagingTools

getShipToAddressNickname

public java.lang.String getShipToAddressNickname()
Returns:
Returns the shipToAddressNickname.

setShipToAddressNickname

public void setShipToAddressNickname(java.lang.String pShipToAddressNickname)
Parameters:
pShipToAddressNickname - The shipToAddressNickname to set.

getNewAddressNickname

public java.lang.String getNewAddressNickname()
Returns:
Returns the newAddressNickname.

setNewAddressNickname

public void setNewAddressNickname(java.lang.String pNewAddressNickname)
Parameters:
pNewAddressNickname - The newAddressNickname to set.

getTicketId

public java.lang.String getTicketId()
Returns the Id of the current ticket


postApplyShippingGroups

public void postApplyShippingGroups(atg.servlet.DynamoHttpServletRequest pRequest,
                                    atg.servlet.DynamoHttpServletResponse pResponse)
                             throws javax.servlet.ServletException,
                                    java.io.IOException
postApplyShippingGroups is for work that must happen after the ShippingGroups are applied.

Overrides:
postApplyShippingGroups in class atg.commerce.order.purchase.ShippingGroupFormHandler
Parameters:
pRequest - a DynamoHttpServletRequest value
pResponse - a DynamoHttpServletResponse value
Throws:
javax.servlet.ServletException - if an error occurs
java.io.IOException - if an error occurs

splitCommerceItemShippingInfoByQuantity

protected void splitCommerceItemShippingInfoByQuantity(atg.commerce.order.purchase.CommerceItemShippingInfo pCommerceItemShippingInfo,
                                                       long pSplitQuantity)
splitCommerceItemShippingInfoByQuantity extends the corresponding method in ShippingGroupFormHandler. It will send a SplitShippingGroup event that will be captured by the audit-logging system

Overrides:
splitCommerceItemShippingInfoByQuantity in class atg.commerce.order.purchase.ShippingGroupFormHandler
Parameters:
pCommerceItemShippingInfo - a CommerceItemShippingInfo value
pSplitQuantity - a long value

preSingleShippingGroupCheckout

public void preSingleShippingGroupCheckout(atg.servlet.DynamoHttpServletRequest pRequest,
                                           atg.servlet.DynamoHttpServletResponse pResponse)
                                    throws javax.servlet.ServletException,
                                           java.io.IOException
This method is used for ShippingGroupCheckout pre processing.

Parameters:
pRequest -
pResponse -
Throws:
javax.servlet.ServletException
java.io.IOException

handleSingleShippingGroupCheckout

public boolean handleSingleShippingGroupCheckout(atg.servlet.DynamoHttpServletRequest pRequest,
                                                 atg.servlet.DynamoHttpServletResponse pResponse)
                                          throws javax.servlet.ServletException,
                                                 java.io.IOException
This method is specifically used single shipping pages. This method performs the necessary things to perform single shipping.

Parameters:
pRequest -
pResponse -
Returns:
Throws:
javax.servlet.ServletException
java.io.IOException

postSingleShippingGroupCheckout

public void postSingleShippingGroupCheckout(atg.servlet.DynamoHttpServletRequest pRequest,
                                            atg.servlet.DynamoHttpServletResponse pResponse)
                                     throws javax.servlet.ServletException,
                                            java.io.IOException
This method is used for ShippingGroupCheckout post processing.

Parameters:
pRequest -
pResponse -
Throws:
javax.servlet.ServletException
java.io.IOException

singleShippingGroupCheckout

public void singleShippingGroupCheckout(atg.servlet.DynamoHttpServletRequest pRequest,
                                        atg.servlet.DynamoHttpServletResponse pResponse)
                                 throws javax.servlet.ServletException,
                                        java.io.IOException
In CSC application, in single shipping page, agnet could add a shipping group or select an existing address and shipping methods. This method identifies whether an agent wants to add an shipping group or use the existing shipping address. If the creation new shipping group is desired, this method calls CreateHardgoodShippingGroupFormHandler to create a new address. Also if the use of existing or new shipping group is desired, then this method applies the shipping groups to the order.

Parameters:
pRequest -
pResponse -
Throws:
javax.servlet.ServletException
java.io.IOException
See Also:
ShippingGroupFormHandler.applyShippingGroups(DynamoHttpServletRequest, DynamoHttpServletResponse)

addShippingGroupValidationErrors

public void addShippingGroupValidationErrors(java.util.Collection pFormExceptions)
The form errors are not added to the request. If the errors are added to request, then those errors will show up in the messaging UI

Parameters:
pFormExceptions -
See Also:
-- This method uses CreateHardgoodFormHandler to add a shipping group. but the error messages are not added to the request. This method adds the errors to the request.

changeShippingGroupForCommerceItemShippingInfos

protected void changeShippingGroupForCommerceItemShippingInfos(java.util.Collection pCommerceItemShippingInfos,
                                                               java.lang.String pShippingGroupName,
                                                               java.lang.String pShippingMethod)
Changes the shipping group name and shipping method for a collection of items in the CommerceItemShippingInfoContainer

Parameters:
pCommerceItemShippingInfos - the colection of items to change
pShippingGroupName - if this is not null, each info item's shipping group name is set to this value
pShippingMethod - if this is not null, each info item's shipping method is set to this value.

handlePreserveUserInputOnServerSide

public boolean handlePreserveUserInputOnServerSide(atg.servlet.DynamoHttpServletRequest pRequest,
                                                   atg.servlet.DynamoHttpServletResponse pResponse)
                                            throws javax.servlet.ServletException,
                                                   java.io.IOException
This method is used to preserve any user inputs in the server's memeory. For example if an agent is in the multiple shipping page and the mutlitipe shipping page has few drop downs and edit icon to edit an address. If the agent changes the values in the drop down and prefers to click on the edit icon to edit an address. The edit address action will refresh the multiple shipping page with current information (without the user's selection. because it is not saved in the server object). In order to retain the user information, they have to call this method to preserve the user input or selections. This method creates a json object and sends them in the response. The data or response receiving layer should understand text/json data stream.

Parameters:
pRequest -
pResponse -
Returns:
Throws:
javax.servlet.ServletException
java.io.IOException

prePreserveUserInputOnServerSide

public void prePreserveUserInputOnServerSide(atg.servlet.DynamoHttpServletRequest pRequest,
                                             atg.servlet.DynamoHttpServletResponse pResponse)
                                      throws javax.servlet.ServletException,
                                             java.io.IOException
prePreserveUserInputOnServerSide is for work that must happen before the user selections are retained.

Parameters:
pRequest - a DynamoHttpServletRequest value
pResponse - a DynamoHttpServletResponse value
Throws:
javax.servlet.ServletException - if an error occurs
java.io.IOException - if an error occurs

postPreserveUserInputOnServerSide

public void postPreserveUserInputOnServerSide(atg.servlet.DynamoHttpServletRequest pRequest,
                                              atg.servlet.DynamoHttpServletResponse pResponse)
                                       throws javax.servlet.ServletException,
                                              java.io.IOException
postPreserveUserInputOnServerSide is for work that must happen after the user selections are saved.

Parameters:
pRequest - a DynamoHttpServletRequest value
pResponse - a DynamoHttpServletResponse value
Throws:
javax.servlet.ServletException - if an error occurs
java.io.IOException - if an error occurs

handleApplyShippingMethods

public boolean handleApplyShippingMethods(atg.servlet.DynamoHttpServletRequest pRequest,
                                          atg.servlet.DynamoHttpServletResponse pResponse)
                                   throws javax.servlet.ServletException,
                                          java.io.IOException
This method is used in the multiple shipping functionality. This method allows us to save the user selected shipping methods for the shipping groups. In addition to that user's could save the order if is transient.

Parameters:
pRequest -
pResponse -
Returns:
Throws:
javax.servlet.ServletException
java.io.IOException

applyShippingMethods

public void applyShippingMethods(atg.servlet.DynamoHttpServletRequest pRequest,
                                 atg.servlet.DynamoHttpServletResponse pResponse)
                          throws javax.servlet.ServletException,
                                 java.io.IOException
applyShippingMethods is used in the multiple shipping functionality. This method allows us to save the user selected shipping methods for the shipping groups. In addition to that user's could save the order if is transient.

Parameters:
pRequest - a DynamoHttpServletRequest value
pResponse - a DynamoHttpServletResponse value
Throws:
javax.servlet.ServletException - if an error occurs
java.io.IOException - if an error occurs

preApplyShippingMethods

public void preApplyShippingMethods(atg.servlet.DynamoHttpServletRequest pRequest,
                                    atg.servlet.DynamoHttpServletResponse pResponse)
                             throws javax.servlet.ServletException,
                                    java.io.IOException
preApplyShippingMethods is for work that must happen before the user selections are retained.

Parameters:
pRequest - a DynamoHttpServletRequest value
pResponse - a DynamoHttpServletResponse value
Throws:
javax.servlet.ServletException - if an error occurs
java.io.IOException - if an error occurs

postApplyShippingMethods

public void postApplyShippingMethods(atg.servlet.DynamoHttpServletRequest pRequest,
                                     atg.servlet.DynamoHttpServletResponse pResponse)
                              throws javax.servlet.ServletException,
                                     java.io.IOException
postApplyShippingMethods is for work that must happen after the user selections are saved.

Parameters:
pRequest - a DynamoHttpServletRequest value
pResponse - a DynamoHttpServletResponse value
Throws:
javax.servlet.ServletException - if an error occurs
java.io.IOException - if an error occurs

createRepriceParameterMap

public java.util.Map createRepriceParameterMap()
Creates the extra parameter map that is used when the order is repriced after form handler modifications to the order.

Overrides:
createRepriceParameterMap in class atg.commerce.order.purchase.PurchaseProcessFormHandler
Returns:
Map of parameters or null

getPriceList

protected atg.repository.RepositoryItem getPriceList()
This method over-rides the core commerce form handler method. This method makes the call to CSREnvironmentTools.getCurrentPriceList() and returns the current pricelist.

Overrides:
getPriceList in class atg.commerce.order.purchase.PurchaseProcessFormHandler
Returns:
a RepositoryItem
See Also:
atg.commerce.csr.util.CSREnvironmentTools.getCurrentPriceList()

applyExchangeProcessPayments

public java.lang.String applyExchangeProcessPayments(java.lang.String pHandlerSuccessURL)
This method calls ReturnManager.applyExchangeProcessPayments() and applies the payment between the original order and replacement order. After appling the payments, this method provides the success urls.

Parameters:
pHandlerSuccessURL -
Returns:

runProcessValidatePaymentGroups

public void runProcessValidatePaymentGroups(atg.commerce.order.Order pOrder,
                                            java.util.Locale pLocale,
                                            java.util.Map pExtraParameters)
                                     throws atg.service.pipeline.RunProcessException
runProcessValidatePaymentGroups runs a configurable Pipeline chain to validate PaymentGroups or to prepare for the next checkout phase.

Parameters:
pOrder - an Order value
pPricingModels - a PricingModelHolder value
pLocale - a Locale value
pProfile - a RepositoryItem value
pExtraParameters - a Map value
Throws:
atg.service.pipeline.RunProcessException - if an error occurs

getUserLocale

public java.util.Locale getUserLocale(atg.servlet.DynamoHttpServletRequest pRequest,
                                      atg.servlet.DynamoHttpServletResponse pResponse)
                               throws javax.servlet.ServletException,
                                      java.io.IOException
This method over-rides the core commerce method and calls CSRAgentTools.getActiveCustomerPricingLocale() to get the locale. The CSC agents are working on a customer's orders. Because of the above reason, the application has to load customer's default locale.

Overrides:
getUserLocale in class atg.commerce.order.purchase.PurchaseProcessFormHandler
Parameters:
pRequest - a DynamoHttpServletRequest value
pResponse - a DynamoHttpServletResponse value
Returns:
a Locale value
Throws:
javax.servlet.ServletException - if an error occurs
java.io.IOException - if an error occurs
See Also:
CSRAgentTools.getActiveCustomerPricingLocale()

isMultipleNonGiftHardgoodItems

public boolean isMultipleNonGiftHardgoodItems()
Determines if the total quantity of all non-gift hardgood items is more than one.

Returns:
true if the the non-gift hg item quantity is more than one.