From badb3bca312e1873de1ab39fbdb1e6acd75099c7 Mon Sep 17 00:00:00 2001 From: tping Date: Tue, 29 Jun 2021 16:31:13 +0800 Subject: [PATCH 1/3] =?UTF-8?q?=E8=AE=BE=E7=BD=AE=E6=9D=83=E9=99=90?= =?UTF-8?q?=E3=80=81admin=E3=80=81=E5=B8=82=E5=9C=BA=E6=80=BB=E7=9B=91?= =?UTF-8?q?=E5=8F=AF=E4=BB=A5=E7=9C=8B=E6=89=80=E6=9C=89=E6=95=B0=E6=8D=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Admin/Controller/SocietyInfoController.class.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Application/Admin/Controller/SocietyInfoController.class.php b/Application/Admin/Controller/SocietyInfoController.class.php index a103e12cd..634933eb3 100644 --- a/Application/Admin/Controller/SocietyInfoController.class.php +++ b/Application/Admin/Controller/SocietyInfoController.class.php @@ -31,8 +31,9 @@ class SocietyInfoController extends ThinkController { $model = M($this->modelName, 'tab_'); $map = []; - if ($this->admininfo['username'] == "admin" || isMarketLeader()) { - // admin 和 市场总监可以看所有数据 + + if ($this->checkRule("Admin/SocietyInfo/lists", array('in','1,2')) || isMarketLeader() || is_administrator()) { + // 设置权限、admin、市场总监可以看所有数据 } else { // 其他用户只能看自己的 $map['create_account'] = $this->admininfo['username']; @@ -125,7 +126,6 @@ class SocietyInfoController extends ThinkController return ; } else { $societyInfos = $order_query->page($page,$row)->field("*")->select(); -// dump($order_query->_sql());die(); } //分页 From d8b2a161afa6e6a32d26b3fa9c230e78258e3178 Mon Sep 17 00:00:00 2001 From: tping Date: Wed, 30 Jun 2021 10:34:24 +0800 Subject: [PATCH 2/3] =?UTF-8?q?=E6=9D=83=E9=99=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Admin/Controller/SocietyInfoController.class.php | 8 ++++++-- Application/Admin/View/SocietyInfo/lists.html | 6 ++++-- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/Application/Admin/Controller/SocietyInfoController.class.php b/Application/Admin/Controller/SocietyInfoController.class.php index 634933eb3..bee8324a7 100644 --- a/Application/Admin/Controller/SocietyInfoController.class.php +++ b/Application/Admin/Controller/SocietyInfoController.class.php @@ -157,9 +157,13 @@ class SocietyInfoController extends ThinkController if (IS_ROOT) { $this->assign('timeset_check',true); $this->assign('delset_check',true); + $this->assign('export_check', true); + $this->assign('import_check', true); } else { - $this->assign('timeset_check',$this->checkRule("Admin/SocietyInfo/timeset" ,array('in','1,2'))); - $this->assign('delset_check',$this->checkRule("Admin/SocietyInfo/delset" ,array('in','1,2'))); + $this->assign('timeset_check', $this->checkRule("Admin/SocietyInfo/timeset" ,array('in','1,2'))); + $this->assign('delset_check', $this->checkRule("Admin/SocietyInfo/delset" ,array('in','1,2'))); + $this->assign('export_check', $this->checkRule("Admin/Society/lists_export_check" ,array('in','1,2'))); + $this->assign('import_check', $this->checkRule("Admin/SocietyInfo/excelImport" ,array('in','1,2'))); } diff --git a/Application/Admin/View/SocietyInfo/lists.html b/Application/Admin/View/SocietyInfo/lists.html index 420c8359c..e85d91ee4 100644 --- a/Application/Admin/View/SocietyInfo/lists.html +++ b/Application/Admin/View/SocietyInfo/lists.html @@ -108,10 +108,12 @@ 新增
- 导入 + + 导入 +
- + 导出
From f9b1501095738852884d0e3b944cce54aa70efe8 Mon Sep 17 00:00:00 2001 From: tping Date: Wed, 30 Jun 2021 10:35:26 +0800 Subject: [PATCH 3/3] =?UTF-8?q?=E6=9D=83=E9=99=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Application/Admin/View/SocietyInfo/lists.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Application/Admin/View/SocietyInfo/lists.html b/Application/Admin/View/SocietyInfo/lists.html index e85d91ee4..37a25826b 100644 --- a/Application/Admin/View/SocietyInfo/lists.html +++ b/Application/Admin/View/SocietyInfo/lists.html @@ -108,7 +108,7 @@ 新增
- + 导入