[更新]修复权限禁用后仍然可以读取节点

This commit is contained in:
邹景立 2017-03-23 13:32:32 +08:00
parent 9aa9691818
commit 7e4d270fd6

View File

@ -14,6 +14,7 @@
namespace app\admin\model;
use think\Config;
use think\Db;
/**
@ -36,7 +37,7 @@ class Node {
if (empty($authorizeids)) {
return session('user.nodes', []);
}
$nodes = Db::name('SystemAuthNode')->where('auth', 'in', explode(',', $authorizeids))->column('node');
$nodes = Db::name('SystemAuthNode')->where('auth', 'in', $authorizeids)->column('node');
return session('user.nodes', $nodes);
}
return false;