Closed beatrizmaselli closed 1 year ago
Hi! I'm VTEX IO CI/CD Bot and I'll be helping you to publish your app! 🤖
Please select which version do you want to release:
[ ] Patch (backwards-compatible bug fixes)
[x] Minor (backwards-compatible functionality)
[ ] Major (incompatible API changes)
And then you just need to merge your PR when you are ready! There is no need to create a release commit/tag.
Beep boop :robot:
I noticed you didn't make any changes at the docs/
folder
In order to keep track, I'll create an issue if you decide now is not a good time
Your PR has been merged! App is being published. :rocket: Version 2.165.0 → 2.166.0
After the publishing process has been completed (check #vtex-io-releases) and doing A/B tests with the new version, you can deploy your release by running:
vtex deploy vtex.store-graphql@2.166.0
After that your app will be updated on all accounts.
For more information on the deployment process check the docs. :book:
What problem is this solving?
When we have a multiplier unit involved in some situations the price returned by the IS was divergent. For example:
Price: 430 Unit multiplier: 1,3 discount: -19 Selling Price: 540
IS calculation before = Selling Price/(Unit multiplier 100) = 4.15 So using this price to calculate the Selling Price would result in = 4.15 1.3 = 5.395 (truncating the number 5.39) ❌
Now with the new calculation we get:
Price = 4.16 Calculating Selling Price = 4.16 * 1.3 = 5.409 ((truncating the number 5.40) 👌
How to test it?
Beta version:
vtex.store-graphql@2.161.5-beta2
You can use the implemented test calculatePrice to perform different tests.
How does this PR make you feel? :link: