Calculation a dynamical discount

Hello! I need to create calculation a dynamical discount in customer order. Discount size for customer depends on amount of purchases in current month.
I have 3 sizes:
30% - amount of purchases in current month is less than 10000
35% - amount of purchases in current month is 10001-20000
40% - amount of purchases in current month is more than 20001
How I can create it?

Good evening @aqqura,

I don’t see any replies to your question. I am trying to build a similar tiered discount structure. Were you able to figure this out or were you able to find any helpful resources?

Hello! I’ve added WF to Backend WF which calculates amount of purchases and discount percent for every customer.

Thanks for the reply! I didn’t realize that this thread started 2016. New to Bubble/the forum and didn’t pay attention.

I’m assuming WF = workflow? Is that correct? Trying to build the same within Bubble to avoid plugins, etc as much as possible to keep page load fairly quick. Are you experiencing any slowing?

1 Like

Yes! WF = workflow. It will be workflow on backend and this WF won’t influence on the page loading.
If you calculate a discount amount once per month I recommend you to add 2 WFs on Backend workflows page.
The first WF is Recurring. Your should launch the calculation for every your Client.

The second WF is Calculation for specified Client. You can set discount criteria in this WF

The third WF can located on any page. You need to start the Recurring WF on 1 day of next month. The Recurring WF will start every month at 1 day on 00:10:00