Job Quotes API handler
Return a collection job quotes.
HTTP Verb – GET
URL – /api/v1/jobquotes
Description – Return a collection job quotes
Base – HandlerBase<GetJobQuoteCollectionParameter, GetJobQuoteCollectionResult>
Handlers –
Order | Handler | Description |
---|---|---|
500 | GetJobQuoteCollectionHandler | Gets a collection of current job quotes by either the current user or if the current user is a salesperson, then by that salesperson for the current bill to customer. |
Order | Handler | Description |
---|---|---|
500 | ValidateContext | If UserProfile object has no value, a forbidden error is returned. |
600 | CreateQuery | Creates the job quotes query. Applies filters and expands. The query is stored in the JobQuotesQuery property in the result object. |
700 | CreateGetJobQuoteResults | Executes the JobQuotesQuery, map result to the GetJobQuoteResult objects and stores it in the GetJobQuoteResults property in the result object. |
HTTP Verb – GET
URL – /api/v1/jobquotes/{jobQuoteId}
Description – Return a single job quote record
Base – HandlerBase<GetJobQuoteParameter, GetJobQuoteResult>
Handlers –
Order | Handler | Description |
---|---|---|
500 | GetJobQuoteHandler | If user cannot view quote, then JobQuoteAccessDenied error result is returned, otherwise gets the job quote for the jobQuoteId. |
Order | Handler | Description |
---|---|---|
500 | GetCart | Retrieves a cart using the GetCartHandler handler chain. If access to the cart is denied, an access denied error is returned. The cart is stored in the GetCartResult property in the result object. |
600 | CreateGetJobQuoteResult | Maps GetCartResult to the result object. Updates result properties. Maps GetCartResult.CartLineResults to the GetJobQuoteLineResult objects and stores it in the JobQuoteLineResults property in the result object. |
700 | GetOrderLineQtySold | If cart status equal "JobAccepted", then retrieves sold quantity for each order line and stores it in the OrderLineQtySold property in the result object. |
HTTP Verb – PATCH
URL – /api/v1/jobquotes/{jobQuoteId}
Description – Update a single job quote record
Base – HandlerBase<UpdateJobQuoteParameter, UpdateJobQuoteResult>
Handlers –
Order | Handler | Description |
---|---|---|
500 | UpdateJobQuoteHandler | If order quantities are not valid, then JobQuoteServiceJobQuoteNotFound error result is returned, otherwise updates the job quote for the jobQuoteId. |
Order | Handler | Description |
---|---|---|
500 | ValidateContext | Retrieves a job quote using the GetJobQuote handler chain. The job quote is stored in the GetJobQuoteResult property in the result object. Validates job quote quantities. If quantities are incorrect, an error is returned. |
600 | CreateNewOrder | Creates a new customer order by GetJobQuoteResult.Cart property, maps it to the GetCartResult object and stores it in the GetCartResult property in the result object. |
700 | CopyOrderLines | Creates a copies of the GetJobQuoteResult.Cart.OrderLines objects. Sets QtyOrdered, UnitOfMeasure and QtyShipped properties to it. Adds a copies of order lines to the cart using AddCartLine pipeline. |
800 | CopyOrderLineRfqs | Creates a copies of the OrderLineRfq objects from GetJobQuoteResult.Cart.OrderLines. Inserts it to the database. |
Updated over 1 year ago