shacker 1,051 Posted September 12, 2010 Posted September 12, 2010 Enable the option to delete orders in admin page (ideal to delete test orders)Use this module to enable or disable this feature in a easy way to your clients.Also you can delete all orders in a clic from the module configurationFeatures:MultilingualCross beowser v2.0-compatible ps 1.6+bootstrap v3.0- compatible PS1.7 http://www.catalogo-...ete-orders.htmlVisit our site for the latest version of the free module and more modules comments are welcomedeleteorders.zip deleteorders.zip v3.0 8 1 Share this post Link to post Share on other sites
Zenith 17 Posted September 13, 2010 Posted September 13, 2010 Just adding this delete button using the code in PS does not remove all instances of an order. Share this post Link to post Share on other sites
shacker 1,051 Posted September 13, 2010 Posted September 13, 2010 Just adding this delete button using the code in PS does not remove all instances of an order. This only does the same trick that enables the delete order in the Adminorders.php Share this post Link to post Share on other sites
Zenith 17 Posted September 14, 2010 Posted September 14, 2010 Yes that's what I said, but using this method does not remove all instances of an order like messages, order history, slips, discounts, etcThis module - http://www.prestashop.com/forums/viewthread/18231/ - cleans the order from the database properly. Share this post Link to post Share on other sites
shacker 1,051 Posted September 14, 2010 Posted September 14, 2010 Yes that's what I said, but using this method does not remove all instances of an order like messages, order history, slips, discounts, etcThis module - http://www.prestashop.com/forums/viewthread/18231/ - cleans the order from the database properly. This module only does the trick posted by rocky, without replace any file and no mods, only this. Share this post Link to post Share on other sites
shacker 1,051 Posted August 20, 2012 Posted August 20, 2012 v1.1 - compatible ps 1.2/1.5 Share this post Link to post Share on other sites
ivancitoo_22 0 Posted January 7, 2013 Posted January 7, 2013 (edited) Muy bueno lo estaba buscando!Gracias totalesss! Edited January 7, 2013 by ivancitoo_22 (see edit history) Share this post Link to post Share on other sites
Berlindoor 3 Posted February 24, 2013 Posted February 24, 2013 here works perfectly. But in dev mode, when trying to delete all orders with the "one click button" this is what I get: [PrestaShopDatabaseException] Db->executeS() must be used only with select, show, explain or describe queries at line 470 in file classes/db/Db.php 464. 465. // This method must be used only with queries which display results 466. if (!preg_match('#^\s*\(?\s*(select|show|explain|describe|desc)\s#i', $sql)) 467. { 468. if (defined('_PS_MODE_DEV_') && _PS_MODE_DEV_) 469. throw new PrestaShopDatabaseException('Db->executeS() must be used only with select, show, explain or describe queries'); 470. return $this->execute($sql, $use_cache); 471. } 472. 473. $this->result = false; 474. $this->last_query = $sql; DbCore->executeS - [line 40 - modules/deleteorders/deleteorders.php] - [1 Arguments] DeleteOrders->getContent - [line 597 - controllers/admin/AdminModulesController.php] - [0 Argument] AdminModulesControllerCore->postProcessCallback - [line 717 - controllers/admin/AdminModulesController.php] - [0 Argument] AdminModulesControllerCore->postProcess - [line 158 - classes/controller/Controller.php] - [0 Argument] ControllerCore->run - [line 348 - classes/Dispatcher.php] - [0 Argument] DispatcherCore->dispatch - [line 50 - greenadmin/index.php] - [0 Argument] [PrestaShop] Fatal error in module Unk: Module 'mcrypt' already loaded Share this post Link to post Share on other sites
shacker 1,051 Posted February 25, 2013 Posted February 25, 2013 thanks. i check it Share this post Link to post Share on other sites
shacker 1,051 Posted March 2, 2013 Posted March 2, 2013 i update the module and solve this Share this post Link to post Share on other sites
shacker 1,051 Posted March 2, 2013 Posted March 2, 2013 v1.2 - support ps 1.5.3.1 1 Share this post Link to post Share on other sites
shacker 1,051 Posted November 7, 2014 Posted November 7, 2014 v2.0-compatible ps 1.6+bootstrap 1 Share this post Link to post Share on other sites
Totti 59 Posted November 7, 2014 Posted November 7, 2014 You can also put the file on this page ?Thanks. Share this post Link to post Share on other sites
Dead2010 5 Posted November 7, 2014 Posted November 7, 2014 hello shacker, added account and will finish in the cart, but when downloading, always fails. I can not download, any problem? greetings Share this post Link to post Share on other sites
shacker 1,051 Posted November 7, 2014 Posted November 7, 2014 hi. what browser iu use and version, and please tell me how you download, order page, my download or email link. help me so i can solve asap Share this post Link to post Share on other sites
Dead2010 5 Posted November 7, 2014 Posted November 7, 2014 When will I access my account and try to download, it always gives error and the others I have in my account too. formerly gave no error.both on firefox and in internet explorer Share this post Link to post Share on other sites
shacker 1,051 Posted November 7, 2014 Posted November 7, 2014 hi. can iu please try again? Share this post Link to post Share on other sites
Dead2010 5 Posted November 7, 2014 Posted November 7, 2014 hello, still giving error. download failure Share this post Link to post Share on other sites
shacker 1,051 Posted November 7, 2014 Posted November 7, 2014 can iu send me a pm with your user and pass? Share this post Link to post Share on other sites
Dead2010 5 Posted November 9, 2014 Posted November 9, 2014 hello, now I got it. Thank you greetings Share this post Link to post Share on other sites
shacker 1,051 Posted November 10, 2014 Posted November 10, 2014 hello, now I got it. Thank you greetings perfect.regards Share this post Link to post Share on other sites
reinvis 0 Posted November 12, 2014 Posted November 12, 2014 Hi Shacker, Your site is down! I got only mysql errors. Share this post Link to post Share on other sites
shacker 1,051 Posted November 12, 2014 Posted November 12, 2014 yes, we are upgrading mysql and php version Share this post Link to post Share on other sites
jcmil 1 Posted December 21, 2014 Posted December 21, 2014 Just tried this on 1.6.0.9 - killed all those dummy orders! Thanks. Share this post Link to post Share on other sites
shacker 1,051 Posted December 21, 2014 Posted December 21, 2014 Just tried this on 1.6.0.9 - killed all those dummy orders! Thanks. you welcome. please rate the product in our site. This help us Share this post Link to post Share on other sites
juanimela 0 Posted January 18, 2015 Posted January 18, 2015 In your code I read: chmod('../controllers/admin/AdminOrdersController.php', 0777); if (ini_get('allow_url_fopen') == '0') ini_set('allow_url_fopen', '1'); $str = ''; if ($fh = fopen('../controllers/admin/AdminOrdersController.php', 'r')) { while (!feof($fh)) $str .= fgets($fh); $str = str_replace('$this->addRowAction(\'view\');', '$this->addRowAction(\'view\');$this->addRowAction(\'delete\');', $str); fclose($fh); chmod('../controllers/admin/AdminOrdersController.php', 0644); } So, you change the source file ../controllers/admin/AdminOrdersController.php in place (that's dangerous!), to add the delete action to orders. So I have som doubts: I've read in this forum that is not safe to just add that action, because that will not take care of all tables that depend on order You're not using a module or an override, so the code will come back to normal after any upgrade, ¿no? allow_url_fopen might be disabled for security reasons, so this module may not work for some people. Share this post Link to post Share on other sites
shacker 1,051 Posted January 18, 2015 Posted January 18, 2015 Hi. change the file is not dangerous when you only add a code (like enable or disable), dont do anything else If you update, can turn on again. If the customer have disabled overrides, the module dont work. Check what actions do the enable delete functions, and you get all the way up to delete the orders allow url its irrelevant in this case, must be deleted in futures releases. Share this post Link to post Share on other sites
juanimela 0 Posted January 18, 2015 Posted January 18, 2015 (edited) shacker, I know the code is not malicious and probably works for many people, but I'd very much overwrite the file myself rather than have a module do it for me. Possible issues: - Encoding problem, and my installation is dead - Uninstall: who needs that? - Possible conflict with other approaches Further, I agree that the entry in the ps_orders table will get deleted, but our concern is: how about the other tables that depend on it? Will we have stranded invoices or phantom carts? There is one way to check: - Install the official "prestashop cleaner", which has two interesting functions: "CheckAndFix" and "CleanAndOptimize". Use both. - After deleting one order with this module, use both function again. - If any of them report any operation after deleting the order, that means your module is not safe to use. A quick fix would be to call those functions from the cleaner module using the right hook. I'm no expert, but I'd say it's actionObjectOrderDeleteAfter. Edited January 18, 2015 by juanimela (see edit history) Share this post Link to post Share on other sites
shacker 1,051 Posted January 18, 2015 Posted January 18, 2015 I doubt ps cleaner works in all ps version. I made this for all version. Anyway, if somebody want to improve, no problem i can add the changes. at the moment i dont have time to develop all free modules and make changes to all. regards Share this post Link to post Share on other sites
El Patron 2,871 Posted January 18, 2015 Posted January 18, 2015 shacker, is the current/correct version downloadable from here or only from your shop? Share this post Link to post Share on other sites
shacker 1,051 Posted January 18, 2015 Posted January 18, 2015 shacker, is the current/correct version downloadable from here or only from your shop? Dont remember, but always download the latest from our site. sometimes i cant upload. Share this post Link to post Share on other sites
El Patron 2,871 Posted January 18, 2015 Posted January 18, 2015 Dont remember, but always download the latest from our site. sometimes i cant upload. please attach the current version according to forum rules, this will keep people from downloading old version that may not work. Share this post Link to post Share on other sites
shacker 1,051 Posted January 19, 2015 Posted January 19, 2015 according to forum rules section, there is no rule to put the latest version in free modules Any module you may provide should be attached directly in your post Meaning: not with a link to an external website. The modules you are posting here are 100% free. Thus, you can share them just by attaching the ZIP file to the topic. Posts with an external link will be moderated and taken down. Please use your common sense to make this section pleasant for everyone (respect others, be benevolent). So as i said, i have more than 200 free modules and keep on eye on all its hard job when its free, so i always put a warning that can download latest version from our site Share this post Link to post Share on other sites
Xavier du Tertre 589 Posted January 19, 2015 Posted January 19, 2015 according to forum rules section, there is no rule to put the latest version in free modules Still, it would be better. Can you: - edit first post - replace ZIP with latest one - reply to the thread with notification of new ZIP Thanks Vekia! Share this post Link to post Share on other sites
vekia 8,961 Posted January 19, 2015 Posted January 19, 2015 You probably mean Shacker, right Xav? ;-) Share this post Link to post Share on other sites
shacker 1,051 Posted January 19, 2015 Posted January 19, 2015 You probably mean Shacker, right Xav? ;-) lol, thats becouse have the same module name Still, it would be better. Can you: - edit first post - replace ZIP with latest one - reply to the thread with notification of new ZIP Thanks Vekia! i do now, for other modules i try to add the latest when update Share this post Link to post Share on other sites
Xavier du Tertre 589 Posted January 20, 2015 Posted January 20, 2015 You probably mean Shacker, right Xav? ;-) Yeah sorry, you're like two brothers from a different mother: I love you both too much but I forget who's who. 1 Share this post Link to post Share on other sites
shacker 1,051 Posted January 20, 2015 Posted January 20, 2015 Yeah sorry, you're like two brothers from a different mother: I love you both too much but I forget who's who. one is taken, but no one knows what Share this post Link to post Share on other sites
elvibora 0 Posted January 22, 2015 Posted January 22, 2015 Looks totally awesome - Thanks!!! Share this post Link to post Share on other sites
shacker 1,051 Posted January 22, 2015 Posted January 22, 2015 Looks totally awesome - Thanks!!! iu welcome Share this post Link to post Share on other sites
bcsteeve 7 Posted July 18, 2015 Posted July 18, 2015 Does your module delete all database reference to the order? Such as things like order_invoice, order_payment, etc? Or just the 'orders' table? Thanks. Share this post Link to post Share on other sites
shacker 1,051 Posted August 4, 2015 Posted August 4, 2015 The module enables the option DELETE, that is hidden in prestashop by default. You can track all the process of the function Share this post Link to post Share on other sites
bcsteeve 7 Posted August 4, 2015 Posted August 4, 2015 "You can track all the process of the function"... huh? Anyway, as you can see I asked WEEKS ago, so nevermind. Share this post Link to post Share on other sites
shacker 1,051 Posted August 4, 2015 Posted August 4, 2015 as you can see, i have more than 14000 replies and more than 500 msg every week to respond, so, cant reply fast 1 Share this post Link to post Share on other sites
myselfidem 66 Posted August 7, 2015 Posted August 7, 2015 (edited) Thansk for this nice module "shaker". It seems there are little typo errors Inside deleteorders.php : on line 98 : wouldn't be ('submitdeleteo') ? if (Tools::isSubmit('submitedeleteo')) on line 531 : wouldn't be : "submitdeleteo' ? <center><input type="submit" name="submitedeleteo" value="'.$this->l('Save').'" class="button" /></center> Friendly Edited August 7, 2015 by myselfidem (see edit history) Share this post Link to post Share on other sites
shacker 1,051 Posted August 7, 2015 Posted August 7, 2015 is with submitdeleteo. Where do you download the module? Share this post Link to post Share on other sites
shacker 1,051 Posted August 7, 2015 Posted August 7, 2015 I see, its ok, uses different name to 1.6 version Share this post Link to post Share on other sites
viktorb92 3 Posted October 4, 2015 Posted October 4, 2015 Hello does this module resets the number of invoices too? Share this post Link to post Share on other sites
shacker 1,051 Posted October 4, 2015 Posted October 4, 2015 no. use the ps cleaner that comes with prestashop to delete all and reset Share this post Link to post Share on other sites
nrms 0 Posted November 24, 2015 Posted November 24, 2015 Woks fine in ps 1.6.0.11 for now. Thanks! Share this post Link to post Share on other sites
shacker 1,051 Posted November 24, 2015 Posted November 24, 2015 thanks for share Share this post Link to post Share on other sites
shacker 1,051 Posted October 23, 2018 Posted October 23, 2018 v3.0 - compatible PS 1.7 Share this post Link to post Share on other sites
Gipielle 21 Posted March 1, 2020 Posted March 1, 2020 Thanks, works on PS 1.7.6.3 Maybe delete all orders buttum in not a good idea ... Share this post Link to post Share on other sites
shacker 1,051 Posted March 3, 2020 Posted March 3, 2020 was requested by a lot of users Share this post Link to post Share on other sites
Gipielle 21 Posted March 4, 2020 Posted March 4, 2020 OK, so maybe change the look of the button so it not easy to confuse with the other one Share this post Link to post Share on other sites
shacker 1,051 Posted July 13, 2020 Posted July 13, 2020 thanks for comment Share this post Link to post Share on other sites
One_Man 73 Posted November 4, 2020 Posted November 4, 2020 Hello and thank you for your module. I have a problem on a 1.7.6.8 ps, when I uninstall and remove the module, the option to remove commands is still present! it's normal ? ************************************ Salut et merci pour ton module J'ai un probleme sur un ps 1.7.6.8, quand je désinstalle et supprime le module, l'option pour supprimer les commandes est toujours présent ! c'est normal ? Share this post Link to post Share on other sites
KamikStudio 1 Posted February 15 Posted February 15 you can do it without a module go to the product in the url/index.php?controller=AdminOrders&vieworder=&id_order replace vieworder with deleteorder the order will be deleted immediately and you will return to the order panel Share this post Link to post Share on other sites
SalDan 1 Posted February 15 Posted February 15 ciao a me esce in questo modo come mai? .......it/evte5baiutamzbm9/index.php/sell/orders/3/view?_token=ewd9r7VnwTOJ4wliiyDbD435z0saHl_5Mpqd9fehEzU Share this post Link to post Share on other sites
Deragos Webdesign 1 Posted February 16 Posted February 16 Hi, Its installed fine on ps 1.7.7.1 but when i try to put it on / activate in the module.. i get error: Error opening file in /var/www/domains/domainname.*/www/modules/deleteorders/deleteorders.php on line __LINE. Then it doesnt activate. Greetings. Share this post Link to post Share on other sites
SalDan 1 Posted February 16 Posted February 16 ciao allora in pratica non funziona giusto?? ....in tal caso se trovi qualcosa che fa per la nostra versione mi avvisi grazie mille Share this post Link to post Share on other sites
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now