fix: 列表/看板中系统用户字段由账号改为显示真实姓名 #43
No reviewers
Labels
No labels
area/app
area/back
area/deploy
area/front
area/gis
size/L
size/M
size/S
type/chore
type/docs
type/feat
type/fix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
jiaoce/xm_txys2_front!43
Loading…
Reference in a new issue
No description provided.
Delete branch "fix/display-user-realname"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
变更摘要
全站统一:原本在列表/看板/详情中直接展示系统用户账号(如申请人、负责人、确认人等)的字段,现统一改为展示真实姓名。
src/utils/userName.ts:全局单例缓存,进入相关页面时单次拉取/sys/user/list,构建 账号/ID → 姓名 映射;导出useUserMap()与displayName(val, map)。displayName对空值返回—,已为姓名的值原样返回,保证对“本就是姓名”的字段安全无副作用。自测步骤
npm run build通过(vue-tsc 无类型错误,Vite 构建成功)。文档影响
无(纯前端展示层改动,不涉及接口协议或数据结构)。