We’ve to follow some steps :-
- The Scriptable Cart should be enabled in the website setup record.
- We can create a new integer field for updating the quantity and a checkbox for enabling the feature in the item record. And we have to update the client script for updating the price level in the item line in the cart.
- If the checkbox is enabled and the quantity is equal to greater than the number in the newly created field. Then we have updated the price from the respective price level.
- If the quantity is less, then the price should be online price ( if there is any promotion available it should that price).
- We can use any pricelevel for the testing purpose.
For achieving this promotion we’ve to edit some files for the updating the prices.
Here are the details of same :-
To achieve this need to update a Client Script and Some dev code files. And also added a new file in dev code. Here are details of the same.
Client Script
Name – OTGN-445 JJ CS Promotion item Update
Files and Folders used for this update.
- Modules\custom\CartCustom@1.0.0\JavaScript\Cart.Lines.View.js
- Modules\custom\HeaderCustom@1.0.0\JavaScript\Header.MiniCart.View.js
These files update the price in the cart page while looking Australian promotion.
Created two custom fields in NetSuite account for achieving this solution here are the Name.