I have written a new custom award and idetified the orderline I wish to discount. How do you discount the orderline programatically? None of the following seem to work and there is no documentation.
E.g.
ol.Discount = 100 ol.Save()
Or
Dim disc As New Discount disc.AmountOffTotal = ol.Price disc.Save() ol.AddDiscount(disc) ol.Save()
Or
Dim percOff As New PercentOffOrderLinesAward percOff.PercentOff = 100 percOff.Apply(order, ol) ol.Save()
(bit weird though applying an award from an award!)
Discount orderline in new custom Award
I have written a new custom award and idetified the orderline I wish to discount. How do you discount the orderline programatically? None of the following seem to work and there is no documentation.
E.g.
Or
Or
(bit weird though applying an award from an award!)
Discount has to be added to the order itself and the relevant order line like so:
is working on a reply...