Quoting operations are also initiated with the /atg/commerce/order/purchase/QuoteFormHandler. By default, the form handler contains the following properties:
Property | Description |
|---|---|
| The ID of the order used in the form handler operation. |
| A note from the customer that accompanies the quote request. |
| The page that the customer is directed to if the form handler successfully submits the order for a quote. |
| The page that the customer is directed to if an error occurs during quote submission. |
| The page that the customer is directed to if the form handler successfully resubmits the order for a quote. |
| The page that the customer is directed to if an error occurs during the quote resubmission. |
| The page that the customer is directed to if the form handler successfully submits the quoted order. |
| The page that the customer is directed to if there is an error while completing the checkout of a quoted order. |
| The page that the customer is directed to if the quote rejection request is successful. |
| The page that the customer is directed to if there is an error during the rejection of a quote. |
| The page that the customer is directed to when the quote is completed successfully. |
| The page that the customer is directed to if there is an error when completing the quote. |
| The map parameters used for the completion of a quote. |
The QuoteFormHandler, which extends the PurchasProcessFormHandler, has a number of handle methods. These handle methods have corresponding premethodName, postmethodName, and methodName methods. For example, the handleRequestQuote method has corresponding preRequestQuote, postRequestQuote and requestQuote methods. A handle method calls its premethodName method before executing its methodName method. Likewise, it calls its postmethodName method after executing its methodName method. The pre and post methods provide an easy way to extend the functionality of the handle methods.
The QuoteFormHandler also has a set of successURL and errorURL properties that map to its handle methods. For example, handleRejectQuote has corresponding rejectQuoteSuccessURL and rejectQuoteErrorURL properties. After a handle method executes, you can use these properties to redirect the customer to pages other than those specified by the form’s action attribute. The redirected page’s content depends on the type of operation and whether the operation succeeded or not. For example, if an attempt to request a quote fails, you could redirect the customer to a page explaining what caused the failure.
The value of the redirect properties is a URL relative to the action page of the form. You can either specify the values of these URL properties in the properties of the form handler or you can set them in the JSP itself using a hidden tag attribute.
The QuoteFormHandler uses the following handle methods:
The
requestQuotemethod is used during the submission of an order for quoting. It obtains the properties used to construct thequoteInfoobjects, which are needed by thePrepareForQuoteRequestpipeline processor. Once the order has been validated, the form handler callsOrderManager.requestQuoteto initiate therequestQuotepipeline chain. If therequestQuotepipeline chain is successful, thequoteInfoobject is added to the order and the order’s status is set to PENDING_QUOTE. Once therequestQuotepipeline has been invoked, therequestQuoteform handler method creates a new order in theOrderHolder.The
requestRequotemethod performs the same actions as therequestQuotemethod, but does not modify theOrderHolder.The
completeQuotemethod is used once your third-party quoting system has completed its quoting process and it ready to submit a quote to a customer. Once this method receives anorderIdand thecompleteQuoteParametersMap, it calls theOrderManager.completeQuotemethod.The
acceptQuotemethod is used to accept the quoted order and initiate the repricing and checkout process. Once this method receives anorderId, it callsOrderManager.acceptQuoteto complete the checkout process by running theprocessOrderWithRepricepipeline chain.The
rejectQuotemethod is used when a customer rejects a quote. Once this method receives anorderId, it callsOrderManager.rejectQuoteto run therejectQuotepipeline chain. The order’s status is set to REJECTED_QUOTE.
For detailed information on working with form handlers, refer to the Page Developer's Guide. For information on working with the OrderManager, refer to the Updating an Order with the OrderManager section.

