Most of you have created few test transactions with your ecommerce website (Prestashop) when building it. By the time you decided to delete / clear all test orders in Back Office but wonder how as no “delete button” available.
The solutions is very simple
Option 1:
Click on one of the order and replace the parameters “vieworder” by “deleteorder” from the url
For example
http://yourdomain.com/admin/index.php?tab=AdminOrders&id_order=7&vieworder&token=798dfd720021761c80d828eb3f2a8621
Change it to:
http://yourdomain.com/admin/index.php?tab=AdminOrders&id_order=7&deleteorder&token=798dfd720021761c80d828eb3f2a8621
Option 2: For the sake of PHP
Go to AdminOrders.php class in webroot\admin\tabs\AdminOrders.php
At line 25 look for
global $cookie, $currentIndex;
And add this code below it…
$this->delete = true;
That’s it.. when you click on “Order” main tab you will see the delete button “X” next to each order (screenshot)


works great, thank you so much…
awesome, your help is very much appreciated.
hi
very thanks!
maybe its a simple code but its really great help!
thank you so much!!!
Nice, really helped, thanks!
very good.
Thanks a million!
You know what you’re doing!
Wow. This is so simple! I don’t understand why this is not enabled by default.
Great tip! Thanks.
Perfect solution! Great job! Thank you!
Hi, both ways for deleting orders actually delete order but there remains associations in other tables like order_detail. This can be a trouble in a future if another order with the same id is created – it will be connected with all associations and instead of 100 euro order there could be 500 euro… Be aware DON’T USE THIS SOLUTION (at least not for 1.4.* presta)!
Amazing, Nice trick, worked for me.
Thanks!
HI!
I really appreciate for your valuable advice. You are a genuine expert!!!
Next time, can I see you again when I have some problem.
Thanks again.
very nice, but does it delete all the order information from database too?
great help !!! and sooo easy :) thank you