shish 4 лет назад
Родитель
Сommit
4d28ae789d
1 измененных файлов с 5 добавлено и 0 удалено
  1. 5 0
      app-ghs/controllers/CustomLevelController.php

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

@@ -35,6 +35,11 @@ class CustomLevelController extends BaseController
     //添加修改等级 shish 20211016
     public function actionReplace()
     {
+        $shopAdmin = $this->shopAdmin;
+        if (isset($shopAdmin->super) == false || $shopAdmin->super != 1) {
+            util::fail('管理员才能操作');
+        }
+
         $post = Yii::$app->request->post();
         $info = CustomLevelClass::getByCondition(['shopId' => $this->shopId], true);
         if (empty($info)) {