-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
Add moveOrderItems mutation #5018
Conversation
Signed-off-by: Eric Dobbertin <[email protected]>
Signed-off-by: Eric Dobbertin <[email protected]>
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.
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.
Not sure if this is done on purpose or not, but I cannot move ALL items from one fulfillment group to another, and "close" the fulfillment group. I get an error You must specify at least 1 values
, which doesn't completely make sense, but I believe based on not allowing me to move a single remaining item
to another fulfillmentGroup
, it means that each fulfillmentGroup
must have at least one item in it.
@kieckhafer I did intentionally want an error if you try to have no items in a group. It's something we could consider supporting in the future, but I think it leads to a lot of unanswered questions and potential confusion as far as what to do about group status, totals, etc. I will fix the I think I'll need to pull out the placeOrder calculations to a util function, so we can redo them as the order changes. (The payments will then not necessarily match the total, but that can be handled by refunds or adding additional payments, something we'll add support for in a future PR.) |
Signed-off-by: Eric Dobbertin <[email protected]>
Signed-off-by: Eric Dobbertin <[email protected]>
@kieckhafer This should be ready for another look |
Signed-off-by: Erik Kieckhafer <[email protected]>
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.
I'm having issues with what seems like Taxes not being calculated / added into the total, causing an mismatch error in total where I can't check out:
This mutation works when taxes aren't active, so it's possible this was something overlooked during my testing in #5027 when all those files were moved around, and not necessarily the fault of this PR.
Signed-off-by: Eric Dobbertin <[email protected]>
after select fulfillment option Signed-off-by: Eric Dobbertin <[email protected]>
to fix integration test Signed-off-by: Eric Dobbertin <[email protected]>
Signed-off-by: Eric Dobbertin <[email protected]>
Signed-off-by: Eric Dobbertin <[email protected]>
Signed-off-by: Eric Dobbertin <[email protected]>
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.
👍 good to go with updates
Part of #4999
Impact: minor
Type: feature
Changes
A new
moveOrderItems
mutation allows you to move one or more order items from one fulfillment group to another existing fulfillment group on the same order.The operator UI does not yet implement this.
moveOrderItems
can be called internally to synchronize from an external system by settingcontext.isInternalCall
totrue
moveOrderItems
can be called through GraphQL by any user with "orders" permission for the shop that owns the ordermoveOrderItems
can be called through GraphQL by the user who placed the order. In this case, the move will only succeed if both the item status and the order status are "new".Breaking changes
None
Testing