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

Bug introduced in #61 #62

Closed
wernerkrauss opened this issue Apr 27, 2020 · 2 comments
Closed

Bug introduced in #61 #62

wernerkrauss opened this issue Apr 27, 2020 · 2 comments

Comments

@wernerkrauss
Copy link
Contributor

in #61 @RVXD changed the value taken for calculating shipping costs to order's "Total" instead of SubTotal.

This introduces a bug when using TableShippingRates and stepped checkout.

Imagine a SubTotal of 75,-
Under 80,- we have a shipping fee of 10,-
Now the Total is 85,- and saved to the order object.

In the next step it calculates the shipping fee again, but now it uses the saved Total of 85,- to calculate it. Unfortunately this is just above free shipping limit.

The user sees a total calculated ammount of 75,- (Subtotal and no shipping), but internally the order is still worth 85,- .

Now the problems are really starting: The customer is sent to the payment gateway to pay the last calculated amount of 75,-, the order is not fully paid.

IMHO we should revert #61 and the discounts module should modify the value of "createShippingPackage" using the provided hook "updateShippingPackage"

@wilr
Copy link
Contributor

wilr commented Apr 27, 2020

@wernerkrauss I see what you mean, 61 has been reverted for now

@RVXD
Copy link
Contributor

RVXD commented Apr 29, 2020

@wernerkrauss Maybe you can test this fix, it should work good for both our cases.

wilr added a commit that referenced this issue May 27, 2020
@wilr wilr closed this as completed May 27, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants