2

In Magento2.3, I want to maintain the custom log table when order status change.

How to achieve this?

2 Answers 2

0

you can use the sales_order_save_after event and observer the status and log your data in a custom table

0

I think there is already a table sales_order_status_history and you can access through vendor/magento/module-sales/Model/Order/Status/HistoryRepository

It does not log status change unless a comment is attached with it.

At least it will save your time in creating custom table and its files.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.