!25 修复权限编辑操作

Merge pull request !25 from Ufec/ufec
This commit is contained in:
Zhao 2021-03-28 14:12:22 +08:00 committed by Gitee
commit 89199a240f

View File

@ -246,7 +246,7 @@ class Auth extends Base {
public function editRule(): Response { public function editRule(): Response {
$id = $this->request->post('id', 0); $id = $this->request->post('id', 0);
$rules = $this->request->post('rules', []); $rules = $this->request->post('rules', []);
if ($rules) { if (is_array($rules)) {
$needAdd = []; $needAdd = [];
$has = (new AdminAuthRule())->where(['group_id' => $id])->select(); $has = (new AdminAuthRule())->where(['group_id' => $id])->select();
$has = Tools::buildArrFromObj($has); $has = Tools::buildArrFromObj($has);