| Dean J Garrett 2004-06-11, 6:13 pm |
| I am trying to add a coupon discount feature to the order summary
page. It is a order level discount that needs to be subtracted
from the order subtotal before any shipping or tax charges is
calculated.
There are two pipelines that are involved for this process:
'Basket' and 'Total' pipelines. The 'Basket' pipeline has the
'Order Subtotal' as the last stage and the 'Total' pipeline has
stages such as Shipping, Handling, Tax and so on.
I added a new stage 'CalcCouponDisc' to the end of the 'Basket'
pipeline and it has this line of code:
orderform.value("_cy_oadjust_subtotal") =
CStr(CLng(orderform.value("_cy_oadjust_subtotal")) * 0.9)
orderform.value("saved_cy_oadjust_subtotal") =
orderform.value("_cy_oadjust_subtotal")
to give the total a 10% discount. However, when it calculates
the shipping charge and tax, it is still looking at the original
subtotal (before the discount). What do I need to do so that the
shipping charge and tax will be calculated using the discounted
subtotal?
Thank you!
|