asianstop Posted July 22, 2010 Share Posted July 22, 2010 Basically, I'd like to delete order statuses which I don't need such as "Awaiting cheque payment" as I won't be accepting cheques. So it's pointless having it there .Any ideas?Thanks. Link to comment Share on other sites More sharing options...
rocky Posted July 23, 2010 Share Posted July 23, 2010 Go to Orders > Statuses and the click the X in the Actions column in the "Awaiting cheque payment" row. Be careful which statuses you delete though, since it will cause problems if PrestaShop tries to automatically switch to a status that you have deleted. This shouldn't be a problem if you don't use the cheque module though. Link to comment Share on other sites More sharing options...
asianstop Posted July 23, 2010 Author Share Posted July 23, 2010 Thanks rocky, I've tried that. This is the error I get ; 1. For security reasons, you cannot delete default order statuses. Link to comment Share on other sites More sharing options...
rocky Posted July 24, 2010 Share Posted July 24, 2010 It looks like your only option is to hide the status on the order page. You can do this by changing lines 469-470 of admin/tabs/AdminOrders.php (in PrestaShop v1.3.1) from: foreach ($states AS $state) echo ''.stripslashes($state['name']).''; to: foreach ($states AS $state) if ($state['id_order_state'] != 1) echo ''.stripslashes($state['name']).''; Link to comment Share on other sites More sharing options...
fallenleader Posted August 7, 2010 Share Posted August 7, 2010 foreach ($states AS $state) if ($state['id_order_state'] != 1) if ($state['id_order_state'] != 10) echo ' $currentStateTab['id_order_state']) ? ' selected="selected"' : '').'>'.stripslashes($state['name']).''; will block the cheque and bankwire i believe. the code worked for me. thanks rocky. Link to comment Share on other sites More sharing options...
rocky Posted August 7, 2010 Share Posted August 7, 2010 That's great that it was useful for you. The following code would be better though: foreach ($states AS $state) if ($state['id_order_state'] != 1 AND $state['id_order_state'] != 10) echo ''.stripslashes($state['name']).''; 1 Link to comment Share on other sites More sharing options...
fallenleader Posted August 8, 2010 Share Posted August 8, 2010 i thought my change was written wrong, thanks.and of course, streamlining it is important, we don't use checks or bankwire, so clicking by accident would just cause much confusion. Link to comment Share on other sites More sharing options...
james-laws Posted August 17, 2010 Share Posted August 17, 2010 Thanks rocky for the post .Mine problem was solved at least Link to comment Share on other sites More sharing options...
davor Posted February 17, 2011 Share Posted February 17, 2011 Anybody can help how to delete statuses. This code I change and do not work at me. I still can't delete statuses1. For security reasons, you cannot delete default order statuses. - shown when I want ot delete some. I use only COD and want to delete paypal and chque Link to comment Share on other sites More sharing options...
Artizzz Posted April 5, 2011 Share Posted April 5, 2011 this is great solution... thanks, rocky! Link to comment Share on other sites More sharing options...
haunter Posted August 10, 2012 Share Posted August 10, 2012 In ps 1.482 you can edit table ps_order_state and set deleted to 1 to statuses you dont want to see and use 1 Link to comment Share on other sites More sharing options...
Artizzz Posted November 5, 2012 Share Posted November 5, 2012 how to apply Rocky's great solution to prestashop version 1.5.2? Link to comment Share on other sites More sharing options...
jaimeweb Posted May 28, 2013 Share Posted May 28, 2013 Can this be done on 1.5? Link to comment Share on other sites More sharing options...
FreshCommerce Posted June 1, 2013 Share Posted June 1, 2013 (edited) In PS 1.5 you can hide statuses in the select of the order management page looking in: AdminFolder/themes/default/template/controllers/orders/helpers/view.view.tpl About line 114 you´ll find {if ($state['id_order_state'] .... and exclude the ids you want to hide (or directly type what statuses you want availables) Example: Remove the code {foreach from=$states item=state} {if $state['id_order_state'] != $currentState->id} <option value="{$state['id_order_state']}">{$state['name']|stripslashes}</option> {/if} {/foreach} And add your options manually <select id="id_order_state" name="id_order_state"> <option value="1">Sent</option> <option value="2">Cancelled</option> <option value="3">Preparing</option> ..... </select> Edited June 1, 2013 by FreshCommerce (see edit history) Link to comment Share on other sites More sharing options...
fortuner Posted April 7, 2014 Share Posted April 7, 2014 In PS 1.5 you can hide statuses in the select of the order management page looking in: AdminFolder/themes/default/template/controllers/orders/helpers/view.view.tpl About line 114 you´ll find {if ($state['id_order_state'] .... and exclude the ids you want to hide (or directly type what statuses you want availables) Example: Remove the code {foreach from=$states item=state} {if $state['id_order_state'] != $currentState->id} <option value="{$state['id_order_state']}">{$state['name']|stripslashes}</option> {/if} {/foreach} And add your options manually <select id="id_order_state" name="id_order_state"> <option value="1">Sent</option> <option value="2">Cancelled</option> <option value="3">Preparing</option> ..... </select> That is not a solve, because if you add yor own order state, it will not display too. Link to comment Share on other sites More sharing options...
Pedro Henrique Posted January 26, 2015 Share Posted January 26, 2015 Bom dia. Se você alterar a coluna "unremovable" dentro do banco de dados, trocando o valor "1" para "0", você conseguirá deletar o status dentro do BO. ------------------ Good day.If you change the "unremovable" column in the database, changing the value "1" to "0", you will delete the status within the BO. Link to comment Share on other sites More sharing options...
Cyrius91 Posted February 1, 2015 Share Posted February 1, 2015 It looks like your only option is to hide the status on the order page. You can do this by changing lines 469-470 of admin/tabs/AdminOrders.php (in PrestaShop v1.3.1) from: foreach ($states AS $state) echo '<option value="'.$state['id_order_state'].'"'.(($state['id_order_state'] == $currentStateTab['id_order_state']) ? ' selected="selected"' : '').'>'.stripslashes($state['name']).'</option>'; to: foreach ($states AS $state) if ($state['id_order_state'] != 1) echo '<option value="'.$state['id_order_state'].'"'.(($state['id_order_state'] == $currentStateTab['id_order_state']) ? ' selected="selected"' : '').'>'.stripslashes($state['name']).'</option>'; Thank you very much, it's perfect in ps 1.4.9 Link to comment Share on other sites More sharing options...
alex_netsov Posted August 3, 2015 Share Posted August 3, 2015 In ps 1.482 you can edit table ps_order_state and set deleted to 1 to statuses you dont want to see and use You can edit many options there. Solved the problem via ps_order_state in Prestashop 1.6.1.0 Link to comment Share on other sites More sharing options...
walter.w Posted October 31, 2015 Share Posted October 31, 2015 Hello, Can anyone tell me what's the best option to delete/hide the 'awaiting cheque payment' status in PS 1.6? I see 2 options in this topic and would like to know what's is the best and safest way? Thanks in advance! Link to comment Share on other sites More sharing options...
littlegreenguy Posted January 24, 2019 Share Posted January 24, 2019 ps version: 1.7 (maybe other versions too) I've found a way that I've not fully tested but which I presume is pretty harmless! If you have database access, on the: ed_order_state table, there is a 'deleted' column - kinda like a 'soft delete' - you can cross reference the id_order_state with the: ed_order_state_lang table to see the label of the order status and then enter '1' in the relevant record's 'deleted' column. It can be easily undone by changing back to a zero. Link to comment Share on other sites More sharing options...
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