修改权限判断
This commit is contained in:
@@ -85,6 +85,7 @@ class ApiAuthHook
|
||||
|
||||
private function set_session($userId)
|
||||
{
|
||||
$uri_string = uri_string();
|
||||
$_SESSION['userId'] = intval($userId);
|
||||
$this->CI->load->model('agent/admin/Market_sys_admin_model');
|
||||
$re_admin = $this->CI->Market_sys_admin_model->get(['userId' => $userId, 'status' => 0]);
|
||||
@@ -119,7 +120,7 @@ class ApiAuthHook
|
||||
}
|
||||
}
|
||||
}
|
||||
if ($authority_set) {
|
||||
if ($authority_set && !in_array($uri_string, $this->route_un)) {
|
||||
$show = true;
|
||||
$authority = $authorityAry[1] . ':' . $authorityAry[2] . ':' . $authority_set;//system:user:save
|
||||
if ($menuIds) {
|
||||
@@ -153,6 +154,7 @@ class ApiAuthHook
|
||||
|
||||
private function set_session_pingan($userId)
|
||||
{
|
||||
$uri_string = uri_string();
|
||||
$_SESSION['userId'] = intval($userId);
|
||||
$this->CI->load->model('agent/pingan/Pingan_users_model');
|
||||
$re_admin = $this->CI->Pingan_users_model->get(['id' => $userId, 'status' => 1]);
|
||||
@@ -187,7 +189,7 @@ class ApiAuthHook
|
||||
}
|
||||
}
|
||||
}
|
||||
if ($authority_set) {
|
||||
if ($authority_set && !in_array($uri_string, $this->route_un)) {
|
||||
$show = true;
|
||||
$authority = $authorityAry[1] . ':' . $authorityAry[2] . ':' . $authority_set;//system:user:save
|
||||
if ($menuIds) {
|
||||
|
||||
Reference in New Issue
Block a user