admin select

This commit is contained in:
zhao 2020-05-03 15:06:25 +08:00
parent c6e2ee23ac
commit 32a1f8b13e

View File

@ -71,7 +71,7 @@ class AuthAccess extends AdminController
return json($res); return json($res);
} }
$admins = Db::name('admin')->field('id,username')->select(); $admins = Db::name('admin')->field('id,username')->where('delete_time',0)->select();
$auth_groups = Db::name('auth_group')->field('id,title')->select(); $auth_groups = Db::name('auth_group')->field('id,title')->select();
View::assign(['admins'=>$admins,'auth_groups'=>$auth_groups]); View::assign(['admins'=>$admins,'auth_groups'=>$auth_groups]);
@ -99,7 +99,7 @@ class AuthAccess extends AdminController
} }
$access = Db::name('auth_group_access')->group('uid')->find($id); $access = Db::name('auth_group_access')->group('uid')->find($id);
$admins = Db::name('admin')->field('id,username')->select(); $admins = Db::name('admin')->field('id,username')->where('delete_time',0)->select();
$auth_groups = Db::name('auth_group')->field('id,title')->select(); $auth_groups = Db::name('auth_group')->field('id,title')->select();
View::assign(['admins'=>$admins,'auth_groups'=>$auth_groups,'access'=>$access]); View::assign(['admins'=>$admins,'auth_groups'=>$auth_groups,'access'=>$access]);