An upgrade order is created in the status 'New' and requires manual approval for further processing. How to make upgrade orders be created in the status Open instead of New to avoid manual orders opening?
Initial orders statuses are stored in the table "OrderOperation" in the database:
pba=> select "OperID", "OrderStatusID", "OrderTypeID" from "OrderOperation"; OperID | OrderStatusID | OrderTypeID ---------------------------------------------+---------------+------------- generateBill | NW | BO generateZeroBill | NW | ZB handleSubscriptionCancellation | CL | makeAutoRenewalOrder | OP | RN makeCancellationChargeOrder | NW | CF makeCancellationOrder | NW | CL makeCustomerPlanDowngradeOrder | NW | DG makeCustomerResourceDowngradeOrder | NW | DG makePaymentOrderByProv | OP | PO makePaymentOrder | OP | PO makePlanDowngradeOrder | NW | DG makeResourceDowngradeOrder_API | NW | DG makeResourceDowngradeOrder | NW | DG makeRestoreOrder | NW | RN makeSynchrOrder | NW | RC PlaceMyOrder | OP | SO PlaceOrder_Step2 | NW | SO resubmitPaymentOrder | OP | PO StorePlaceOrderBankTransfer_ExistingAccount | OP | SO StorePlaceOrderBankTransfer | OP | SO StorePlaceOrderCheckCash_ExistingAccount | OP | SO StorePlaceOrderCheckCash | OP | SO StorePlaceOrder_ExistingAccount | OP | SO StorePlaceOrder | OP | SO makePlanUpgradeOrder | NW | UG makeResourceUpgradeOrder | NW | UG makeCustomerPlanUpgradeOrder | OP | UG makeCustomerResourceUpgradeOrder | OP | UG makeResourceUpgradeOrder_API | OP | UG generateNipBill | CP | BN makeRenewalOrder | NW | RN (31 rows)
To let upgrade orders created from the provider's control panel be created in the status Open the following SQL query may be used:
pba=> update "OrderOperation" set "OrderStatusID" = 'OP' where "OperID" = 'makeResourceUpgradeOrder';
For the order created from the customer CP, the prefix Customer is present in the operation name, e.g. makeCustomerResourceUpgradeOrder is an operation for creating a resource upgrade order from the CCP.
Leave initial status for upgrade orders as New and make transition from New to Open automatic. To do this please refer to the following article - How to make manually created orders open automatically