The OrderClose controller command is invoked by the WebSphere Commerce Scheduler. It moves one or more advanced orders having the order state of PRC (processing) to CLS (closed) after all items in the orders have shipped for a given store.
This command should be used infrequently on an exception basis to move orders that cannot be closed normally to a closed state.
Environment variable name | Description |
---|---|
storeId | (Required) The store on which the command runs. |
langId | (Optional) The language ID. (Refer to the LANGUAGE database table for ID values.) |
userId | (Required) The logon ID of the user who is running the command. |
Behavior
For the given store, this command gets the list of orders in the ORDERS table with a major status of PRC for which all items have already shipped. For each of these orders, the command changes the order state to CLS to close the order. As with other scheduler commands, the transaction for each order gets committed before any exception is thrown.
Exception conditions
- Invalid store ID
- The command invoker (user ID) does not have the access to the particular store.