Repository navigation
fix(app-shell): after a datasource sync, link each new object and name the steps left; the form labels a label-less field like the list - #30493
Merged
Conversation
…names the steps left After Sync creates objects, the dialog stays open on the result: a link to each created object, opened under the app the page is in, and the two steps left before people can use it (add it to an app, grant access in a permission set). A run that creates nothing closes the dialog as before. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01L6bhgVaDMZ9FxV4kMaNFGU
…as in the list A declared field with no label is drawn under its name with the first letter capitalised and underscores as spaces, the rule the list header uses, instead of the raw field name. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01L6bhgVaDMZ9FxV4kMaNFGU
Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01L6bhgVaDMZ9FxV4kMaNFGU
Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01L6bhgVaDMZ9FxV4kMaNFGU
Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01L6bhgVaDMZ9FxV4kMaNFGU
… describes Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01L6bhgVaDMZ9FxV4kMaNFGU
Contributor
Author
|
domain:ui#5 · os-sales · session_01L6bhgVwQZbHRRM9CaXeKif Contract reviewServed-tier: Reviewed 2026-11-05T13:45Z. Face: the ① Derived judgments
② Semver level
③ Boundary flags
Implemented-by: VERDICT: PASS |
Contributor
Author
|
domain:ui#5 · os-sales · session_01L6bhgVwQZbHRRM9CaXeKif 维护者速读
席位核对 — ACCEPT · domain:ui#5 · head
|
This was referenced Nov 5, 2026
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 join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
domain:ui#5 · os-sales · session_01L6bhgVaDMZ9FxV4kMaNFGU
Requested by Sales · project thread
Part of #30328
Clause-②: yes (widening)
Metadata-protocol: none
维护者速读
part_no→Part no),不再直接显示字段名。Part name、表单叫part_name。ui/packages/app-shell/src/views/metadata-admin/datasource/DatasourceResourcePage.tsx(SyncResultNote、runSync结尾)、ui/packages/plugin-form/src/sectionFields.ts的fieldNameLabel、ui/packages/i18n/src/namespaces/studio/zh.ts的engine.datasource.syncNextStep*。pnpm --dir ui exec vitest run packages/app-shell/src/views/metadata-admin/datasource/DatasourceResourcePage.syncNextSteps-30328.test.tsx packages/plugin-form/src/ObjectForm.fieldNameLabel-30328.test.tsx,预期 7 个用例全绿。What changes
Card #30328, the domain:ui half only. The server half (the object draft's field labels, and which package a synced object lives in and whether it exports under ADR-0146) is #30469, so this PR does not close the card.
SyncResultNote): the count line, one link per created object (label, with the name beside it when they differ), and a box naming the two steps left before people can use it: add it to an app, and grant access in a permission set. The link opens the object under the app the page is in (/apps/SEGMENT/OBJECT, read from the current path; Setup when the path names no app). It is a routerLink, so the console navigates in place.SyncResultNoteis the only part of the page that reads the router, and it mounts only after a sync, so the page's other test files, which render without a router, are unchanged. A run that creates nothing closes the dialog as before; refused tables still go to the error toast either way. The dialog's footer offers Close on the result.labelwas drawn in the form under its raw name (ObjectFormgenerated fields andfromObjectSchemaboth usedfield.label || fieldName), while the list draws it under the name with the first letter capitalised and underscores as spaces (objectGridGenerateColumnsin plugin-grid, the same expression in four places there).fieldNameLabel()insectionFields.tsis that rule, and both form paths now use it as the fallback passed tofieldLabel(), so a translation still wins and an authored label is unchanged.FieldSchema.labelis optional in the spec, so this is the renderer's rule for valid metadata, not a tolerance for invalid metadata. plugin-grid is unchanged and no@object-ui/coreexport is added (claim amendment 6658567034).studionamespace rows, en and zh:engine.datasource.syncNextStepsOne,engine.datasource.syncNextSteps,engine.datasource.syncNextStepApp,engine.datasource.syncNextStepAccess. The count line reusesengine.datasource.syncedOne/syncedand the button reusesengine.close..changeset/30328-datasource-sync-next-steps.md,@object-ui/app-shell,@object-ui/i18nand@object-ui/plugin-formpatch.Branch: the harness-assigned
claude/project-thread-53q18n, notclaude/issue-30328-*; the card is #30328.Tests
DatasourceResourcePage.syncNextSteps-30328.test.tsx(new, 4 cases), under aMemoryRouterat/apps/setup/metadata/datasource; expectations are read from Studio's table, never retyped:Spare Parts (spare_parts)withhref/apps/setup/spare_parts, both steps are listed, no success toast, and clicking the link moves the router there;ObjectForm.fieldNameLabel-30328.test.tsx(new, 3 cases): the rule (part_no→Part no); the generated form drawsPart no/Unit priceand never the raw names;fromObjectSchemadrawsPart no; CONTROL: an authored label (Supplier) stays in both paths.Acceptance notes
studionamespace shipsenandzhonly, by the ruling recorded in its header (every other language falls back toen, no invented translations), so the four rows are en and zh like every otherengine.datasource.*row.新建Spare Parts(Console and CLI polish from the real-user walkthrough #30126 item 1), the object draft's labels and the synced object's package and export (Datasource table sync: the generated object draft gives its fields no label, so forms show raw column names; where the synced object lives (package, export) is unstated #30469). Seen on the live rig and routed by the seat to A read-only external object offers New and Import, then refuses with a permission message that blames the wrong thing #30334 item 1: on the new-record page of the synced external object, an administrator reads 「您没有创建Spare Parts的权限,字段均为只读。」.Verification
Gates and tests ran on
e93daf70(the gate runner started on8787d0b7;e93daf70, which only types the new plugin-form test's data source, landed while its first five families, the changeset and ADR-0087 checks, were running); the head adds an evidence commit and its removal, the tree is byte-identical (git diff e93daf70 HEADis empty). Basef273c9fe.Live rig and screenshots (zh-CN, 1440 wide)
examples/app-showcaseobjectstack dev --seed-admin --freshon a private port, the console viaviteinui/apps/consolewithDEV_PROXY_TARGET, Chromium, browser locale zh-CN. An external SQLite file with tablespare_parts(id,part_no,part_name,unit_price,in_stock, 3 rows), registered asPOST /api/v1/datasourcesparts_db(label 零件库,schemaMode: external), then synced through the dialog.Item ② measured on the base:
GET /api/v1/meta/object/spare_partsserved the business fields with no label ({"part_no":{"type":"text"},"part_name":{"type":"text"},...}); the list headers readPart name,Part no,Unit price,In stock; the new-record form labels readpart_no,part_name,unit_price,in_stock. After: the form readsPart no,Part name,Unit price,In stock.Before (page restored to the base for the shot): the dialog closes and the toast reads 「已从 parts_db 同步 1 个对象。」.
After: the dialog shows 「已从 parts_db 同步 1 个对象。」, the link
Spare Parts (spare_parts)(href/apps/com.objectstack.setup/spare_parts), and 「还剩两步,其他人才能使用它:」 with both steps. Clicking the link opened the object's list (3 records).Tests, ablation, typecheck, lint
pnpm --dir ui exec vitest run packages/plugin-form/src/ObjectForm.fieldNameLabel-30328.test.tsx packages/plugin-form/src/sectionFields.test.ts packages/app-shell/src/views/metadata-admin/datasource/ packages/i18n/src/__tests__/studio-namespace.test.tsone93daf70: Test Files 11 passed (11), Tests 104 passed (104), lock VERDICT command-exit 0.pnpm --dir ui exec vitest run packages/plugin-form/on8787d0b7(the only later change types the new test's data source): Test Files 223 passed (223), Tests 2452 passed, 1 skipped, lock VERDICT command-exit 0.scripts/ablation-replace.mjs, anchor x1 to x0):setSyncResultnever called: 3 failed / 1 passed (the none-created case still passes, as it should). Restored, blob equals HEAD,git diff HEADempty.fieldNameLabelreturns the raw name: 3 failed / 3. Restored, blob equals HEAD.pnpm --filter @object-ui/app-shell run type-check,pnpm --filter @object-ui/plugin-form run type-check,pnpm --filter @object-ui/i18n run type-check(eachtsc --noEmitandtsc -p tsconfig.test.json): exit 0.pnpm --dir ui run check:spec-symbols,check:i18n-keys,check:i18n-drift,check:unreferenced-sources,check:esm-specifiers,check:new-line-citations(0 new citations): exit 0.Derived gates (35/35 exit 0)
node scripts/pm/dispatch-gates.mjs --commands --repo objectstack-ai/objectstackderived 35 families; every one ran and exited 0.--ranreconciliation: 35 derived, 35 run, 0 NOT-MEASURED (a derived zero, every line carries an exit code).pnpm --dir ui exec vitest run scripts/: 170 files passed, 2 skipped; 4985 tests passed, 2 skipped. CI runs the rest.Generated by Claude Code
🤖 Generated with Claude Code
https://claude.ai/code/session_01L6bhgVaDMZ9FxV4kMaNFGU