瀏覽代碼

阿东的创始人才能查看采购单

shish 4 年之前
父節點
當前提交
5803429083
共有 1 個文件被更改,包括 16 次插入0 次删除
  1. 16 0
      app-ghs/controllers/PurchaseOrderController.php

+ 16 - 0
app-ghs/controllers/PurchaseOrderController.php

@@ -157,12 +157,20 @@ class PurchaseOrderController extends BaseController
     {
 
         if (getenv('YII_ENV') == 'production') {
+            //阿东的创始人才能查看采购单
             if ($this->mainId == 742) {
                 $staff = $this->shopAdmin;
                 if (isset($staff['founder']) == false || $staff['founder'] != 2) {
                     util::fail('没有权限');
                 }
             }
+        }else{
+            if ($this->mainId == 661) {
+                $staff = $this->shopAdmin;
+                if (isset($staff['founder']) == false || $staff['founder'] != 2) {
+                    util::fail('没有权限');
+                }
+            }
         }
 
         $get = Yii::$app->request->get();
@@ -188,12 +196,20 @@ class PurchaseOrderController extends BaseController
     {
 
         if (getenv('YII_ENV') == 'production') {
+            //阿东的创始人才能查看采购单
             if ($this->mainId == 742) {
                 $staff = $this->shopAdmin;
                 if (isset($staff['founder']) == false || $staff['founder'] != 2) {
                     util::fail('没有权限');
                 }
             }
+        }else{
+            if ($this->mainId == 661) {
+                $staff = $this->shopAdmin;
+                if (isset($staff['founder']) == false || $staff['founder'] != 2) {
+                    util::fail('没有权限');
+                }
+            }
         }
 
         $orderSn = Yii::$app->request->get('orderSn', '');