feat(identity): 展示名与头像以官网为权威源,桌面端可改昵称头像,用户名退成内部标识(dev-board#564-567) - #797
Merged
Conversation
…#565 #566 #567) 案件库:AwdkLoginService.resolveUser 与 CollaboratorAdmission 每次桥接/名录回查刷新展示名(username 不动); 参与人列表头像改用 avatarUrlFor(桥接用户取官网 /api/avatar/{accountId});版本作者 userName 改 displayName。 桌面端后端(local-mode):新增 GET/PUT /api/account/profile、POST/DELETE /api/account/avatar,经 Bearer 透传官网 (PUT→PATCH,multipart 编码已对真实 formData 解析器验过);AccountIdentitySync 在连接、status、每次写入后把官网 displayName/avatarUrl 同步到本机 User 行与 account.json,官网不可达静默跳过;account.json 增 accountId。 桌面端前端:个人设置「基本信息」头像可传可删、昵称内联可编辑(local-mode 且已连接账户走官网,自建服务器保持只读 与本机头像上传);displayNameIsDefault 时给「填写你的姓名」引导(内联 + 连接后弹一次,按 accountId 记已读); 去掉侧栏与新建项目页的 @用户名、参与人列表与页面上的 username 回落、LibreOfficeEditor 作者名不再回落 username; 新增 tests/identity 契约测试(源码扫描 + 允许名单带理由)并进 CI。 验证:后端全量 3572 项零失败;前端 test:identity 10 / member-invite 27 / build:h5 绿;multipart 用 jshell 对 Node formData 解析器验证字段名、文件名、类型、大小、哈希一致。 Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
背景
手机号注册账户用户名是随机串、展示名是打码手机号(线上 14/25);案件库与桌面端各抄一份不再同步;版本时间线与文档批注/修订作者直接写用户名。维护者裁决见
docs/superpowers/specs/2026-09-10-identity-display-source-design.md。官网侧 zeweihan/aiworkdeck_website#171 已合并部署。卡:zeweihan/dev-board#564 #565 #566 #567。改动
avatarUrlFor(桥接用户取官网);版本作者改 displayName。GET/PUT /api/account/profile、POST/DELETE /api/account/avatar经 Bearer 透传官网;AccountIdentitySync在连接/status/写入后把官网身份同步到本机 User 行与 account.json;官网不可达静默跳过。tests/identity契约测试进 CI(允许名单五条各带理由)。验证
mvn -B test:3572 项,0 失败;目标集 149 项。test:identity10、test:member-invite27、check:nav:full/check:locales/check:emits、build:h5全绿;七个 SFC 编译通过。Request.formData()解析器:字段 file、文件名清洗、image/png、3000 字节、sha 一致,Bearer 在。|| m.username→ 契约测试转红。上线
合并后案件库换 jar(展示名刷新与参与人头像立刻生效)。桌面端随集中发版。
🤖 Generated with Claude Code