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

Coupon calculations incorrect #651

Closed
mscruse opened this issue Jun 8, 2022 · 4 comments · Fixed by #655 or #660
Closed

Coupon calculations incorrect #651

mscruse opened this issue Jun 8, 2022 · 4 comments · Fixed by #655 or #660

Comments

@mscruse
Copy link

mscruse commented Jun 8, 2022

Bug Description

I am experiencing an issue with the calculation of coupon discounts. I have created 2 coupons:

Coupon 1 - Fixed Discount. I create a $10 discount and enter 10.00 in the value field of the coupon. When I go to use this coupon it gives a discount of $0.10 (10 cents). If I enter 1000 in the value field I get the $10 discount.

Coupon 2 - Percentage Discount. I create a 10% discount and there 10 as the value. When using this coupon it multiplies the order items total by 10. NOTE this only seems to happen when the price of an item is not a whole dollar, e.g. $24.99. If it is $25.00 then it works OK.

<note: this SC project has been in development for about a year so it has been upgraded along the way but started on a 2.x install of SC>

Steps to reproduce

Create the coupons as above and test.

Environment

Statamic 3.3.13 Pro
Laravel 9.17.0
PHP 8.1.5
aryehraber/statamic-captcha 1.8.0
aryehraber/statamic-font-awesome 2.2.0
doublethreedigital/duplicator 2.2.0
doublethreedigital/simple-commerce 3.2.6
mitydigital/simple-commerce-australia-post 1.0.0
rias/statamic-redirect 2.3.5
statamic/seo-pro 3.1.0

@duncanmcclean
Copy link
Owner

Thanks for this issue - I don't have any time to look into it tonight but will try and take a look tomorrow 👍

@github-actions
Copy link

github-actions bot commented Jun 9, 2022

Released as part of v3.2.7.

@duncanmcclean duncanmcclean reopened this Jun 14, 2022
@duncanmcclean
Copy link
Owner

Note to self: re-watch video recording sent over via email

@github-actions
Copy link

Released as part of v3.2.8.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants