Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add checkoutUserError field selection to remaining checkout mutations.
- Loading branch information
1 parent
51d07c1
commit fc3f86f
Showing
18 changed files
with
1,146 additions
and
454 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
20 changes: 20 additions & 0 deletions
20
fixtures/checkout-line-items-add-with-user-errors-fixture.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
export default { | ||
"data": { | ||
"checkoutLineItemsAdd": { | ||
"userErrors": [ | ||
{ | ||
"message": "Variant is invalid", | ||
"field": ["lineItems", "0", "variantId"] | ||
} | ||
], | ||
"checkoutUserErrors": [ | ||
{ | ||
"message": "Variant is invalid", | ||
"field": ["lineItems", "0", "variantId"], | ||
"code": "INVALID" | ||
}, | ||
], | ||
"checkout": null | ||
} | ||
} | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
20 changes: 20 additions & 0 deletions
20
fixtures/checkout-line-items-remove-with-user-errors-fixture.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
export default { | ||
"data": { | ||
"checkoutLineItemsRemove": { | ||
"userErrors": [ | ||
{ | ||
"message": "Line item with id abcdefgh not found", | ||
"field": null, | ||
} | ||
], | ||
"checkoutUserErrors": [ | ||
{ | ||
"message": "Line item with id abcdefgh not found", | ||
"field": null, | ||
"code": "LINE_ITEM_NOT_FOUND" | ||
} | ||
], | ||
"checkout": null | ||
} | ||
} | ||
}; |
14 changes: 14 additions & 0 deletions
14
fixtures/checkout-line-items-replace-with-user-errors-fixture.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
export default { | ||
"data": { | ||
"checkoutLineItemsReplace": { | ||
"userErrors": [ | ||
{ | ||
"message": "Variant is invalid", | ||
"field": ['lineItems', '0', 'variantId'], | ||
"code": "INVALID" | ||
} | ||
], | ||
"checkout": null | ||
} | ||
} | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
20 changes: 20 additions & 0 deletions
20
fixtures/checkout-line-items-update-with-user-errors-fixture.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
export default { | ||
"data":{ | ||
"checkoutLineItemsUpdate":{ | ||
"userErrors": [ | ||
{ | ||
"message": "Variant is invalid", | ||
"field": ['lineItems', '0', 'variantId'] | ||
} | ||
], | ||
"checkoutUserErrors": [ | ||
{ | ||
"message": "Variant is invalid", | ||
"field": ['lineItems', '0', 'variantId'], | ||
"code": "INVALID" | ||
} | ||
], | ||
"checkout": null | ||
} | ||
} | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
20 changes: 20 additions & 0 deletions
20
fixtures/checkout-update-custom-attrs-with-user-errors-fixture.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
export default { | ||
"data": { | ||
"checkoutAttributesUpdateV2": { | ||
"checkoutUserErrors": [ | ||
{ | ||
"message": "Note is too long (maximum is 5000 characters)", | ||
"field": ['input', 'note'], | ||
"code": "TOO_LONG" | ||
} | ||
], | ||
"userErrors": [ | ||
{ | ||
"message": "Note is too long (maximum is 5000 characters)", | ||
"field": ['input', 'note'] | ||
} | ||
], | ||
"checkout": null | ||
} | ||
} | ||
}; |
20 changes: 20 additions & 0 deletions
20
fixtures/checkout-update-email-with-user-errors-fixture.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
export default { | ||
"data": { | ||
"checkoutEmailUpdateV2": { | ||
"checkoutUserErrors": [ | ||
{ | ||
"message": "Email is invalid", | ||
"field": ['email'], | ||
"code": "INVALID" | ||
} | ||
], | ||
"userErrors": [ | ||
{ | ||
"message": "Email is invalid", | ||
"field": ['email'], | ||
} | ||
], | ||
"checkout": null | ||
} | ||
} | ||
}; |
Oops, something went wrong.