feat(需求): ①用户管理补「角色」筛选(前端+后端 role 参数) ②软件/数字人版本页补版本号搜索 ③全站 el-select 统一 filterable(分组/所属管理员/角色等大下拉可模糊搜索)

This commit is contained in:
2026-09-06 23:43:00 +08:00
parent 970affec95
commit f00fdcd42a
10 changed files with 115 additions and 25 deletions
+4
View File
@@ -13,6 +13,8 @@ export interface UserListParams {
keyword?: string
createdById?: number | null
adminId?: number | null
/** 角色过滤(''=全部)。 */
role?: string
}
/** 序列化到 GET /api/admin/users 的查询参数(Java snake_case)。 */
@@ -23,6 +25,7 @@ export interface UserListQuery {
search?: string
created_by_id?: number
admin_id?: number
role?: string
}
/** 用户列表项即 AdminUser(与 Java AdminUserItemVo 字段对齐)。 */
@@ -67,6 +70,7 @@ export function toUserListQuery(params: UserListParams): UserListQuery {
if (params.keyword) query.username = params.keyword
if (params.createdById != null) query.created_by_id = params.createdById
if (params.adminId != null) query.admin_id = params.adminId
if (params.role) query.role = params.role
return query
}