feat: 新增角色列表

This commit is contained in:
xlsea
2025-05-09 23:26:09 +08:00
parent b70ddb31e9
commit 67b5af9892
25 changed files with 869 additions and 125 deletions

View File

@ -10,10 +10,13 @@ declare namespace Api {
* backend api module: "system"
*/
namespace System {
/** data scope */
type DataScope = '1' | '2' | '3' | '4' | '5' | '6';
/** role */
type Role = Common.CommonRecord<{
/** 数据范围1全部数据权限 2自定数据权限 3本部门数据权限 4本部门及以下数据权限 */
dataScope: string;
dataScope: DataScope;
/** 部门树选择项是否关联显示 */
deptCheckStrictly: boolean;
/** 用户是否存在此角色标识 默认不存在 */
@ -45,21 +48,19 @@ declare namespace Api {
type RoleOperateParams = CommonType.RecordNullable<
Pick<
Api.System.Role,
| 'roleId'
| 'roleName'
| 'roleKey'
| 'roleSort'
| 'dataScope'
| 'menuCheckStrictly'
| 'deptCheckStrictly'
| 'status'
| 'remark'
>
'roleId' | 'roleName' | 'roleKey' | 'roleSort' | 'menuCheckStrictly' | 'status' | 'remark'
> & { menuIds: CommonType.IdType[] }
>;
/** role list */
type RoleList = Common.PaginatingQueryRecord<Role>;
/** role menu tree select */
type RoleMenuTreeSelect = Common.CommonRecord<{
checkedKeys: CommonType.IdType[];
menus: MenuList;
}>;
/** all role */
type AllRole = Pick<Role, 'roleId' | 'roleName' | 'roleKey'>;
@ -261,6 +262,8 @@ declare namespace Api {
parentName: string;
/** 子菜单 */
children: MenuList;
id?: CommonType.IdType;
label?: string;
}>;
/** menu list */