Post by iplocker » Tue Sep 13, 2016 11:49 pm

Hello.

When I am trying to sort order by Status at admin here: http://prntscr.com/chkdvn
I am getting a Fatal Error:

Code: Select all

Fatal error: Uncaught exception 'Exception' with message 'Error: Unknown column 'status' in 'order clause'<br />Error No: 1054<br />SELECT o.order_id, CONCAT(o.firstname, ' ', o.lastname) AS customer, (SELECT os.name FROM sydf_order_status os WHERE os.order_status_id = o.order_status_id AND os.language_id = '1') AS order_status, o.shipping_code, o.total, o.currency_code, o.currency_value, o.date_added, o.date_modified FROM `sydf_order` o WHERE o.order_status_id > '0' ORDER BY status ASC LIMIT 0,100' in /home/site/public_html/system/library/db/mysqli.php:40 Stack trace: #0 /home/site/public_html/system/library/db.php(16): DB\MySQLi->query('SELECT o.order_...', Array) #1 /home/site/public_html/admin/model/sale/order.php(229): DB->query('SELECT o.order_...') #2 [internal function]: ModelSaleOrder->getOrders(Array) #3 /home/site/public_html/vqmod/vqcache/vq2-system_storage_modification_system_engine_loader.php(161): call_user_func_array(Array, Array) #4 [internal function]: Loader->{closure}(Array) #5 /home/es in /home/site/public_html/system/library/db/mysqli.php on line 40
http://prntscr.com/chk58k

Anybody knows why ?

Thanks

Active Member

Posts

Joined
Sun May 26, 2013 6:39 pm


Post by iplocker » Wed Sep 14, 2016 10:31 pm

OK it seems its a BUG as there is not status column at order_status table : http://prntscr.com/chxp3z
Dont know if this has been fixed at 2.3.0.2 as there is not changelong betwean 2.2 and 2.3.0.2 version !

Thanks

Active Member

Posts

Joined
Sun May 26, 2013 6:39 pm


Post by mleira » Thu Sep 15, 2016 12:15 am

Para corrigir o problema, alterar
/admin/model/sale/order.php
linha:1199 trocar status por order_status

trocar
---------------------------------------

Code: Select all

		$sort_data = array(
			'o.order_id',
			'customer',
			'status',
			'o.date_added',
			'o.date_modified',
			'o.total'
		);
---------------------------------------
por
---------------------------------------

Code: Select all

		$sort_data = array(
			'o.order_id',
			'customer',
			'order_status',
			'o.date_added',
			'o.date_modified',
			'o.total'
		);
---------------------------------------

Newbie

Posts

Joined
Sat Jun 08, 2013 1:16 am

Post by pm-netti » Thu Sep 15, 2016 12:28 am

iplocker wrote:OK it seems its a BUG as there is not status column at order_status table : http://prntscr.com/chxp3z
Dont know if this has been fixed at 2.3.0.2 as there is not changelong betwean 2.2 and 2.3.0.2 version !

Thanks
That is to table `order`:

Code: Select all

..... o.currency_value, o.date_added, o.date_modified FROM `sydf_order` o WHERE o.order_status_id > '0' ORDER BY status ASC LIMIT 0,100' 
If column status is found, this need be:

Code: Select all

..... o.currency_value, o.date_added, o.date_modified FROM `sydf_order` o WHERE o.order_status_id > '0' ORDER BY o.status ASC LIMIT 0,100' 
Is this your extension issue?

Code: Select all

/home/site/public_html/vqmod/vqcache/.....

User avatar
Active Member

Posts

Joined
Sat Apr 07, 2012 11:22 pm
Location - Kittilä, Finland

Post by iplocker » Sat Nov 05, 2016 5:50 pm


Active Member

Posts

Joined
Sun May 26, 2013 6:39 pm


Post by kestas » Mon Apr 10, 2017 5:08 pm

If You have installed VQMOD just use attached xml. This fix the bug.

Attachments

fix status sort order bug in admin orders OCMOD

fix status sort order bug in admin orders


Custom OpenCart modules and solutions. You can write PM with additional questions... Extensions you can find here


Active Member

Posts

Joined
Tue Oct 12, 2010 2:23 am
Who is online

Users browsing this forum: No registered users and 5 guests