修改基类

This commit is contained in:
yanwenwu
2018-11-22 09:53:19 +08:00
parent ff297f692e
commit a186eacc8f
3 changed files with 4 additions and 5 deletions

View File

@@ -1,6 +1,7 @@
<?php
namespace app\admin\controller;
use think\Exception;
use think\permissions\facade\Roles;
use app\validates\RoleValidate;
use think\permissions\facade\Permissions;
@@ -47,10 +48,8 @@ class Role extends Base
}
Roles::updateBy($data['id'], $data) !== false ? $this->success('编辑成功', url('role/index')) : $this->error('编辑失败');
}
$roleId = $this->request->param('id');
$role = Roles::getRoleBy($roleId);
$this->role = $role;
$this->role = Roles::getRoleBy($this->request->param('id'));
return $this->fetch();
}