wugg 2 years ago
parent
commit
08f69c54a3
2 changed files with 1 additions and 1 deletions
  1. 0 1
      app/admin/BaseController.php
  2. 1 0
      app/admin/controller/Menu.php

+ 0 - 1
app/admin/BaseController.php

@@ -54,7 +54,6 @@ class BaseController extends base{
             }
             $this->roleid=$role['roleid'];
             $this->level=Db::name("role")->where(["id"=>$role['roleid'],"status"=>1])->value("level",'');
-            if($this->level=='') return ["code"=>101,"message"=>"账户角色已禁用"];
              return ["code"=>0,"message"=>"验证通过"];
      }
 

+ 1 - 0
app/admin/controller/Menu.php

@@ -18,6 +18,7 @@ class Menu extends BaseController{
 	 */
     public function MenuList(){
     	$condition =["status"=>1,"is_del"=>0];
+    	 if($this->level=='') return app_show(101,"账户角色已禁用",[]);
 		if ($this->roleid!=1){
 			 $role = Db::name("role_action")->where("role_id","=",$this->roleid)->find();