Closed simonmaass closed 3 months ago
Update: After doing some more research it seams like this bug only happens when you set the custom price to 0€... my first thought would be that some kind of truthy check fails with 0...
Hi There @simonmaass ,Thank you for opening this issue. We were unable to reproduce this. Could you please try this on a plain Magento 2 installation with only Mollie installed to see if this issue is then still present? Thanks!
@Frank-Magmodules I was able to reproduct the bug when setting a custom price to 0€:
Old order:
New order created by "Mark as paid":
Hello @simonmaass, I have replicated the issue now. It's indeed strange. I'll look into this with the team and provide you with an update shortly. Thank you for providing the additional information. It seems the problem is caused by the 0,00 number. We're not sure if it's Magento or Mollie responsible for this, but we'll investigate and find out.
Hi There @simonmaass ,
Once again, thank you for opening this issue. It seems that this error is on the Magento side.
To be even more precise, it is due to this line:
https://github.com/magento/magento2/blob/2.4-develop/app/code/Magento/Quote/Model/Quote/Item/Processor.php#L104
At that point $customPrice === (int)0
, which returns false when compared with empty.
Since it appears to be a Magento-related problem rather than an issue specifically with the Mollie plugin, we will be closing this ticket for now.
I found an open issue for magento for this: https://github.com/magento/magento2/issues/36970
There is also an open pull request: https://github.com/magento/magento2/pull/37625
Perfect @simonmaass , thanks for sharing!
Describe the bug When clicking "Mark as paid" a new order is created and the old one is set to "Canceled". The new order now has wrong totals!
Used versions
To Reproduce Steps to reproduce the behavior:
Expected behavior New order is created with the same product totals as the old order!
Actual behavior The new order is created with the original product price!
Screenshots Old order:
New order: