Forums / Basic Configuration / Custom sort order of our 22 status bins

Custom sort order of our 22 status bins

Views: 728

Results 1 to 2 of 2
1 Sep 2011, 2:05 PM
#1
sbbemn avatar

sbbemn

Zen Follower

Join Date:
Jan 2010
Posts:
182
Plugin Contributions:
0

Custom sort order of our 22 status bins

There was a thread closed in 2009 that I am highly interested in finding more about. http://www.zen-cart.com/forum/showthread.php?t=105926

I would like to custom sort order the status bins based on ID. We have 22 bins and they don't make much order sense the way they are.

$orders_status = $db->Execute("select orders_status_id, orders_status_name
                                 from " . TABLE_ORDERS_STATUS . "
                                 where language_id = '" . (int)$_SESSION['languages_id'] . "' order by orders_status_id");

For example would I simply list the custom ID numbers accordingly like this :
order by orders_status_id 16,17,1,2,3,8,9,10

I would like to do this to orders, super_order and admin/index.php so I assume the code would be all the same.

1 Sep 2011, 2:20 PM
#2
sbbemn avatar

sbbemn

Zen Follower

Join Date:
Jan 2010
Posts:
182
Plugin Contributions:
0

Re: Custom sort order of our 22 status bins

Note: this is for sort order display purposes only and I would like to keep the orders_status_id as is. Just specify the ID and sort accordingly.

I would like to avoid this direction:
mysql> update orders set orders_status = '5' where orders_status = '3';