Walrus Posted August 9, 2015 Share Posted August 9, 2015 I cannot see any sales from July onwards in the Dashboard, or in the Stats Dashboard module, in PS 1.6.0.14. I can for previous months. Does anyone have a fix? Some suggest turning on invoices, which is turned on, or clicking Day, then Month but not working for me. TIA. Link to comment Share on other sites More sharing options...
varmedia Posted August 26, 2015 Share Posted August 26, 2015 Tia, I had a similar problem, while looking in the modules (statssale and dashtrends) code I found that the module was filtering only "validated" orders, and my 2 main state (Processing and complete) where not validated. In "Back end" -> "Orders" -> "Statuses" I clicked "Edit" on my statuses "processing" and "completed", then I checked "Consider the associated order as validated." for both of them. This was not backward compatible. To have your stats backward either update trough MySQL or through a script (change 14 byt he correct state_id): UPDATE `ps_orders` SET `valid`=1 WHERE `current_state`=14; Or trough a looping script: <?php require_once 'config/config.inc.php'; $id_order_states = array(13,14); // List state_ids foreach($id_order_states as $id_order_state){ $orders = Order::getOrderIdsByStatus($id_order_state); foreach($orders as $id_order){ $sql = 'UPDATE '._DB_PREFIX_.'orders SET `valid`=1 WHERE `id_order`='. (int) $id_order; $result = Db::getInstance(_PS_USE_SQL_SLAVE_)->execute($sql); } } ?> Or trough a script trough the objects <?php require_once 'config/config.inc.php'; $id_order_states = array(13,14); // List state_ids foreach($id_order_states as $id_order_state){ $orders = Order::getOrderIdsByStatus($id_order_state); foreach($orders as $id_order){ $order = new Order($id_order); $order->valid = true; $order->save(); unset($order); } } ?> Hope it helps. Link to comment Share on other sites More sharing options...
Walrus Posted August 31, 2015 Author Share Posted August 31, 2015 Thanks but order status were already set to validate. Link to comment Share on other sites More sharing options...
Walrus Posted September 3, 2015 Author Share Posted September 3, 2015 Any other ideas anyone?... Am only one having this problem in 16.0.14? If it helps, in the database, current_state is set to #2 for majority of orders, and valid is set to #1. In the Dashboard, there are hundreds of orders under Pending. Why pending? They have been paid for here is no option that I can find to change order from Pending to Validated. There were a dozen or so test orders using Bank Wire but changing their status to Cancelled still shows same number of Pending orders in the Dashboard. In the Orders page, the Status is set to Payment Accepted for majority of orders, and that status is set to automatically validate in Order > Statuses. None of this make any sense. Happy to be enlightened as to what I am doing wrong. 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