When I split a sales order that has a promotion (3...
# suitescript
d
When I split a sales order that has a promotion (30% discount) the original order does not recalc the discount but the split off items do. Anyone know how to trigger a promotions recalc on or before record save?
b
what does the code look like
d
The code just copies the order (standard mode) and removes or closes items. What I'm looking for is a way to trigger recalculation of the promotions. For some reason the original order promotion keeps its value even though some item lines were closed.
b
sounds normal to me
close a sales order in the ui and take a look at its total
d
Lines are also adjusted to $0, which changes the order total but the promotion does not update/change the % value.
b
need more code
and a way to reproduce whatever item you are using for your promotion
d
The code is over 1k lines
b
you do not need 1000 lines to close a sales order line and set its amount
identify a small amount of code that can reproduce your issue
d
All I'm looking for is a way to force a recalc on the promotion. Doesn't seem possible in standard mode
b
its automatic
d
and yet it doesn't work.....
b
which is why you want to identify which code is not making it work