The tutorial will help you to add delete order feature on Prestashop. It is very useful if you completed the development and you are going to move your website to live. Delete the test order is a must.
As a lead Prestashop development company, I have experience with Prestashop since 2011. I developed a first website by Prestashop version 1.3 and form the version till now 1.6, A lot of my Prestashop client asked to delete order. Example you want to delete test order. Or some canceled order. Today I will help you to know how to remove PS order.
There are only 3 simple steps:
1. Create a new file: /override/controllers/admin/AdminOrdersController.php
2. Add bellow code to your new file:
<?php
class AdminOrdersController extends AdminOrdersControllerCore{
public function __construct() {
$this->addRowAction('delete');
parent::__construct();
}
}
3. Delete the file: /cache/class_index.php
Now go to order panel in Back Office. You will see:
Note: Before delete the order, we have to go through that order and change status to “Canceled” before delete it by the icon’s button that we activated it in the first part. Otherwise the item in stock will be gone with the deleted order as well.
If you want to improve your experience on Order Management and want delete order feature on Prestashop. I recommend Prestashop Order Management Module. The module has a lot features such as: Edit order, delete order, duplicate order, export order to csv file
works perfect thanx
LikeLike
Can you please explain the process to duplicate an order from prestashop 1.6 backoffice? Thanks
LikeLike
We need create a temporary cart object that is copy from the source order. Then convert the cart to an order.
Now the module Order Management is available on Prestashop Addons Store. You can purchase here: https://addons.prestashop.com/en/order-management/23748-advanced-order-management-edit-order-duplicate-order.html
LikeLike