feat: Add order auto-confirmation (best effort)
Added order confirmation after checkout completion. Note: This requires MANAGE_ORDERS permission which currently has the same bug as HANDLE_PAYMENTS. The try-catch ensures checkout won't fail if confirmation fails. Orders will be UNCONFIRMED until manually confirmed in dashboard.
This commit is contained in:
@@ -224,3 +224,19 @@ export const TRANSACTION_CREATE = gql`
|
||||
}
|
||||
}
|
||||
`;
|
||||
|
||||
export const ORDER_CONFIRM = gql`
|
||||
mutation OrderConfirm($orderId: ID!) {
|
||||
orderConfirm(id: $orderId) {
|
||||
order {
|
||||
id
|
||||
number
|
||||
status
|
||||
}
|
||||
errors {
|
||||
field
|
||||
message
|
||||
}
|
||||
}
|
||||
}
|
||||
`;
|
||||
|
||||
Reference in New Issue
Block a user