Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Discount maximum (CAP) #769

Open
theachoem opened this issue Oct 31, 2023 · 1 comment · May be fixed by #802
Open

Discount maximum (CAP) #769

theachoem opened this issue Oct 31, 2023 · 1 comment · May be fixed by #802
Assignees
Labels

Comments

@theachoem
Copy link
Collaborator

theachoem commented Oct 31, 2023

Allow to add a max discount amount mainly used with discount percentage.

Problem

eg: Discount 50% with cap 20$.

  1. If applied to an order with an amount of 100$
    calculated discount = 100 * 50 / 100 = 50$
    the discount 20$ ( capped )

  2. If applied to an order with an amount of 30$
    calculated discount = 15 * 50 / 100 = 7.5$
    the discount is 7.5$

Rule

  • If the discount is greater than the cap then we choose the cap amount
  • If the discount is less than the cap, we choose the calculated discount.

We end up choosing the mix of the two.

@MenghourLao
Copy link
Collaborator

+1

@theachoem theachoem moved this from Backlog to 🏗 In progress in Spree CM Commissioner Dec 6, 2023
kimsrung added a commit that referenced this issue Dec 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

3 participants