From 26389290318569fced14fc666820eb2ad5564596 Mon Sep 17 00:00:00 2001 From: ELF <360197197@qq.com> Date: Fri, 18 Oct 2019 14:07:34 +0800 Subject: [PATCH] =?UTF-8?q?=E9=80=9A=E8=BF=87=E5=B8=90=E5=8F=B7=E9=9A=90?= =?UTF-8?q?=E8=97=8F=E7=9B=AE=E5=BD=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Application/Home/Controller/BaseController.class.php | 3 ++- .../Home/Controller/PromoteController.class.php | 7 +++++-- Application/Home/View/default/Public/promote_base.html | 10 ++++++++++ 3 files changed, 17 insertions(+), 3 deletions(-) diff --git a/Application/Home/Controller/BaseController.class.php b/Application/Home/Controller/BaseController.class.php index 5db490250..ef4a8e3d5 100644 --- a/Application/Home/Controller/BaseController.class.php +++ b/Application/Home/Controller/BaseController.class.php @@ -25,7 +25,8 @@ class BaseController extends HomeController{ define('SETTLEMENT_GRADE','sub_status'); /* 给二级结算 */ define('G_SETTLEMENT_GRADE','sub_status,third_status'); } - + + $this->assign('loginer', $pro); $this->assign("parent_id", $pro['parent_id']); $this->assign("grand_id", $pro['grand_id']); $result = M('site_apply','tab_')->where("promote_id=$pid")->getField('status'); diff --git a/Application/Home/Controller/PromoteController.class.php b/Application/Home/Controller/PromoteController.class.php index 789c7ea94..81e738c27 100644 --- a/Application/Home/Controller/PromoteController.class.php +++ b/Application/Home/Controller/PromoteController.class.php @@ -36,8 +36,11 @@ class PromoteController extends BaseController public function index($p = 1) { $this->meta_title = "首页"; - $this->display('prepare'); - exit(0); + $loginPromote = $this->getLoginPromote(); + if ($loginPromote['id'] != 1 && $loginPromote['parent_id'] != 1 && $loginPromote['grand_id'] != 1) { + $this->display('prepare'); + exit(0); + } header("Content-type:text/html;charset=utf-8"); $user = D('Promote')->isLogin(); diff --git a/Application/Home/View/default/Public/promote_base.html b/Application/Home/View/default/Public/promote_base.html index 9c9380ebf..edbb370ae 100644 --- a/Application/Home/View/default/Public/promote_base.html +++ b/Application/Home/View/default/Public/promote_base.html @@ -47,6 +47,9 @@ 推广员管理 + + +