shish před 3 roky
rodič
revize
baa55eca1c
1 změnil soubory, kde provedl 5 přidání a 0 odebrání
  1. 5 0
      app-ghs/controllers/ProductController.php

+ 5 - 0
app-ghs/controllers/ProductController.php

@@ -112,6 +112,7 @@ class ProductController extends BaseController
         $status = Yii::$app->request->get('status', 1);
         //默认显示未删除商品
         $delStatus = Yii::$app->request->get('delStatus', 0);
+        $warning = Yii::$app->request->get('warning', 0);
 
         //获取所有当前供货商的分类 (全部、常用)
         //根据分类组装分类下的花材信息
@@ -132,6 +133,10 @@ class ProductController extends BaseController
         }
         $where['delStatus'] = $delStatus;
 
+        if ($warning == 1) {
+            $where['stock<'] = 'stockWarning';
+        }
+
         //客户等级
         $customId = Yii::$app->request->get('customId', 0);
         $level = 1;