Skip to content

Commit 8e5adb9

Browse files
baozhoutaoclaude
andcommitted
fix(platform-objects): surface sys_user phone_number in list views and 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>
1 parent 611402f commit 8e5adb9

2 files changed

Lines changed: 4 additions & 3 deletions

File tree

packages/platform-objects/src/identity/sys-user.object.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -433,7 +433,7 @@ export const SysUser = ObjectSchema.create({
433433
name: 'me',
434434
label: 'My Profile',
435435
data: { provider: 'object', object: 'sys_user' },
436-
columns: ['name', 'email', 'email_verified', 'two_factor_enabled', 'updated_at'],
436+
columns: ['name', 'email', 'phone_number', 'email_verified', 'two_factor_enabled', 'updated_at'],
437437
filter: [{ field: 'id', operator: 'equals', value: '{current_user_id}' }],
438438
sort: [{ field: 'name', order: 'asc' }],
439439
pagination: { pageSize: 1 },
@@ -443,7 +443,7 @@ export const SysUser = ObjectSchema.create({
443443
name: 'all_users',
444444
label: 'All Users',
445445
data: { provider: 'object', object: 'sys_user' },
446-
columns: ['name', 'email', 'email_verified', 'source', 'two_factor_enabled', 'created_at'],
446+
columns: ['name', 'email', 'phone_number', 'email_verified', 'source', 'two_factor_enabled', 'created_at'],
447447
sort: [{ field: 'name', order: 'asc' }],
448448
pagination: { pageSize: 50 },
449449
},

packages/platform-objects/src/pages/sys-user.page.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ export const SysUserDetailPage: Page = {
9595
highlights: {
9696
type: 'record:highlights',
9797
properties: {
98-
fields: ['email', 'email_verified', 'two_factor_enabled', 'role'],
98+
fields: ['email', 'phone_number', 'email_verified', 'two_factor_enabled', 'role'],
9999
},
100100
},
101101

@@ -110,6 +110,7 @@ export const SysUserDetailPage: Page = {
110110
'ban_expires',
111111
// already promoted to highlights:
112112
'email',
113+
'phone_number',
113114
'email_verified',
114115
'two_factor_enabled',
115116
'role',

0 commit comments

Comments
 (0)