d8b678f2 by Zelig

cookie

1 parent 4db1e873
......@@ -25,6 +25,7 @@ if(!function_exists('hasRole')) {
$CI = &get_instance();
$CI->load->helper('cookie');
$login_user = get_cookie('login_user');
if($login_user) {
$login_user = json_decode($login_user, true);
foreach($login_user['roleKeys'] as $v){
if(in_array($v, $roles)){
......@@ -33,4 +34,5 @@ if(!function_exists('hasRole')) {
}
return false;
}
}
}
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!