declare namespace ApiTypes { namespace Common { namespace Admins { type List = { "username"?: string; // 模糊搜索:名称 }; type Store = { "username": string; // 用户名 "password": string; // 密码 "roles_id"?: string[]; // 角色 }; type Update = { "id": number; // id "username": string; // 用户名/手机号 "password"?: string; // 密码,[hidden] "roles_id"?: string[]; // 角色 }; type Delete = { "id": number; // id }; type Select = { "username"?: string; // 模糊搜索:名称 }; } namespace Auth { type Login = { "username": string; // 用户名 "password": string; // 密码 }; type ChangePassword = { "old_password": string; // 老密码 "new_password": string; // 新密码 "re_new_password": string; // 重复新密码 }; type PreUpload = { "filename": string; // 文件名称 "alc": string; // 访问限制 public-read, private }; type TemporaryUrl = { "filename": string; // 文件名称 }; } } namespace Permission { namespace SysPermissions { type List = { "parent_id"?: number; // 上级ID "guard_name": string; // }; type Tree = { "parent_id"?: number; // 上级ID "guard_name": string; // }; type Store = { "name": string; // "key"?: string; // "guard_name": string; // "icon"?: string; // 图标 "type": string; // 类型:SysPermissionsTypeEnum "backend_apis"?: string[]; // 后台api "path"?: string; // 路由 "parent_id"?: number; // }; type Update = { "id": number; // ID "name": string; // "key"?: string; // "guard_name": string; // "icon"?: string; // 图标 "type": string; // 类型:SysPermissionsTypeEnum "backend_apis"?: string[]; // 后台api "path"?: string; // 路由 "parent_id"?: number; // }; type Delete = { "id": number; // ID }; type Move = { "id": number; // ID "type": string; // 类型:up 升级,down 降级 }; } namespace SysRoles { type List = { "name"?: string; // 模糊搜索:名称 }; type Store = { "name": string; // 名称 "color"?: string; // 颜色 }; type Update = { "id": number; // ID "name": string; // 名称 "color"?: string; // 颜色 }; type Delete = { "id": number; // ID }; type GetPermissions = { "id": number; // ID }; type SetPermissions = { "id": number; // ID "permissions_ids": string[]; // 权限ID }; } } }