This global method updates the prices of the line items after the cart is split.


static Id updatePriceForCart(Id cartId)

Request Parameter
cartIDIDYesThe Id of the cart for which you want to update prices of the line item

Response Parameter
jobIdIDThe Id of the batch job executed to update the pricing of the cart

Code Sample

This sample enables you to update the price of the line items after the cart is split. When the method is executed, the task pending flag is set to true on the cart passed as the parameter. After pricing is calculated for the line items, the flag is set to false.

//Api to price large cart (pass in either Main Cart Id or Config Cart Id), if there is a change in any pricing parameter post split.
This would set the task pending flag on the cart passed as the parameter (either main or config). When all carts are priced, the flag is cleared.

ID jobId = Apttus_Config2.BatchJobService.updatePriceForCart(mainOrConfigCartId);