Closed jamierobles closed 5 years ago
On this page specifically: https://ipromanager.ideashop.iit.edu/admin/orders
It looks like this is caused by the database having separate statuses for orders and items. At the moment, the order's status is automatically advanced to "ordered" when at least one item is ordered, "Ready for pickup" when at least item is delivered, and "completed" when all items have been picked up or canceled. The status will not go back to requested even if all ordered items are set off of ordered.
How would you like this system changed?
Reminder for future me (or anyone who deals with this later): https://github.com/iit-ideashop/IPRO_manager/blob/8ff708de5821c971bc56e942449d34780a3f273f/app/Models/Order.php#L87-L130
New logic is as follows:
Status field is not changing from 'Requested" to reflect current new status when order status is changed