shish 3 anni fa
parent
commit
17acd4a622

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

@@ -19,6 +19,11 @@ class StatController extends BaseController
         ini_set('memory_limit', '2045M');
         set_time_limit(0);
 
+        $shopAdmin = $this->shopAdmin;
+        if (isset($shopAdmin->super) == false || $shopAdmin->super != 1) {
+            util::fail('超管才能查看');
+        }
+
         $mainId = $this->mainId;
         $respond = StatSaleClass::profile($mainId);
         $income = $respond['income'] ?? 0;

+ 6 - 0
app-ghs/controllers/StatKdController.php

@@ -12,6 +12,12 @@ class StatKdController extends BaseController
     //各渠道收入 ssh 20220711
     public function actionProfile()
     {
+
+        $shopAdmin = $this->shopAdmin;
+        if (isset($shopAdmin->super) == false || $shopAdmin->super != 1) {
+            util::fail('超管才能查看');
+        }
+
         $get = Yii::$app->request->get();
         $contain = $get['contain'] ?? 0;
         $incomeList = StatKdClass::eachChannelIncome($this->mainId, $this->shop, $contain);