Canceling Backorders through the Generic Pick In API
With this update, a new bo_cancel_reason tag is supported in version 4.0 of the CWPickIn message when the transaction_type is B (partial shipment/unreserve) or U (void/unreserve), indicating the cancel reason code to use when canceling the backordered quantity on a pick slip. The new tag is ignored for any other transaction type.
The cancel reason code is a two-position, numeric field, so if the bo_cancel_reason passed for a transaction type of B or U is:
-
An existing cancel reason, this cancel reason is used.
-
A two-position number that doesn’t match an existing cancel reason code, a new cancel reason is created with:
-
A Description such as 12 — AUTO CREATED, where 12 is the code passed.
-
The Generate Refund? flag set to Generate Refund with Hold Status.
-
The Reduce Demand flag set to No.
-
-
A number longer than two positions, it is truncated to two positions, and then evaluated for use or creation as described above. For example, if a code of 1234 is passed, the system uses a cancel reason of 12, if it exists; otherwise, it creates a new cancel reason with a code of 12. In this case, the system creates an order transaction history note indicating: Pick BO cancel reason was truncated.
-
Not a number, the order lines on the pick slip aren’t canceled, and the system creates an order transaction history note indicating: Pick BO cancel failed - Invalid Reason.
Updates if a backorder cancel reason is specified with the transaction type set to B (partial shipment/unreserve):
-
Any shipped lines or quantities on the pick slip are confirmed.
-
Any unshipped lines or quantities on the pick slip are canceled using the specified backorder cancel reason. The specified cancel reason is displayed at the Display Order Line History screen with the total backordered quantity that was canceled.
Updates if a backorder cancel reason is specified with the transaction type set to U (void/unreserve): All order lines on the pick slip are unreserved and canceled.
Aside from the changes above, existing logic and updates still take place, including creating order transaction history, generating the order line cancellation email, and so on, as described in the Generic Pick In API help topic.