Skip to content

fix(platform-objects): surface sys_user phone_number in list views and detail highlights#3263

Merged
os-zhuang merged 2 commits into
mainfrom
claude/new-user-phone-display-1826e3
Jul 19, 2026
Merged

fix(platform-objects): surface sys_user phone_number in list views and detail highlights#3263
os-zhuang merged 2 commits into
mainfrom
claude/new-user-phone-display-1826e3

Conversation

@baozhoutao

Copy link
Copy Markdown
Contributor

Fixes #3262

问题

启用 phoneNumber 插件后新建带手机号的用户,phone_number 正确落库,但 UI 无处显示:

  • sys_user 所有列表视图的 columns 都没有 phone_number
  • 默认详情页是 slotted 定制页,亮点条与正文分区均为显式白名单,也不含 phone_number

纯手机号用户在各处只显示随机占位邮箱(u-…@placeholder.invalid),看起来像手机号丢了。

修复(2 文件 / 4 行)

  • sys-user.object.tsall_usersme 列表视图的 columnsphone_number(紧跟 email)。
  • sys-user.page.ts:详情页亮点条加 phone_number(与邮箱并列,同为登录标识),并同步加入亮点去重 hideFields 列表。

字段的 zh-CN/ja-JP/es-ES 翻译(「手机号码」等)随 #2766 已存在,列标签与亮点标签自动生效,无需改翻译文件。

验证

  • 真机实测(showcase 示例 + OS_AUTH_PHONE_NUMBER_ENABLED=true + 最新 objectui HMR console):/admin/create-user 创建纯手机号用户 → 「全部用户」列表出现「手机号码」列并显示 +8613800001111 → 记录详情页亮点条显示手机号。
  • packages/platform-objects 213 个测试全部通过;包构建(含 DTS)通过。

纯 bug 修复,无 changeset(per AGENTS.md)。

🤖 Generated with Claude Code

@vercel

vercel Bot commented Jul 19, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
spec Ready Ready Preview, Comment Jul 19, 2026 8:31am

Request Review

@github-actions

Copy link
Copy Markdown
Contributor

📓 Docs Drift Check

This PR changes 1 package(s): @objectstack/platform-objects.

2 hand-written doc(s) reference the affected code and may need an implementation-accuracy re-verification:

  • content/docs/plugins/packages.mdx (via @objectstack/platform-objects)
  • content/docs/ui/setup-app.mdx (via @objectstack/platform-objects)

Advisory only. To re-verify, run the docs-accuracy-audit workflow scoped to these files:
node scripts/docs-audit/affected-docs.mjs origin/main → pass the list as args.docs.

baozhoutao added a commit that referenced this pull request Jul 19, 2026
… timeout defaults in body-runner (#3264)

CI's Test Core intermittently failed sandbox tests with 'hook ... exceeded
timeout of 250ms' (nested-write.integration.test.ts 'rollup_parent_total' on
PR #3263 twice; quickjs-runner.test.ts 'lvl4' on main runs 29678362032 /
29677462748). Root cause: every sandbox invocation compiles a fresh WASM
module (newAsyncContext), and a nested hook compiles another one inside the
parent hook's budget — on a loaded CI runner that fixed cost alone can blow
the 250ms default, while the tests in question are about nested-write
correctness, not the budget.

- body-runner: stop hardcoding the 250ms/5000ms fallbacks as an explicit
  opts.timeoutMs — when neither body nor action declares a timeout, leave it
  unset so QuickJSScriptRunner's constructor defaults (hookTimeoutMs /
  actionTimeoutMs, same 250/5000 values) apply. Default behavior is
  unchanged; the previously dead constructor option now works.
- quickjs-runner.test.ts: shared runner gets hookTimeoutMs 10s (behavioral
  tests); the timeout-resolution suite uses a dedicated stock-default runner
  and asserts the effective budget via the error message ('timeout of
  250ms'/'50ms') instead of a wall-clock bound.
- both nested-write integration tests: construct the runner with
  hookTimeoutMs 10s — their subject is the hook → sandbox → nested-write
  path, not the default budget.

hook-wrappers.ts runWithTimeout was investigated and is not a budget source
here: it only applies when hook metadata declares 'timeout', which these
tests do not.

Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
baozhoutao and others added 2 commits July 19, 2026 03:41
…d detail highlights (#3262)

A user created with a phone number (auth.plugins.phoneNumber) had the
number persisted but displayed nowhere: no list view included a
phone_number column, and the slotted sys_user detail page whitelists
its highlight/detail fields, none of which was phone_number. Phone-only
accounts surfaced only their placeholder email, so the identifier
looked lost.

- add phone_number to the all_users and me list view columns
- promote phone_number into the detail-page highlights strip (next to
  email — both are sign-in identifiers) and the highlights dedup list

Field translations already exist, so column/chip labels localize as-is.
Verified end-to-end against the showcase example (create via
/admin/create-user, column shown in All Users, chip shown on the
record detail).

Fixes #3262

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@os-zhuang
os-zhuang merged commit 183d6d8 into main Jul 19, 2026
16 checks passed
@os-zhuang
os-zhuang deleted the claude/new-user-phone-display-1826e3 branch July 19, 2026 13:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

新建带手机号的用户后,手机号在 UI 无处显示

2 participants