diff --git a/controllers/admin/AdminOrdersController.php b/controllers/admin/AdminOrdersController.php index 8f980e828..47a8bfd22 100755 --- a/controllers/admin/AdminOrdersController.php +++ b/controllers/admin/AdminOrdersController.php @@ -1300,7 +1300,7 @@ class AdminOrdersControllerCore extends AdminController // display warning if there are products out of stock $display_out_of_stock_warning = false; $current_order_state = $order->getCurrentOrderState(); - if (configuration::get('PS_STOCK_MANAGEMENT') && (!Validate::isLoadedObject($current_order_state) || ($current_order_state->delivery != 1 && $current_order_state->shipped != 1))) + if (Configuration::get('PS_STOCK_MANAGEMENT') && (!Validate::isLoadedObject($current_order_state) || ($current_order_state->delivery != 1 && $current_order_state->shipped != 1))) $display_out_of_stock_warning = true; // products current stock (from stock_available) diff --git a/controllers/admin/AdminProductsController.php b/controllers/admin/AdminProductsController.php index ccef97b8f..97d5ae9b0 100644 --- a/controllers/admin/AdminProductsController.php +++ b/controllers/admin/AdminProductsController.php @@ -249,14 +249,15 @@ class AdminProductsControllerCore extends AdminController 'havingFilter' => true, 'orderby' => false ); - $this->fields_list['sav_quantity'] = array( - 'title' => $this->l('Quantity'), - 'width' => 90, - 'align' => 'right', - 'filter_key' => 'sav!quantity', - 'orderby' => true, - 'hint' => $this->l('This is the quantity available in the current shop/group.'), - ); + if (Configuration::get('PS_STOCK_MANAGEMENT')) + $this->fields_list['sav_quantity'] = array( + 'title' => $this->l('Quantity'), + 'width' => 90, + 'align' => 'right', + 'filter_key' => 'sav!quantity', + 'orderby' => true, + 'hint' => $this->l('This is the quantity available in the current shop/group.'), + ); $this->fields_list['active'] = array( 'title' => $this->l('Status'), 'width' => 70,