Automatic discount based on customer discount-level with set amounts per product

It would be nice if we could have these discounts included in the Discounts account.
I’m not sure how to best approach this though.

I’m thinking maybe this could work: at Payment Processed event, create an account transaction which puts the total discount amount in Discounts account, and also adds it to Sales account.

I’ve tried to access the total discount value with this (but it’s not working, I get 0.00 every time):

[=-1*({ORDER TAG TOTAL:D1}+{ORDER TAG TOTAL:D2}+{ORDER TAG TOTAL:D3})]

It seems like this information is not available at Payment processed event…

EDIT: I forgot to use TN in the expression, I know it should be like this:

[=-1*(TN(‘{ORDER TAG TOTAL:D1}’)+TN(‘{ORDER TAG TOTAL:D2}’)+TN('{ORDER TAG TOTAL:D3}))]

but even just {ORDER TAG TOTAL:D1} or {ORDER TAG TOTAL:D2} or {ORDER TAG TOTAL:D3} show 0.00 in a Show Message action…
In the Order State Updated and Ticket Total Changed events it’s also not available…

EDIT: @Jesse just pointed out to me that D1 is the tag’s value, not it’s name (duh) :smile:
so we just need {ORDER TAG TOTAL:Discount}

1 Like