-
-
Notifications
You must be signed in to change notification settings - Fork 3k
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
fix(product): fix product variant update price with min_quantity and max_quantity #9381
fix(product): fix product variant update price with min_quantity and max_quantity #9381
Conversation
|
@BeyondOT is attempting to deploy a commit to the medusajs Team on Vercel. A member of the Team first needs to authorize it. |
I just added a commit that fixes the unit test error. The price update fix was made by spreading the price object in money amount so the test should expect the currency code to be there as well if it was included in the price object. |
Hi @adrien2p, this is my first pull request, and it's been open for over two weeks now. The tests have passed, and it has already been approved. Could you let me know if there's anything preventing it from being merged? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nice work! 💪🏻
Apologies for the delay @BeyondOT, merging this in now! 💪🏻 |
What :
The issue is updating the variant price with min_quantity and max_quantity always returned null for both these attributes. Which is not the expected behaviour based on the admin api reference. https://docs.medusajs.com/api/admin#products_postproductsproductvariantsvariant
How :
Make sure to include all the attributes when updating the variant price.
Testing:
Update variant price through api including min_quantity and max_quantity.