How to assign a certain percentage discount on a list of items? and then show it on a snippet.
Hi @Osama_Alsaati, welcome to the forum.
Here's an example on how to apply the discount on a list of items:
{prices=[120, 200, 315.25]}
Discount: {formtext: name=discount; default=10}%
{repeat: for (x, i) in prices}
Discounted price on product {=i} is {=(x*(100-discount)/100) if discount <> 0 else x; format=$,.2f}
{endrepeat}
Let me know if that helps, or if you need any further assistance.
I have a list of items with a price, and then I want to chose from the list and apply the discount, how to do that ?
@Osama_Alsaati Thanks for joining the call, I hope it's working well now.