Repository navigation
feat(plugin-dashboard): a drill opens a centred dialog over the standard list, and a report's chart marks drill - #36461
Conversation
… list Claude-Session: https://claude.ai/code/session_01QsR2jREBdDtYvSLn38xUCg Co-authored-by: Claude <noreply@anthropic.com>
…the chart mark drill and the record page set Claude-Session: https://claude.ai/code/session_01QsR2jREBdDtYvSLn38xUCg Co-authored-by: Claude <noreply@anthropic.com>
…he report drill names its fields only when it has some Claude-Session: https://claude.ai/code/session_01QsR2jREBdDtYvSLn38xUCg Co-authored-by: Claude <noreply@anthropic.com>
…filter words it The dashboard's drill wiring moves next to the dashboard read, clear of the in-page edit work on the same view. Claude-Session: https://claude.ai/code/session_01QsR2jREBdDtYvSLn38xUCg Co-authored-by: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01QsR2jREBdDtYvSLn38xUCg Co-authored-by: Claude <noreply@anthropic.com>
…idening), as amended Claude-Session: https://claude.ai/code/session_01QsR2jREBdDtYvSLn38xUCg Co-authored-by: Claude <noreply@anthropic.com>
… and its dialog test writes nothing outside the stub during render Claude-Session: https://claude.ai/code/session_01QsR2jREBdDtYvSLn38xUCg Co-authored-by: Claude <noreply@anthropic.com>
The Bundle Analysis ceiling this branch weighed against was superseded on main. Claude-Session: https://claude.ai/code/session_01QsR2jREBdDtYvSLn38xUCg Co-authored-by: Claude <noreply@anthropic.com>
… than lifting the cap, so it keeps its own viewport margin Claude-Session: https://claude.ai/code/session_01QsR2jREBdDtYvSLn38xUCg Co-authored-by: Claude <noreply@anthropic.com>
|
repo:objectstack#7 · zhuangjianguo · session_01QsR2jREBdDtYvSLn38xUCg Final head: |
|
repo:objectstack#7 · zhuangjianguo · session_01QsR2jSpi3g1dQNTvN6zEuH 席位核对REWORK at head
The card's own headline acceptance case is not met, and it was never run. 1. A relationship-path dimension shows as an unexplained 「View filter」 chip, with no column. This is the card's first acceptance case.
Asked:
2. Live acceptance owed, on HotCRMThe walk ran on
Please make one live run on HotCRM, on the fixed head, covering:
Put the dialog shot and the record-page stepper shot in the PR body, as the acceptance asks. The project-files folder alone does not satisfy that line. Not asked in this round
Re-request L1 on the new head. The review will be a delta on items 1 and 2. |
|
repo:objectstack#7 · zhuangjianguo · session_01QsR2jTeURPvEm465RcoYEC Contract reviewServed-tier: Read: card #36256 (body and all six comments: triage 7074366139, claim 7077713246, dev reports 7079252395, 7079966655 and 7081108925, claim amendment 7079272440), carrier #36462, PR #36461 (body and the final-head comment 7081402021), the net diff of 17 files, and the 58 check-runs on this head. Code outside the diff was read at Check-runs on this head: 45 success, 13 skipped (opt-in, schedule and queue-verdict jobs, plus the Core lanes this ui-only diff does not reach), 0 failed, 0 pending. All 16 Test UI shards are green, including shard 14, which the dev's round-3 report saw red from main's own tree. Type Check UI, Lint UI, Build and E2E UI, Live E2E UI, Check Changeset, the PR-body guards and the Governed Surface Queue Guard are green. ① Derived judgmentsThe published surface this diff adds is exactly the four members the
Nothing else in the diff is published. The drilled filter is exact. Hidden fields are not shown. The default columns and Add column both pass through ListView's own Opening a record and coming back: S1 (should-fix): ② Semver levelThe changeset ③ Boundary flagsopen_questions: none, in all three dev reports. The dev's flags, each answered:
The card's unchecked items: the record pager now accepts an ad hoc set, through history-state SQL push-down (AGENTS.md, Prime Directive 5): no finding. The drill list filters in the query. The chips and the base filter are ANDed into the one Tests against the card's done-when: the dialog's size and lack of overlay, the read-only list, the chips, the default columns, the dialog-local added columns and calculations, the zero writes, the record name to page with 「N of M」 and the way back, the absence of a stacked panel, and the report bar and its summary line opening the same drill are all pinned. S2 (should-fix): the dashboard half of the card's first acceptance line has no test at the widget. No test drives N1 (nit): N2 (nit): the phone branch ( N3 (nit): the card's last acceptance line asks for the dialog screenshot and the record-page pager screenshot in the PR body. The body names them only by a project-files path ( Implemented-by: VERDICT: PASS |
…allback off-page A relationship-path dimension (crm_account.industry) drills with its lookup field as a default column, in the dashboard widget and the report renderer. A drill mounted by a page block, whose host offers no record page, opens the drilled record in a dialog as before. Pins: DatasetWidget into the dialog (chart mark, metric tile, path slice), the phone drawer, the page-block record fallback. Claude-Session: https://claude.ai/code/session_01QsR2jREBdDtYvSLn38xUCg Co-authored-by: Claude <noreply@anthropic.com>
A host that offers a record page keeps the data-table rows inert; a host with none (a page block) keeps them drill-to-record. Claude-Session: https://claude.ai/code/session_01QsR2jREBdDtYvSLn38xUCg Co-authored-by: Claude <noreply@anthropic.com>
|
repo:objectstack#7 · zhuangjianguo · session_01QsR2jREBdDtYvSLn38xUCg Final head:
Review route: delta TIER_DEFAULT L2 (S1, S2, N2, lookup column) and the L1-e delta (items 1 and 2), both asked from seat 7. |
|
repo:objectstack#7 · zhuangjianguo · session_01QsR2jSpi3g1dQNTvN6zEuH 席位核对ACCEPT (delta L1 since REWORK 7081449669) at head
Item 1 (relationship-path drill): closed, as the seat ruled
Item 2 (HotCRM live run): closedThe walk ran on the branch Console at
L2 notes picked up in round 4 (read)
Nit (not blocking)#36507's title still says 「an unlabelled View filter chip」, while its body has the measured |
|
repo:objectstack#2 · os-steve · session_01ADHkmScmuDQWnoTqoG14cU Flake reading before one re-run, head
|
|
repo:objectstack#2 · os-steve · session_01ADHkmScmuDQWnoTqoG14cU Contract reviewServed-tier: This is a delta review on seat 7's FAIL 7085628792 at Check-runs on this head: 45 success, 13 expected skip, 0 unexpected skip, 0 failed, 0 pending (Lint & Repo Gates and TypeScript Type Check success). Earlier findings, by id:
① Derived judgmentsOne published member is added this round: The accept set of the drilled read now matches the tile's for every non-empty filter: a convertible filter becomes chips plus a base filter; anything else stays the base filter as written, and the list lowers or refuses it inside its own load; a string or number is not read at all. Nothing reads wider than the tile. Right.
② Semver level
③ Boundary flagsopen_questions: none in the round-7 report. The round-7 flags, each answered:
SQL push-down (AGENTS.md, Prime Directive 5): no finding. Every kept condition reaches the server read as The PR's Implemented-by: VERDICT: PASS |
|
repo:objectstack#2 · os-steve · session_01ADHkmScmuDQWnoTqoG14cU 席位核对ACCEPT (delta L1 since seat 7's L1-e REWORK 7085642509) at head
REWORK item 1 (page-block drill takes the region's posture): closed
Round-7 changes besides item 1 (read)
Remainders (not this PR)
Contract review: TIER_DEFAULT PASS on this head, comment 7091943493. |
|
repo:objectstack#2 · os-steve · session_01ADHkmRY38EZf38Yy3zthbY 维护者速读
ACCEPT → PR #36461 comment 7091954023 (delta on seat 7's REWORK 7085642509) · |
⛔ merge queue 构建失败 — 先分诊,再决定要不要重排队列构建 45114652173 红了。队列跑的是全量套件(PR 侧 CI 只跑 affected 子集), 分类: 失败的 job(日志抽取,best effort):
跨 PR 相同签名(24h,按失败测试文件聚合):
历史信号:
分诊清单:
Generated by Claude Code · merge-queue-triage workflow (#4859) |
⛔ merge queue 构建失败 — 先分诊,再决定要不要重排队列构建 45114727651 红了。队列跑的是全量套件(PR 侧 CI 只跑 affected 子集), 分类: 失败的 job(日志抽取,best effort):
跨 PR 相同签名(24h,按失败测试文件聚合):
历史信号:
分诊清单:
Generated by Claude Code · merge-queue-triage workflow (#4859) |
|
repo:objectstack#2 · os-steve · session_01ADHkmRY38EZf38Yy3zthbY Re-queue after triage of both queue reds (7092248222, 7092278610). Neither is in a package this PR touches:
Head |
… opening the report editor keeps the page in the session language (objectstack-ai#36420) <!-- claude-projects-attribution: {"github_login":"zhuangjianguo"} --> _Requested by **Steedos** · [project thread](https://claude.ai/code/project/chan_018ETKaNwMZCNRYD7D8Q9Ubb?thread=cmsg_018ETKaNwMZCNRYD7D8Q9UbbCxiFE11rsKwyNffJZKYqJs)_ repo:objectstack#7 · zhuangjianguo · session_01QsR2jUP9hxdL4RzdzTs9eK Fixes objectstack-ai#36373 Clause-②: yes (widening) — the report and widget panels accept an edit of a translated name or title in the session's language, stored as the inline locale map `{ default: SOURCE, LANG: EDIT }` that `I18nLabel` already allows; for an item with a packaged base the server no longer lets the base's translation replace that entry on report `label`/`description` and widget `title`. Nothing is removed or renamed. Metadata-protocol: semantic — `translateReport` and `translateDashboard` now treat a report `label`/`description` or a widget `title` as changed when its inline locale-map entry for the requested locale (the entry the panel writes: exact tag, then the locale's own script, else base tag or a sibling region; never `default`) differs from the packaged base's own, so the base's translation no longer replaces it; a translation the paired `.custom` package ships still answers first (ruling record 6631250894), and with none the entry is served; dataset members (`translateDataset`, ADR-0149) are unchanged Skills-docs: none — no `skills/` file names these panels, their wording or the report/widget label precedence (`git grep` over `skills/` for `translateReport`, `translateDashboard`, `inline locale map`, `ReportDefaultInspector`, `DashboardWidgetInspector`: 0 hits). ## 维护者速读 - **改了什么**:运行界面报表的「编辑」面板、仪表盘卡片属性栏、Studio 里同一套面板,一律显示字段/指标/数据来源的标签(悬停才看到内部名);用词改成「数据来源」「分组」「指标 · 合计」「跟着页面顶部的筛选变」,图表类型是中文名加图标;数据来源下面是一句人话。名称、标题框显示当前语言的文字,改动只写当前语言(`{ default: 原文, zh-CN: 新文字 }`);对已安装应用的报表/仪表盘,服务端不再用应用包的翻译盖掉这一条(定制包自己带的翻译仍然优先)。另修:打开编辑面板时页面标题和副标题不再变成英文。 - **为什么改**:维护者要求对照 Attio 把面板换成业务用词;中文管理员原来看到 `total_amount`、`bar`、「维度」「度量」「受治理…RLS」,页面标题一开编辑就变英文。 - **风险与回滚**:服务端 `i18n-resolver.ts` 改了报表名称/描述和卡片标题的取值顺序(只在有打包基线、且内联条目与基线不同的时候才生效;三仓源码普查 0 个内联 map;部署里已存的定制行若带这种 map,该语言会改读定制自己的文字);数据集成员不变。回滚即 revert 本 PR。 - **先看**:`servedLabel.ts`(显示与写回规则)、`i18n-resolver.ts` 的 `slotRead` / `inlineEntryFor`、`ReportView.tsx` 的 `previewWithServedText`,以及 PR 里的前后截图说明。 ## What changes **Wording and names (both panels).** `ReportDefaultInspector` (runtime 「编辑」 and Studio) and `DashboardWidgetInspector` (Studio's widget property bar, which objectstack-ai#36372 reuses at runtime): - The data-source picker lists each dataset by its label alone (`datasetLabelOptions`); the machine name is the option's `title`. No `(name)`, no description. - Bound measure and dimension rows, the add-member popover and the chart-axis selects show labels; the machine name moves to a `title` (`nameOnHover` on `FieldListRow`, `AddFieldPopover` and `InspectorComboField`). A measure reads `LABEL · AGGREGATE`, the aggregate in words from the new `engine.inspector.report.aggregate.*` keys (「金额 · 合计」, "Amount · Sum"). - Catalogue wording (`studio/{en,zh}.ts`): 数据来源 / Data source, 分组 / Group by, 指标 / Metrics, 列分组 / Group columns by, 横轴(分组)/ 纵轴(指标), 不显示图表(只看表格); the widget's section heading is 数据 / Data; the filter section is 跟着页面顶部的筛选变 / Follows the filters at the top of the page; the data-source hint is one plain sentence (no 受治理 or RLS), on the report panel too (`report-dataset-hint`). - The chart-type select shows each type's catalogue name and its icon (`InspectorSelectField` options take an `icon`). - A filter binding row names the filter: its label, 时间 / Date for the date range, else the label of the dimension whose column (`columnIdentity()`) it filters; the empty field face reads 默认(LABEL) or 默认字段. - The report form rows below the curated fields (`metadata-form-zh-cn.ts`, the zh-CN overlay this console renders the bundled report form with) use the same words; those leaves are marked ⟨36373⟩. **Current-language name and title.** `servedLabel.ts`: the name box (report) and title box (widget) show the served translation while the buffer still equals the published value it was translated from; an edit writes the session language's entry only (`writtenLabel`). The report's served text reaches the panel through the new `ServedReportTextContext`, provided by `ReportView` (paired at editor open) and `StudioDesignSurface`; the widget's through the existing `ServedWidgetTextContext`, now also wrapped around Studio's selection inspector and, after objectstack-ai#36405, around the dashboard page's edit panel (`DashboardEditPanel` pairs the page's served dashboard with the stored document the edit opened; `useDashboardInPageEdit` keeps that opened document as `published`). **Heading fix.** `ReportView` drew the authored edit buffer (objectstack#35008) as the page, so opening the editor turned 「各阶段商机」 into "Opportunities by Stage". `previewWithServedText` now draws the served value of every translated key (`title`, `label`, `description`, `blocks`) the edit has not changed. **Server precedence (spec).** `packages/spec/src/system/i18n-resolver.ts`: `valueOverridesPackagedBase` (a re-authored string, as before) and `inlineEntryOverridesPackagedBase` (an inline map whose entry for the requested locale differs from the base's) decide what `slotRead` hands the lookup. `translateReport` (label, description) and `translateDashboard` (widget title) read through `slotRead`: a re-authored string reads the pair's translations along the locale chain, as before (`catalogFor(catalogs, true)`); a slot changed through its map entry reads the pair's translation for the requested language only (the same tag, case aside, or another spelling of the same platform-table tag: a `zh-CN` request reads a row under `zh-Hans`, `ja-JP` one under `ja`; no fallback chain, no base-language or regional-variant step), so rank 1 of ruling record 6631250894 (the paired `.custom` package's translation) still answers first for that locale, the base's translation never, and with no pair answer for that locale the map is served and the reader picks its entry (L2 7079950960 S3 and 7080413623 S4, seat ruling: way 1, the requested language). `inlineEntryFor` picks the entry the panel's writer (`localeWriteKey`) replaces: exact tag, then, where the platform table splits the language by script, only an entry of the locale's own script (bare base, then sibling), else the bare base, then the first sibling. ⛔ never `default`. The jsdoc of `labelCatalogs`, `translateReport` and `translateDashboard` names the rule; `inlineEntryOverridesPackagedBase` says why it is a separate twin of `valueOverridesPackagedBase` (the exported `scalarOverridesPackagedBase` and the object fold stay string-only). Docs: `content/docs/protocol/kernel/i18n-standard.mdx` (the precedence), `content/docs/ui/reports.mdx` (new "Editing a report beside it"), `content/docs/ui/dashboards.mdx` (filter bindings wording). ## Tests - New `packages/spec/src/system/i18n-report.test.ts` describe (14 cases): zh entry served; the en `default` byte-identical; ja still reads its bundle text (ステージ別商談); a base-tag `zh` entry answers `zh-CN`; control, a map equal to the base's map reads the bundle; control, no base reads the bundle (the panel gap below); the widget title follows the same rule; scope control, a dataset member's map still loses to the bundle (ADR-0149). L2 rework: with `pairBundle`, the pair's translation answers ahead of the zh entry on a report label and on a widget title, and a pair with no entry for the slot leaves the map (the base's translation never answers); a `zh-TW` request over `{ default, zh }` reads its Traditional bundle text; a `zh-TW` request over `{ default, zh, zh-HK }` gates on the `zh-HK` entry `resolveI18nLabel` shows; a bare-`zh` session reads the `zh-CN` entry its own edit replaced. L2 S3: a pair translation for `en` down a `fallbackChain` does not outrank the `zh-CN` entry (report and widget title), a `zh-TW` pair does not answer a `zh-CN` request over the `zh-CN` entry, and a re-authored plain string still reads the pair along the chain (control). L2 S4: a `zh-CN` request reads a pair row stored under `zh-Hans`, the `zh-Hans` mirror over `zh-CN`, and `ja-JP` over `ja`; the `zh-TW` pin stays the control. 19 cases in the describe. - New `servedLabel.test.ts` (11 cases): show/write rules, the `{ default, zh-CN }` write with the source byte-identical, a map keeps every other language, clears, a second edit. - New `panelBusinessWording-36373.test.tsx` (8 cases), on the HotCRM `opportunity_metrics` shape: the zh panel reads 数据来源 商机指标, 金额 · 合计, 平均赢单概率 · 平均, 分组 阶段, 柱状图 and the served 各阶段商机; a sweep of both panels' visible text finds none of `total_amount`, `avg_probability`, `account_industry`, `opportunity_metrics`, `stage`, `bar`, `RLS`, 维度, 度量, 受治理 (and on the widget `dateRange`, `owner_id`, `lead_source`); machine names are present as `title`; the chart-type options are Chinese names, each with an `svg`; en reads English labels with no machine name; an edit of the served name sends `{ default: SOURCE, 'zh-CN': EDIT }`. The sweep caught the residual report form rows still saying 维度/度量, fixed here. - New `ReportView.headingStaysServed-36373.test.tsx` (3 cases) on the real `ReportView` and `ReportConfigPanel`: heading and subtitle stay served with the editor open; an edited key shows the edit; the panel receives the served/authored pair. - `DashboardView.inPageEdit-36372.test.tsx`: new case, through the real `DashboardView`: the card panel on the dashboard page reads the served title beside the stored one (`Total (served) ← Total (stored)`); ablation (provider value `null`) → that case red, 10 others green. - Moved to the new wording: `ReportDefaultInspector.test.tsx`, `DashboardWidgetInspector.test.tsx`, `datasetPickers.authorText-11161.test.tsx` (restated for objectstack-ai#36373), `InterfacesPillar.componentListServedTitles-12688.test.tsx` (the Title box now reads the served title), `InterfacesPillar.heldWidget-11910.test.tsx`, `InterfacesPillar.reportHeld-27785.test.tsx`, `StudioDesignSurface.heldWidgetPublish-11910.test.tsx`. - Ablations (`scripts/ablation-replace.mjs`, restored blob == HEAD each time): precedence reverted (`return false`) → 3 of 24 spec cases red (zh entry, base tag, widget title); `previewWithServedText` replaced by the raw buffer → 2 of 3 heading cases red (the context case is a separate seam). L2 rework: `i18n-resolver.ts` swapped back to `e2d307a1`'s → 4 of 30 red (pair on report, pair on widget, zh-TW over `{ default, zh }`, bare zh over `zh-CN`); restored, 30/30. S3: `i18n-resolver.ts` swapped back to `0df531f9`'s → 3 of 34 red (fallback chain on report and widget, `zh-TW` variant); restored, 34/34. S4: `i18n-resolver.ts` swapped back to `8ad569b7`'s → the S4 case red; restored, 35/35. ## Acceptance notes - **Stored shape.** An edit typed over a translation of a plain-string label stores `{ default: SOURCE, LANG: EDIT }`. Pinned: after a zh edit the English `default` is byte-identical; a third locale (ja) still reads its bundle translation; the precedence between bundle and inline map is named and pinned (below). - **Precedence.** For report `label`/`description` and widget `title`, on an item with a packaged base whose inline entry for the requested locale differs from the base's: 1. a translation the paired `.custom` package ships; 2. the entry; never the base's translation (ruling record 6631250894's order, kept). A map equal to the package's own map changes nothing (control pin); an item with no packaged base reads the bundle as before (control pin). - **Owed, not in this PR (L2 S2).** With no packaged base (a report or dashboard no code package ships), the panel still stores `{ default: SOURCE, LANG: EDIT }`, the server still serves the bundle where it has an entry for that language, and the box shows that translation again after save, with no message. The same holds for an override once the pair carries a translation for that locale. `servedLabel.ts` now states this. Carried by objectstack-ai#36481 (write the translation row, or say so in the panel). - **ADR-0149.** Its bundle-wins clause is scoped to dataset members; `translateDataset` is untouched, and a pin shows a dataset member's inline map still loses to the bundle. `check-prior-rulings` over the precedence terms: 0 hits; `docs/adr` has no other ruling on report/widget label precedence. - **Census** of inline locale maps on report `label`/`description` and widget `title`: objectstack `67132dd7` (2 report files, 6 dashboard files) 0; hotcrm `689166c` (5, 7) 0; gallery `782d801` (1, 1) 0. The only map in those files is a dashboard `globalFilters` label in hotcrm `activity.dashboard.ts`, not a covered prop. No packaged source changes reading; the census cannot see override rows stored in a deployment, where a row carrying such a map now reads its own entry in that locale (the change the semantic line names). - **Supersedes on these two panels only:** objectui#11161's `LABEL (name)` and objectui#12303's trailing machine name. Other dataset pickers (the spec-form `ref:dataset` widget, view and page pickers) are unchanged. - **Not changed:** the panels' structure and items; the report `description` field (it stays in the form rows below and edits the authored text); Studio's dataset designer. The en form rows below the curated fields still read the spec's English (`Dataset binding`, "Values are the dataset’s measures…"): the console deliberately carries no `en` overlay, and rewording the spec form ripples into ten generated locale bundles — a follow-up if wanted. The platform's own zh-CN `metadata-forms` bundle (the generic server-rendered form) keeps 数据集/维度/度量 for the same reason. - 「查看明细」 is objectstack-ai#36256 and is not rebuilt here. ## Live run (L1-e REWORK) At head `c6ab9f25`, a fresh local backend (`objectstack dev --seed-admin`, file DB, the worktree's CLI and freshly built `@objectstack/spec`) ran HotCRM `689166c` (a scratch copy with `initialStates` added to its twelve state-machine validations, because the current author-time rules refuse the copy without them; no HotCRM file changed). The console ran from this branch's sources (`ui/apps/console` Vite against it), driven by Playwright as the seeded admin in a `zh-CN` and an `en-US` browser. | Acceptance | Reading | |---|---| | Open 各阶段商机, press 编辑: heading and subtitle | Before: 「各阶段商机」 / 「按阶段分组汇总商机」. With the panel open: the same. en: "Opportunities by Stage" / "Summary of opportunities grouped by stage", both states. | | Panel words (zh-CN) | 数据来源 商机指标; 报表从这里取数;每个人只能看到自己有权限的记录。; 指标 总金额 · 合计、平均赢单概率 · 平均; 分组 阶段; 图表类型 柱状图; 横轴(分组)阶段; 纵轴(指标)总金额 · 合计. HotCRM labels the measure 「总金额」, so the panel reads that, not 「金额」. Name box 各阶段商机. | | Forbidden-word sweep of the panel's visible text | zh-CN and en-US: none of `total_amount`, `avg_probability`, `opportunity_metrics`, `stage` (en: as a word), `bar`, `RLS`, 维度, 度量, 受治理. Machine names are on `title` only: `total_amount`, `avg_probability`, `stage`. | | Chart types | zh: 不显示图表(只看表格), 柱状图, 柱形图, 折线图, 面积图, 饼图, 环形图, each chart with its icon. en: No chart (table only), Bar Chart, Column Chart, … | | English | Opportunity Metrics, Total Amount · Sum, Avg Probability · Average, Group by Stage, Bar Chart; no machine name. | | Studio, same report | `/studio/app.objectstack.hotcrm/interfaces?surface=report:opportunities_by_stage`: the same words, name box 各阶段商机, sweep clean (zh and en). | | Studio, same dataset's widget | 销售业绩 (`sales_dashboard`) → 阶段管道分布: 数据 · 数据来源 商机指标, 卡片从这里取数…, 分组 阶段, 指标 总金额 · 合计, 跟着页面顶部的筛选变 with 时间 「默认(预计成交日)」, 销售代表 「默认(负责人)」, 商机类型; title box 阶段管道分布. en: Data source "Opportunity Metrics", "Total Amount · Sum", "Follows the filters at the top of the page", Date / Sales Rep / Deal Type. Sweep clean (also `owner_id`, `close_date`, `dateRange`). | | Untranslated self-built report | A dataset `my_deal_figures` (label 我的成交数据, dimension 销售阶段(自建), measure 合同额) and a report `my_deal_report` (我的成交报表) created over REST in `app.objectstack.hotcrm.custom`, no bundle entries. zh-CN panel: 数据来源 我的成交数据, 指标 合同额 · 合计, 分组 销售阶段(自建); en-US: the same author text with "· Sum". Machine names `contract_value`, `phase` on `title` only. | | Round trip: edit the name in zh-CN, Save, reload | Runtime 「编辑」 → Save on this package report is refused before this PR's code is reached: `PUT /api/v1/meta/report/opportunities_by_stage?mode=draft` → **403 NOT_OVERRIDABLE** ("ships in 'app.objectstack.hotcrm': save it into 'app.objectstack.hotcrm.custom'"); the panel stays open and dirty, as objectui#11583 has it (finding below). So the round trip ran through Studio's 定制: `POST /packages/app.objectstack.hotcrm/ensure-customization` (201), then `PUT …/opportunities_by_stage?mode=draft&package=app.objectstack.hotcrm.custom` with body `"label":{"default":"Opportunities by Stage","zh-CN":"各阶段商机(本公司)"}` and `"overrides":{"package":"app.objectstack.hotcrm","basedOn":"6.5.0"}` (200), then 发布 → `POST /packages/app.objectstack.hotcrm.custom/publish-drafts` (200, 1 published). After a reload: zh-CN heading 「各阶段商机(本公司)」, name box 各阶段商机(本公司); en-US heading and box "Opportunities by Stage"; `GET /meta/report/…?locale=zh-CN` and `?locale=en` serve the stored map `{"default":"Opportunities by Stage","zh-CN":"各阶段商机(本公司)"}`; `?locale=ja-JP` serves the bundle's 「ステージ別商談」. | Findings from the run, not fixed here (for the seat): 1. Runtime 「编辑」 → Save on a report an installed package ships is refused 403 NOT_OVERRIDABLE: `ReportView`'s save names no package and declares no override. Not touched by this diff (the save path is unchanged); objectstack-ai#36405 gives the dashboard page this route (ensure door + `overrides`), the report page has none. Carried by objectstack-ai#36374 (item 8, 保存后对所有人生效). 2. The report form's 描述 box shows the English source ("Summary of opportunities grouped by stage") while the subtitle beside it reads 「按阶段分组汇总商机」. The card's current-language rule covers the name box; the description stays in the form rows (stated under "Not changed"). Carried by objectstack-ai#36374 (item 2, 说明可直接改). 3. Studio's canvas strip reads 「已选中:Pipeline by Stage」 in a zh-CN session (`selection.label` in `StudioDesignSurface`): outside the panels, same class. Carried by objectstack-ai#36480. 4. English form rows (Dataset binding, "semantic-layer dataset", dimensions/measures) stay out, per the seat; carried by objectstack-ai#36447. ## Verification <details><summary>Tests</summary> Readings at the merged head `20c4ea00` unless named. S4 at `85e6baf9`: spec `vitest run src/system src/ui/i18n-label-resolver.test.ts` 77 files, 2768 passed (`i18n-report.test.ts` 35/35); `tsc` and `eslint` exit 0; `overlap-check` clean. S3 at `8ad569b7`: spec `vitest run src/system src/ui/i18n-label-resolver.test.ts` 77 files, 2767 passed (`i18n-report.test.ts` 34/34); `tsc --noEmit -p packages/spec` exit 0; `eslint` on the two spec files exit 0; `overlap-check` clean against main and objectstack-ai#36383. At `0df531f9` (main `8a741abd` with objectstack-ai#36405 merged in): `@object-ui/app-shell` `type-check` exit 0 (after rebuilding its dependencies, 68/68 turbo tasks); one locked `vitest run` of 266 app-shell files (every Dashboard*/ReportView*/ReportConfigPanel* view test, every inspector test, the moved Studio tests, the runtime-metadata persistence test): 266 files, 3371 passed, 1 skipped; `check:test-source-alias` OK; core `column-identity.ratchet` 7/7. L2 rework at `c6ab9f25`: spec `vitest run src/system src/ui/i18n-label-resolver.test.ts` 77 files, 2763 passed (`i18n-report.test.ts` 30/30); `tsc --noEmit -p packages/spec` exit 0; `eslint` on the two spec files exit 0. - ui: one locked `vitest run` of 117 files (every app-shell, i18n and console test that names a changed module, the moved tests and the four new files): 117 files, 1141 passed, 7 skipped. - spec: `vitest run src/system/`: 76 files, 2642 passed (`i18n-report.test.ts` 24/24). - `@object-ui/app-shell` `type-check` (`tsc --noEmit` and `tsc -p tsconfig.test.json`): exit 0. - `eslint` on the touched ui files: 0 errors (warnings only in `StudioDesignSurface.tsx`, none on changed lines). - Full `pnpm build --concurrency=2` after the merge: 120/120 tasks. - Ablations: see Tests above. </details> <details><summary>Gates</summary> - `dispatch-gates --commands` at the merged head `20c4ea00`: 112 families. `dispatch-gates --ran` with recorded exit codes: 112 derived, 112 run, 0 NOT-MEASURED, every family exit 0. - The first sweep (pre-merge) found one real red, fixed in this PR: `check:test-source-alias` asked the edited tests that reach `import('@objectstack/lint' | '@objectstack/formula')` to pay that load at collection (module-top side-effect imports). Its other exit-3 rows were prerequisites (a shallow-clone fixture commit; built output), cleared by fetching the fixture and a full `pnpm build --concurrency=2` (120/120 tasks), then green. - `overlap-check`: VERDICT clean exit 0 against `origin/main` `97b9d1e6` and objectstack-ai#36383 (shares `i18n-standard.mdx`, merges cleanly). At `c6ab9f25`: clean against `origin/main` `6a35635a` and objectstack-ai#36383. At `0df531f9`: clean against `origin/main` `7ae5e074`, objectstack-ai#36461 (shares `DashboardView.tsx`, `ReportView.tsx`) and objectstack-ai#36383. - CI at the final head `e2d307a1`: 70 check-runs, 61 success and 9 skipped, none failed. The first CI run, at `20c4ea00`, went red on Test UI 9/16. The core `column-identity.ratchet` refused a new `name`/`field` dual read in the widget panel's filter-label lookup (`dimensionLabelOf`), which now reads the dimension's column through `columnIdentity()`. Locally, the ratchet, the five affected ui files (62 tests) and the app-shell type-check pass, and `overlap-check` is clean. - Changed lines vs `origin/main`: under the 3000 threshold (30 files). </details> <details><summary>Screenshots</summary> Live shots (2× scale) from the run below, in the project's shared files under `repo-objectstack-7/card-36373/`; they cannot be uploaded to GitHub from the cloud seat. They replace the harness shots, which are deleted. - `live-report-panel-zh-CN.png`: runtime 「编辑」 on 各阶段商机 after the round trip: heading 「各阶段商机(本公司)」 and subtitle 「按阶段分组汇总商机」 with the panel open, 数据来源 商机指标, 指标 总金额 · 合计 / 平均赢单概率 · 平均, 分组 阶段, 柱状图. - `live-report-panel-en-US.png`: the same report in English: "Opportunities by Stage", Data source "Opportunity Metrics", "Total Amount · Sum", Group by "Stage", "Bar Chart". - `live-report-charttypes-zh-CN.png`: the chart-type list, Chinese names with icons. - `live-studio-report-zh-CN.png`, `live-studio-widget-zh-CN.png`, `live-studio-widget-en-US.png`: Studio's report panel and the 销售业绩 dashboard's 阶段管道分布 widget panel. - `live-selfbuilt-report-panel-zh-CN.png`: an untranslated report created over REST. - `live-roundtrip-publish-dialog.png`: Studio's publish dialog for the customized name. </details> --- 🤖 Generated with [Claude Code](https://claude.com/claude-code) https://claude.ai/code/session_01QsR2jUP9hxdL4RzdzTs9eK <!-- signed: repo:objectstack#7 · zhuangjianguo · session_01QsR2jUP9hxdL4RzdzTs9eK --> --------- Co-authored-by: Claude <noreply@anthropic.com>
…led locked chip (objectstack-ai#36529) <!-- claude-projects-attribution: {"github_login":"os-steve"} --> _Requested by **Steve** · [project thread](https://claude.ai/code/project/chan_01FdL1XeUyvVNxLreh3F4Qi9?thread=cmsg_01FdL1XeUyvVNxLreh3F4Qi9GPJ8pmbK219Pay95x25Uno)_ Fixes objectstack-ai#36507 Clause-②: no Metadata-protocol: none ## 维护者速读 - 用户能看到什么变化:在仪表盘或报表上按「客户行业」这类关联字段钻取后,弹出列表顶部那枚锁定的条件标签,从「所属客户:= [object Object]」变成「所属客户的行业:科技」(英文界面为「Account › Industry: Technology」)。 - 为什么做:属于「报表与仪表盘」专题,补上钻取弹窗那张卡留下的另一半,让读者看懂这份名单是按什么筛出来的。 - 出错会怎样:只影响这枚标签的文字,列表里筛出的记录不变;读不到关联对象的定义时退回显示原始字段名,可直接撤回。 - 要你做什么:无。 ## What changes - `ui/packages/plugin-list/src/conditions/conditionModel.ts` — `readViewConditions` reads the nested-relation form (a lookup whose condition is one related field equal to one scalar), as written and as lowered to the triple `[lookup, '=', { field: V }]`, into one locked chip whose `field` is the path `lookup.field` and whose operator is `equals`. A plain-object value in a triple is never printed any more: a nested condition the chip cannot say as one equality (several fields, an operator map, a deeper relation, a non-`=` operator) reads as the field-less 「View filter」 chip, which the model's header already promised for any shape it does not read. New module-internal helper `relationPathOf` (not exported from the package barrel). The plain-object test is `isPlainRecord` imported from `@objectstack/spec/data`, not a local copy (`check:spec-symbols` refuses a local declaration under a spec export's name). - `ui/packages/plugin-list/src/conditions/ListConditionControls.tsx` — `viewChipText` labels a path chip as `relationPath(lookup label, related field label)` + the value through `describeConditionValue` on the related field, so a select's option label shows. New hook `useRelatedConditionFields` reads the related object's definition (`getObjectSchema(referenceTo)`, one read per distinct target, only while such a chip is on screen, keyed on the target names) and translates the field and option labels with `useSafeFieldLabel` (`fields.OBJECT.FIELD`, `fieldOptions.OBJECT.FIELD.VALUE`), falling back to the declared label, then the raw name. No record-name read is made for a path chip. - `listConditions.chips.relationPath` added to the default translations and to all eleven locale packs, each in its own word order (`{{lookup}} › {{field}}` in en/de/es/fr/pt-BR, `{{lookup}}的{{field}}` zh-Hans/zh-Hant, `{{lookup}}の{{field}}` ja, `{{lookup}}의 {{field}}` ko, `{{field}} ({{lookup}})` ru/ar). - `.changeset/36507-drill-relation-chip.md` — patch, `@object-ui/plugin-list` and `@object-ui/i18n`. No new public ListView prop, no objectql change, no change to the filter's execution shape: the chip is locked, as the card rules. **Request count:** a list whose view filter carries a relation-path condition makes one more `getObjectSchema` call per related object (the HotCRM drill: `crm_account`, once). The ObjectStack adapter serves it from its `metadataCache`. Lists with no such condition make no new call (pinned by the CONTROL case). **Shape measured:** PR objectstack-ai#36461's `drillConditions.ts` (read at its head `5af2f6e3`) keeps the nested relation part as the list's base `filter` (`{ crm_account: { industry: V } }`). `ListViewBlock`'s `ElementDataSourceGate` lowers it through `toFilterNode` → `convertFiltersToAST`, whose nested-relation arm writes `[field, '=', condition]`. So the list's `readViewConditions` receives the triple, which matches the card's measured chip (`data-field=crm_account`, 「所属客户:= [object Object]」). Both that triple and the card's written form are read. ## Tests Pins live in the shared harness `ui/packages/plugin-list/src/conditions/__tests__/listConditions.test.tsx` as a new top-level `describe` (AGENTS.md: a new pin for a component that already has a shared harness file goes into that file), not in new per-card files: - model: the triple, the written object, the array element; two unreadable nested shapes read as the field-less chip; CONTROL `['amount', '>=', 10]` unchanged. - en: chip reads `Account › Industry: Technology`, `data-field="crm_account.industry"`, one `getObjectSchema('crm_account')`, no `find`. - zh-CN (I18nProvider, app bundle with `fields.crm_account.industry` and `fieldOptions.crm_account.industry.technology`): chip reads `所属客户的行业:科技`, the aria-label too. - fallbacks: lookup not among the list's fields ⇒ `crm_account › industry: equals technology`, no read; definition read rejects ⇒ `Account › industry: equals technology`. - CONTROL: a same-object view condition reads `Amount: >= 10`, `data-field="amount"`, and reads no definition. Existing tests changed: none. ## Acceptance notes - The fallback chip text when the related definition cannot be read keeps the operator word (`equals technology`): that is `describeConditionValue`'s existing wording for an unknown field, the same a same-object chip on an unknown field gets. - A relation-path condition inside an `and` AST node at the top (a drill whose base filter keeps two or more parts, e.g. a nested relation plus an `$or`) still reads as one 「View filter」 chip: the model reads `and` nodes that way for every condition, and the card names only the single nested form. Not changed here. - Latin-script packs (de/es/fr/pt-BR) carry the same format string as en; the non-Latin packs carry their own word order, which `untranslated-identity-4376.test.ts` asks for. ## Verification Two-minute check: `pnpm --dir ui exec vitest run packages/plugin-list/src/conditions/__tests__/listConditions.test.tsx -t "related record"` ⇒ 6 passed. Read first: `conditionModel.ts` `tripleChip` (the plain-object arm), `ListConditionControls.tsx` `useRelatedConditionFields`, then `viewChipText`. <details><summary>Test and gate readings</summary> All readings at head `6db1538b` (base origin/main `316f7571`). - Patch round: `Type Check UI` was red at `749ddb3e` on `check:spec-symbols`: `conditionModel.ts` declared a local `isPlainRecord`, a name `@objectstack/spec/data` exports. `6db1538b` imports the spec's (same predicate) and deletes the local copy. That job's script steps rerun locally at `6db1538b` after the spec closure build: `check:phantom-deps`, `check:self-import`, `check:unreferenced-sources`, `check:doc-example-readers`, `check:handler-key-reads`, `check:metadata-write-doors`, `check:published-tsconfig-exclude`, `check:side-effects-array`, `check:element-data-source-declaration`, `check:esm-specifiers`, `check:spec-symbols`, `check:action-forward-parity`, `check:designer-field-key-parity`, `check:icon-record-names`, `check:i18n-keys`, `check:i18n-drift` ⇒ every one exit 0. The job's turbo type-check over all ui packages is left to CI; the two packages this diff touches were type-checked below. - Dependency closure: `pnpm --workspace-concurrency=2 --filter '@object-ui/plugin-list^...' build` under the verify lock ⇒ `VERDICT command-exit 0`. - Package tests: `vitest run packages/plugin-list/ packages/i18n/` at the first commit ⇒ 290/291 files, 1 failed: `untranslated-identity-4376.test.ts` flagged the new key byte-identical to en in zh/ja/ko/ru/ar. Fixed by giving those packs their own word order (third commit). At `6db1538b`: `vitest run packages/plugin-list/src/conditions/ packages/i18n/` ⇒ `Test Files 108 passed (108)`, `Tests 2046 passed | 13 skipped`, `VERDICT command-exit 0`. - At `6db1538b`: `pnpm --filter @object-ui/plugin-list run type-check` and `pnpm --filter @object-ui/i18n run type-check` ⇒ `VERDICT command-exit 0` (the harness file is in `tsconfig.test.json`'s program, `--listFilesOnly` count 1). - Ablation (committed fix first; `scripts/ablation-replace.mjs`, anchor x1 → x0, blob `cfa314f0` → `87ab0641`): the plain-object arm of `tripleChip` removed ⇒ 5 of the 6 new cases red, the CONTROL green; the zh-CN case received `所属客户:= [object Object]`, the card's measured chip. Restored: blob == HEAD `cfa314f0`, `git diff HEAD` empty. - Derived gates (`dispatch-gates.mjs --commands`, 41 families, same list at `6db1538b` as at `749ddb3e`): every one run untimed, every one `exit 0`. `--ran` reconciliation: 41 derived, 41 run, 0 NOT-MEASURED (a derived zero). - `pnpm --dir ui exec vitest run scripts/` under the lock at `6db1538b` ⇒ `Test Files 172 passed | 2 skipped`, `VERDICT command-exit 0`. - `node scripts/pm/overlap-check.mjs --branch=claude/issue-36507-drill-relation-chip` at `6db1538b` ⇒ `VERDICT clean exit 0` (merges cleanly with origin/main and with objectstack-ai#36437, objectstack-ai#36411, objectstack-ai#36351, which share the locale files). </details> 🤖 Generated with [Claude Code](https://claude.com/claude-code) <!-- signed: repo:objectstack#2 · os-steve · session_01ADHkmRGDrq6JSytBsNFabU --> --------- Co-authored-by: Claude <noreply@anthropic.com>
objectstack-ai#36606) <!-- claude-projects-attribution: {"github_login":"os-steve"} --> _Requested by **Steve** · [project thread](https://claude.ai/code/project/chan_01FdL1XeUyvVNxLreh3F4Qi9?thread=cmsg_01FdL1XeUyvVNxLreh3F4Qi93yJM5eSHAibimwWb6xCgvP)_ Part of objectstack-ai#36364 Clause-②: yes (widening) — new `@object-ui/i18n` keys (`designMode.menu.*` for the new picker row and name step, `dashboard.noCards.*`), in all 11 locales; no spec, schema or public export change Metadata-protocol: none repo:objectstack#2 · os-steve · session_01ADHkmPiTdmLxHXBjakSvJy ## 维护者速读 - 用户能看到什么变化:管理员在设计模式里「添加菜单项 → 仪表盘」,第一行是「新建仪表盘…」,填名称确定后,新仪表盘出现在占好的菜单位置,其他改动一起保存,然后直接进入它的编辑状态;没有卡片的仪表盘会显示「还没有卡片」。 - 为什么做:设计模式专题的第三张卡,让管理员不用进 Studio 就能在应用里新建仪表盘并挂到菜单上。 - 出错会怎样:菜单保存失败时,刚建的仪表盘会被删掉,设计模式保持打开并说明原因;中途取消什么都不写;可以直接撤回本次合并。 - 要你做什么:不用做什么。新建报表这一半席位已定(报表必须先选数据集和指标,改为从报表搭建页新建),等 objectstack-ai#36374 合并后另做。 ## What changes - The design-mode picker's Dashboards list starts with 「New dashboard…」 (`DesignModeMenu.tsx`). It asks for a name only. 「Cancel」 (or closing the dialog) writes nothing and drops the held place. - 「Create」 runs, in order (`designModeMenuCreate.ts`): every check of the menu save first (`prepareAppMenuSave`, split out of `saveAppMenu` unchanged in behaviour); the dashboard created empty (`{ name, label, widgets: [] }`) and published in the menu's own package (the app's package when listed writable, else its `.custom` pair via the ensure door; ADR-0146 D2, objectstack-ai#35624 ruling C) through the existing confirmed-save door `saveDashboardInPlace`; then the menu written and published with the new entry in the held place and every other staged menu edit (`writeAppMenu`). Where the menu cannot be saved, nothing is created: no package-less fallback. - A refused menu removes the dashboard again (the item DELETE with `?package=`, measured on a live server: `Deleted dashboard ... it no longer exists`). If that removal is refused too, the error says the dashboard was left. - The design mode gains `saveWith(key, change)` (`designMode.tsx`): commit everything staged with one change in its key's place, never staging it on its own, so a failed create leaves no half-written entry staged for a later Save. - The machine name is generated from the name (Chinese through pinyin), and checked free on the server (`GET /meta/dashboard/:name`) so a create never publishes over an existing dashboard. - On success the mode is left and the page navigates to the dashboard with a one-time navigation-state landing (`designModeArrival.ts`); `DashboardView.tsx` opens its objectstack-ai#36372 edit state on that landing once the Edit button is offered, and clears it. - A dashboard with no cards now draws 「No cards yet」 instead of a blank canvas (view mode only). - **Not in this PR: 「New report…」.** The spec refuses a report without `dataset` + `values`, and the server's draft save refuses it too (`INVALID_METADATA`, measured), so a name-only report cannot be created. The seat's premise correction on the card (comment 7090058961) settles it: 「New report…」 opens the report builder (objectstack-ai#36374) in a create mode and writes the report and its menu entry once a dataset and a measure are picked; that half follows after objectstack-ai#36374 merges. Branch name: this card thread's container pushes only to `claude/project-thread-un7cwb`, so the `claude/issue-36364-*` spelling the Duplicate Fix Guard looks for is not available; the card is objectstack-ai#36364 (claim comment 7088329990). Overlap: touches `DashboardView.tsx`, which draft PR objectstack-ai#36461 also touches; `overlap-check` reads both merging cleanly. This PR lands after objectstack-ai#36461 per the claim. ## Tests <details><summary>Unit and component tests (head 313b6bf)</summary> Run from the repo root under `os-verify-lock`; vitest root `ui/`. - Head `313b6bf8` merges `origin/main`, bringing objectstack-ai#36604 (the `designModeMenu.ts` rename to `designModeMenuModel.ts`), objectstack-ai#36622 (objectstack-ai#36591's menu `order` rule) and objectstack-ai#36461. The one conflict, in `DesignModeMenu-36363.test.tsx`, was resolved by keeping both sides: this card's `server` mock, its reset and its describe, next to objectstack-ai#36591's `servedNav` and its describe. Two imports were moved to the renamed module (`designModeMenuCreate.ts` and its test); no file names the old module any more. objectstack-ai#36591's `inShownOrder` / `withOrderRewritten` auto-merged into `prepareAppMenuSave`, so the create path applies the same rule. It is pinned by a new test: the new entry, held between two entries of an `order`-carrying level, is saved as `[customer 0, nav_item_1 1, contact 2, opportunity 3]`. - At `313b6bf8`, after rebuilding the app-shell dependency closure (`VERDICT command-exit 0`): `pnpm --dir ui exec vitest run --maxWorkers=2 packages/app-shell/src/layout/ packages/i18n/` plus the 9 `packages/app-shell/src/views/DashboardView*.test.tsx` files gives `Test Files 271 passed (271)`, `Tests 3301 passed | 13 skipped (3314)`, `VERDICT command-exit 0`. This covers the 4 card files and every layout/i18n/DashboardView test the merge touched. - At `313b6bf8`: `designModeMenuCreate-36364.test.ts` alone gives `Tests 14 passed (14)`. - At `313b6bf8`: `pnpm --dir ui --filter @object-ui/app-shell --filter @object-ui/i18n run type-check` (both `tsc --noEmit` and `tsconfig.test.json`) gives `VERDICT command-exit 0`, 0 `error TS`. - Earlier, at `ab2257f4`: the i18n run plus the 4 card files gave 110 files and 2050 tests passing. At `0647077c`, a narrowed app-shell + i18n run found 3 failures caused by this change: zh-Hant was not regenerated, and the de quote count was 125 against 126. Both were fixed. The full app-shell suite is left to CI's `Test` shards. - New and extended pins: - `designModeMenuCreate-36364.test.ts`: 14 tests (13, plus the `order` pin). - `DesignModeMenu-36363.test.tsx`: 4 tests (the create row, Cancel writes nothing, the create-and-land flow, a refused menu). - `designMode-36362.test.tsx`: 3 tests for `saveWith`. - `DashboardView.inPageEdit-36372.test.tsx`: 3 landing tests and 2 empty-state tests. </details> <details><summary>Ablations (one-shot, not kept)</summary> - Removal of the created dashboard on a refused menu deleted (`ablation-replace`, anchor 1 to 0, restored blob equals HEAD): 3 tests red (`a refused menu removes the dashboard it was made for…`, `…cannot be removed says the dashboard was left`, `a refused menu removes the new dashboard; the mode, the held place and the other staged edits stay`). - The dashboard created before the menu-save checks: 8 of 13 red in `designModeMenuCreate-36364.test.ts`, every "nothing is created" case among them. A first attempt of this leg was refused by the tool (the replacement contained its own anchor) and ran no tests; the second attempt is the reading above. </details> ## Acceptance notes - The card's first acceptance line names the group 「数据洞察」; the CRM example's group is 「数据分析」, used for the screenshots. - 「Members see an empty state」 was checked as the admin in view mode; the empty-state branch has no role gate. A non-admin session was NOT MEASURED. - Test pins went into the existing harness files for the design mode, the menu editor and the dashboard in-page edit (AGENTS.md: a new pin for a component with a shared harness goes into that file), plus one new file for the new module, `designModeMenuCreate-36364.test.ts`. ## Verification Screenshots (live CRM example on a `--fresh` backend, console dev server, zh-CN, deviceScaleFactor 2) are stored with the seat (`objectstack-seat2/36364-shots/`): design mode; picker 「仪表盘」 with 「新建仪表盘…」 first; the name step; the new 「回款分析」 in its edit state, in the held place under 数据分析; Cancel leaving nothing; the new dashboard in view mode (「还没有卡片」); Studio 「界面」 listing the same 回款分析 in the app's navigation. After the run: the dashboard is the only item of `com.example.crm.custom`, the app's stored menu holds `nav_item_1: hui_kuan_fenxi` under `group_analytics`, no draft is pending, and the cancelled name has no item (404). Read first: `ui/packages/app-shell/src/layout/designModeMenuCreate.ts` (the order and the removal), `designMode.tsx` (`saveWith`'s drop rule after a commit), `DashboardView.tsx` (the landing effect). Two-minute check: `pnpm --dir ui exec vitest run packages/app-shell/src/layout/__tests__/designModeMenuCreate-36364.test.ts` shows 14 passing. <details><summary>Derived gates (head ab2257f)</summary> - `node scripts/pm/dispatch-gates.mjs --commands --repo objectstack-ai/objectstack` derived 41 commands from the tree at commit ab2257f. Each was run with stdin from /dev/null, and its exit code was captured before any pipe. The two heavy commands ran under `os-verify-lock`: `pnpm --dir ui exec vitest run scripts/` and `pnpm check:type-check-debt`. - All 41 exited 0. The reconciliation with `--ran` reads: `Run reconciliation — 41 derived, 41 run, 0 NOT-MEASURED, 0 UNRUN.` - The record is stored with the seat (`objectstack-seat2/36364-gates-ran.txt`). - Before the PR was opened, `overlap-check` gave `VERDICT clean exit 0` against origin/main and the open PR heads. - At `313b6bf8`, `dispatch-gates --commands` derives the same 41 commands as at `ab2257f4`. The merge brought no new gate family for the touched paths, so the run above was not repeated. At push, `overlap-check` against origin/main is clean; it conflicts with open PR objectstack-ai#36629 on the serial de quote-count pin, and whichever lands second rebumps it. - CI families (lint farm, `Test` shards, `Test Core`) are left to this PR's check-runs; none was rerun locally. </details> --- _Generated by [Claude Code](https://claude.ai/code/session_01ADHkmPiTdmLxHXBjakSvJy)_ 🤖 Generated with [Claude Code](https://claude.com/claude-code) <!-- signed: repo:objectstack#2 · os-steve · session_01ADHkmPiTdmLxHXBjakSvJy --> --------- Co-authored-by: Claude <noreply@anthropic.com>
…efore its first render (objectstack-ai#36640) (objectstack-ai#36656) <!-- claude-projects-attribution: {"github_login":"os-warren"} --> _Requested by **Warren** · [project thread](https://claude.ai/code/project/chan_01U5RdnAAmkSQmZbqh6FtqZ8?thread=cmsg_01U5RdnAAmkSQmZbqh6FtqZ8PC4syDJ8bPonzN7bL9mdeU)_ Fixes objectstack-ai#36640 Also the cause of objectstack-ai#36649 (main's 4-hourly full run red at `e9fa6b5d06`); that card closes when the next full run is green. ## What changes `ui/packages/plugin-form/src/__tests__/lineItemsPrintRowCap-11958.test.tsx` loads the line grid's body at module scope (`await preloadGridField()`), before any test renders. No assertion is changed, removed, relaxed or retried; no timeout is touched; the file is not moved into `heavyDomTests`. Test-only: no product code moves, so no changeset (needs `skip-changeset`). ## Why Root cause, read from both failure logs and confirmed with a probe: - Both reds fail at **line 100** (`expected +0 to be 2`), the single row count read right after `waitFor` sees the row-ceiling note: the merge-queue run on PR objectstack-ai#36461 (reading 7092248222) and main's 4-hourly run 45135779472, job 137562669352 (`Test UI (3/16)`, `lineItemsPrintRowCap-11958.test.tsx:100:58`). Lines 112 and 118 never failed. - The note and the rows commit together (`setRowCap` and `setRows` are set in the same load callback in `LineItemsPanel.tsx`), but the grid's body is split out and loads on first use (objectstack#36102, `ui/packages/fields/src/widgets/GridField.ts`). `LineItemsPanel` starts that load at mount with `preloadGridField()` but does not wait for it, so a grid mounted before the load settles draws its loading face (`data-testid="grid-field-loading"`, no table) while the note is already in the DOM. - Probe at line 100 on unmodified `main` (`3cf6a44b`): `loadingFace=true tbody=false`. The count of 0 is the loading face, not a missing or extra row. This is the case `ui/AGENTS.md` § 测试纪律 names: an assertion that lands behind a dynamic `import()` loads that module at module scope, where the cost is outside every test window. Three sibling tests in this package already do exactly this (`ModalForm.untypedRepeater.test.tsx`, `masterDetailSectionMembers-8071.test.tsx`, `deriveMasterDetail.declaredSpelling.test.tsx`). Product side, considered and not changed: in the browser the note can sit under the grid's loading face only until the chunk that `preloadGridField()` already requested arrives, and printing is a user-triggered `window.print()`, so no printed page carries the note without its rows. The row cap and the note are unchanged. ## Verification All counts on `objectstack-ai/objectstack`, the 6-test file run alone with `npx vitest run --maxWorkers=2 packages/plugin-form/src/__tests__/lineItemsPrintRowCap-11958.test.tsx` from `ui/`, 20 runs each, under load (one busy loop per core on a 4-core container, so the file runs against 4 CPU stressors): | Tree | Red runs | Failing test | |---|---|---| | before: `main` `3cf6a44b` | **20 / 20** | `draws the cap’s rows…`, line 100, `expected +0 to be 2` | | after: this branch `0c621d36` | **0 / 20** | none; every run `Tests 6 passed (6)` | Run cold, as each fresh vitest run is, the load always loses the race; in CI's full run it loses only when the chunk's transform is slow, which is why the queue and the 4-hourly run saw it intermittently. Also on `0c621d36`: the whole `plugin-form` package under `--maxWorkers=2`, 245 files / 2766 tests passed, 1 skipped (pre-existing); `eslint` on the changed file clean. Clause-②: no Metadata-protocol: none ## Human Minimum - [x] 1. Schemas start as Zod; `packages/spec` holds no runtime logic. (not touched) - [x] 2. Every name I added uses the casing for its kind. (no names added) - [x] 3. No formatter ran; `pnpm lint` passes. (eslint on the changed file) - [x] 4. One issue, one branch off an up-to-date `main`, one pull request. - [x] 5. A change that publishes carries a changeset, and both declaration lines are filled in here and in the changeset. (test-only, publishes nothing) - [x] 6. `packages/spec` touched: its generated artifacts are regenerated and committed. (not touched) - [x] 7. No hand edits to `content/docs/references/`, `packages/*/CHANGELOG.md` or `content/docs/releases/`. - [x] 8. Title, body and comments are in English. - [x] The *Before Submitting* list in CONTRIBUTING.md is done. --- _Generated by [Claude Code](https://claude.ai/code)_ Co-authored-by: Claude <noreply@anthropic.com>
Requested by Steedos · project thread
Part of #36256
Fixes #36550
This PR lands the drill dialog. One piece stays open on the card, carried by #36507: a labelled chip for a relationship-path condition (plugin-list
readViewConditions/viewChipText, nested-relation form).Clause-②: yes (widening) — additive members only, among them the new
PageRegionPostureResetexport of@object-ui/components; nothing is removed or renamedMetadata-protocol: none
维护者速读
What changes
w-[70vw] h-[65vh], using the shared dialog surface (弹出框外观收紧:背后不再模糊、遮罩减淡,边改成两层(半透明外圈加白色内卡),白底,宽度跟着字段数走,控件降一档,底部加「连续创建」 #35980). Because it is non-modal, Radix draws no overlay: nothing behind it is dimmed or blurred. The header keeps the title and 「Open in list」, which is unchanged. On a phone (useIsMobile) the side drawer stays, with the same list inside.DrillRecordListmounts the registry'slist-view(the block the object list page uses) throughSchemaRenderer, bound withdataSource: { object }. It is read-only:userActionsturns off inline edit, add record, row colour and grouping;showViewSwitcher={false}; and the dialog never receives a save-view, add, bulk, edit, delete, sort-change or filter-change callback. Whenlist-viewis not registered, the drill falls back to the dashboard's data table, and its rows no longer open a stacked record panel.drillConditions.tssplits the composed drill filter (widget filter, global filters, clicked bucket, measure scope) into the list'sinitialFiltersrows, which are ordinary chips that can be edited and removed. Anything a chip row cannot say (a relationship path,$or, an unknown operator) stays the list's basefilter, ANDed. A filter that is not the object form is lowered first. Examples are a page block's authored rule array[{ field, operator, value }]and an AST node. The lowering goes through the drill's own composition,composeDrillFilterin@object-ui/core(mergeFilterNodes, then the spec'sparseFilterAST), and is not a new normaliser. A shape that cannot be lowered stays the list's basefilterexactly as it arrived: one the conversion refuses (FilterOperatorError), and a non-empty one it answers nothing for (an array that is neither rules nor AST, a rule with a blank or missing field, a valid rule beside such an element). A string or number filter, which no list can read, lists nothing: the drawer shows its existing 「can't be listed from here」 notice and sends no read. No condition is ever dropped, and no drill reads every record. A condition stated twice is drawn once. On date fields,$ltand$gtare written as the list's ownbeforeandafter, which lower to the same less-than and greater-than comparisons.crm_account.industry) shows its lookup field (crm_account) instead. The grid has no dotted-column support, so the lookup column (the account's name) stands in for the related value. This applies to the dashboard widget and the dataset report alike. The measured fields are read from the answer'sdrillScopes({field: {$null: false}}). An authoreddrillDown.columnsstill wins. 「View settings → Add column」 adds any other field. Added columns and column calculations live only in the dialog's state.DrillNavigationContextgains an optionalopenRecord(objectName, id, {siblings, total}). The app-shell hook implements it by navigating to the record page with history statefrom = {pathname, label, siblings, total}, the same shape a list hands the page it opens. The record page's existing stepper then reads 「1 of 3 · Pipeline Dashboard」, walks the drill rows, and its way back is the dashboard or report.RecordDetailViewis unchanged.DatasetReportChartpassed noonChartClick. A bar now maps throughfindChartSeriesRowto the summary line it stands for, and both go through one builder (emitBucketDrill), so the bar and its line open the same records with the same defaultfields.drilldown: falsestill offers no click.object-metricandobject-pivotpage blocks mount the drill without aDrillNavigationProvider, so there is noopenRecord. There, a drilled row opens its record in a dialog (RecordDetailDrawer,target: 'dialog'), from both the standard list and the data-table fallback. Dashboard and report hosts are unchanged and open the record page.main.$select). So its record dialog draws those fields, each with its value. It uses the authoreddrillDown.columnswhen given, asObjectDataTabledoes. It does not list every field of the object with the unread ones shown as empty.objectTypesPendingguard, as in the data table.DrillRecordListnow clears the posture for its subtree with the newPageRegionPostureReset(@object-ui/components, next toPageRegionPostureProvider). The drill therefore draws the standard list everywhere, with its chips, record count and pager, and no 「View all」 link. The page's own list blocks keep their posture.measuredFieldsOfcopies, on purpose. One lives in plugin-dashboarddrillConditions.ts, the other in plugin-reportDatasetReportRenderer.tsx, and no shared helper was added to@object-ui/core. Their predicates differ. The dashboard copy reads a measure scope that is already one record list, and takes a field only when its whole condition is{$null: false}. The report copy reads the answer'sdrillScopesper line, and takes every$null: falsefield it finds. A scope that adds other conditions on the same field gets a column in the report but not in the dashboard. This is a known edge.DrillNavigationValue.openRecord, theDrillRecordOrigintype (@object-ui/react),DrillDownDrawerProps.defaultColumnsandDatasetDrillArgs.fields. New export:PageRegionPostureReset(@object-ui/components, apatchentry (Metadata-protocol: none)).Tests
Unit and integration runs (head 0290ee5)
All runs below are under
scripts/pm/os-verify-lock.sh, on head0290ee50d3.Drill suites, run from
ui/withpnpm exec vitest run --maxWorkers=2, covering:Result:
Test Files 103 passed (103)·Tests 919 passed | 7 skipped (926)· vitest exit 0.pnpm --dir ui exec vitest run scripts/(derived):Test Files 172 passed | 2 skipped (174)·Tests 5127 passed | 2 skipped (5129)· exit 0.Reverse check on the rebuilt
.d.ts: a probe passed{ siblings: ['a'], bogus: 1 }toopenRecord.tscturned red withTS2353 ... 'bogus' does not exist in type 'DrillRecordOrigin'(exit 2). The probe was then removed, andgit statusis clean.Type-check (built closure)
@objectstack/specfirst, thenpnpm --filter '@object-ui/app-shell^...' run build. Both exit 0.type-check(the script name was echoed) exits 0 for each of@object-ui/react,@object-ui/plugin-dashboard,@object-ui/plugin-reportand@object-ui/app-shell. Each runstsc --noEmitand thentsc -p tsconfig.test.json.dispatch-gates --ranreads38 derived famil(ies) accounted for — 38 run, 0 NOT-MEASURED (a DERIVED zero).check-platform-checklist --changed-from origin/main: OK.overlap-check:VERDICT clean exit 0. The check covers feat(console): edit a dashboard on its own page, and mark the page filters a card does not follow #36405 and feat(app-shell): report and widget panels speak business wording, and opening the report editor keeps the page in the session language #36420, and both merge cleanly.CI fix round (head bd8af5c)
Four reds on 0290ee5 and f8140a7, each reproduced locally and then shown green:
check:spec-symbols: the drill's chip-split file declared a local type named like a spec export (Scalar, owned by@objectstack/spec/data). The fix inlines the union. The check exits 1 on the old tree and 0 on the fix, measured with@objectstack/specbuilt. The other steps of the same job (check:action-forward-parity,check:designer-field-key-parity,check:icon-record-names,check:i18n-keys,check:i18n-drift) exit 0, andtype-checkexits 0 for@object-ui/plugin-dashboardand@object-ui/app-shellon the merged head.react-hooks/globalsflagged the drill dialog test's stub, which wrote a module-level variable during render. The stub now reports its props through avi.fnspy.eslinton the old file gives 1 error.lintexits 0 (0 errors) for@object-ui/plugin-dashboard,@object-ui/plugin-report,@object-ui/reactand@object-ui/app-shell.components/src/__tests__/dialogViewportGutterCensus-12603.test.ts. The dialog lifted the width cap (sm:max-w-none), which the census reads as a wide dialog with no viewport gutter. It now caps atmax-w-[70vw], so the size is unchanged (70vw by 65vh) and the dialog keeps its own margin. The census fails 2 tests on the old tree; on the fix, the census plus the drill dialog suites read 4 files and 22 tests passed.check:eager-closurebefore any spec ran: a supersededPER_CHUNK_GZIP_CEILINGS(main moved it, and nothing had grown). Mergingorigin/main(37367f3) clears it, as the gate prescribes.Readings on the new head:
vitest run scripts/: 172 files passed.dispatch-gates --ran: 38 derived, 38 run, 0 NOT-MEASURED.overlap-check: clean.Round 7 (no dropped filter, standard list inside a page)
M6, a non-empty filter the conversion answered nothing for.
composeDrillFilteranswersundefinedwithout throwing for an array that is neither rules nor AST, a rule with a blank or missing field, and a valid rule beside such an element.drillListConditionsread that as no filter, so the drill listed every record. Now a non-empty input (anything butundefined,null,[]or{}) whose conversion comes back empty is kept as the list's base filter, the same as the throwing path.ValueDataSource: each such array reaches the read as$filter(a server refuses it as malformed), and the open deal is never listed.toFilterNodereads a non-object as no filter, so the read went out with no$filterand listed 3 of 3 rows.DrillDownDrawernow shows its existingunavailablenotice for such a filter and mounts no list, so no read is sent. This adds no new copy.#36550, the page region's posture inside the drill.
DrillRecordListwraps its subtree in the newPageRegionPostureReset. As L1-e found, the capped list's 「View all N」 link inside the drill came from the host'scompactListDestination: the object's default view, with no drill condition. That link is no longer drawn there.Pins, red on 942e9c2's
drillConditions.ts,DrillDownDrawer.tsxandDrillRecordList.tsx, then green. Red:12 failed | 15 passed (27). Green:27 passed (27). Restored withgit checkout HEAD --, then checked:git diff HEADempty and the blob hashes match.drillConditions-36256.test.ts: six inputs the conversion answers nothing for (an array of a bare object, a blank field, no field, a valid rule beside a malformed one, a string, a number) stay the base filter as they arrived.undefined,null,[]and{}are still no filter. N8: anandnode lowers to chips; anornode, and a rule array's any-of group, go to the base filter as$or. The N8 cases are green on both sides, because they pin behaviour that already held.app-shell/.../pageBlockDrillFilter-36256.test.tsx: the three arrays above, each with every read carrying$filterand the open deal not listed. The string and the number show theunavailablenotice and send no read.app-shell/.../pageBlockDrillPosture-36550.test.tsx: the real page renderer,object-metricandlist-view, with the region widths stubbed. The drill in themainregion (856 of 1200 px) shows the chipfilter-chip-stage, 「2 records」, no capped table and no 「View all」 link. CONTROL: the page's ownlist-viewblock in the same region stays capped (3 capped rows and 「View all 3」). Red: no chip in the dialog.Live re-check on HotCRM 销售主页. Branch Console at de4dfdf456 over HotCRM
origin/main(689166c). The same local-onlydrillDownwas added tokpi_revenue_won; it was not committed and was reverted afterwards.closed_wonopportunities out of 23./api/v1/data/crm_opportunity?populate=crm_account&top=25&select=id,name,crm_account,amount,close_date,stage&filter=["stage","=","closed_won"].repo-objectstack-7/card-36256/hotcrm-r7-sales-home-drill.png.Runs on de4dfdf456. That tree was pushed as 8e8c3bf, which differs only in a reworded trailer. a9d781d then changes only the changeset's
@object-ui/componentsgrade fromminortopatch, as theCheck Changesetlevel axis requires underMetadata-protocol: none(run offline with this body as the event: exit 0). plugin-dashboard + plugin-report: 251 files, 2425 passed / 13 skipped. components: 505 files (1 skipped), 4914 passed / 24 skipped. app-shell drill and page-block suites plus plugin-list's three posture pins: 15 files, 168 passed. type-check exit 0 for components, plugin-dashboard, plugin-report and app-shell. lint 0 errors for components, plugin-dashboard and app-shell.overlap-check:VERDICT clean exit 0, with 0 open PR heads sharing a file, the components index included.Round 6 (page-block drill filter)
The defect. Found live by L1-e, on HotCRM's 销售主页 tile 总收入(全部期间).
object-metricblock whosefilteris the spec's rule array,[{ field: 'stage', operator: 'equals', value: 'closed_won' }].$filteras written. The adapter lowers it.$filterwas[{"field":"stage","operator":"equals","value":"closed_won"}], and the rows were the 2 won deals only.Pins, each run red on b91ec49's
drillConditions.tsandDrillRecordList.tsx, then green. Red:4 failed | 7 passed (11). Green: 11/11.plugin-dashboard/__tests__/pageBlockDrillFilter-36256.test.tsx:object-metricblock with the HotCRM rule array: the drill list gets the chipstage equals closed_won. Red:expected { chips: [], base: undefined }.object-pivotblock with the same rule array: the drill list gets the block's condition and the clicked cell's. This one is green on both sides, because the pivot composes throughcomposeDrillFilterbefore the drill.app-shell/src/views/pageBlockDrillFilter-36256.test.tsx: the real@object-ui/plugin-listoverValueDataSource. The drill lists exactly the won records the tile sums, never the open one, and its read's$filtercarriesclosed_won. Red: the open deal was listed.drillConditions-36256.test.ts:[['stage', 'in', 'won']]) stays the base filter exactly as it arrived.Live re-check on HotCRM. Branch Console, HotCRM
origin/mainon 18.6.0. A local-onlydrillDown({ enabled: true, target: 'dialog', columns: ['name','crm_account','amount','close_date'] }) was added tokpi_revenue_won; it was not committed and was reverted afterwards.closed_wonopportunities (out of 23), each with stageclosed_won./api/v1/data/crm_opportunity?populate=crm_account&top=25&select=id,name,crm_account,amount,close_date,stage&filter=["stage","=","closed_won"].repo-objectstack-7/card-36256/hotcrm-r6-sales-home-drill.png.Round 5 (S3, S4, N4; head b91ec49)
All runs are under
scripts/pm/os-verify-lock.sh, fromui/withpnpm exec vitest run --maxWorkers=2.ObjectMetricWidget.drillOpensRecord-36256, a new case). The list stub answers with the record projected to its listed columns, the way the list's$selectread does. The object has 5 fields, and the drill lists 3.DrillRecordList.tsxat c59a3fc gives1 failed | 2 passed (3), withexpected [ 'Name', 'Stage', 'Amount', …(2) ] to deeply equal [ 'Name', 'Stage', 'Amount' ].git checkout HEAD --andgit diff HEADempty, giving 3/3.openRecordjsdoc now reads "Absent ⇒ the drill opens the record in a dialog.".changeset/36256-drill-dialog-standard-list.md. Its last sentence now reads: "A renderer without@object-ui/plugin-listregistered lists the drilled records in the dashboard's data table. A host that gives noopenRecord(a page block's metric or pivot) opens the drilled record in a dialog, from either body."range.fieldtakes its first segment in bothDatasetWidgetandemitBucketDrill.Other readings on b91ec49:
Test Files 250 passed (250)·Tests 2411 passed | 13 skipped (2424)· exit 0.type-checkexits 0 for plugin-dashboard, plugin-report and react, after the closure build.lintgives 0 errors for all three.vitest run scripts/: 172 files passed.dispatch-gates --ran: 38 derived, 38 run, 0 NOT-MEASURED.overlap-check: clean.Round 4 (head 5af2f6e)
All runs are under
scripts/pm/os-verify-lock.sh, fromui/withpnpm exec vitest run --maxWorkers=2.cmp, and the markergrep -cread 0 then 1):DatasetWidgetandDatasetReportRenderer.chartMarkDrill-36256.expected [ 'amount' ] to deeply equal [ 'crm_account', 'amount' ], andUnable to find [data-testid="record-detail-body"](twice).scripts/ablation-replace.mjs(&& !phoneremoved):1 failed | 6 passed (7). The restore was verified as blob equal to HEAD with an emptygit diff HEAD.Test Files 250 passed (250)·Tests 2410 passed | 13 skipped (2423)· exit 0.type-check(the script name was echoed, and it chainstsc -p tsconfig.test.json) exits 0 for@object-ui/plugin-dashboardand@object-ui/plugin-report, after building the^...closure.lintexits 0 for both, with 0 errors.New card-named tests:
plugin-dashboard/src/__tests__/drillConditions-36256.test.ts: chip rows versus the base filter, de-duplication, date bound wording, and measured fields.plugin-dashboard/src/__tests__/DrillDownDialog-36256.test.tsx:openRecordwith the shown rows and closes the drill.useIsMobileis mocked true, and a mutation of the phone branch turns it red. Withoutlist-viewregistered, no panel is stacked.app-shell/src/views/drillDialogStandardList-36256.test.tsx: the real@object-ui/plugin-list. The chips are removable, and a removal re-reads without the condition. There are zerocreate/update/delete/bulkcalls, no non-GET fetch and nolocalStorage.setItem. Columns lead with Name, then the drilled fields.app-shell/src/views/useOpenRecordList.drillRecordPage-36256.test.tsx:openRecorddrivesuseRecordPageReturn, giving the stepper 2 of 3, next to 3 of 3, and back to the dashboard URL including its query.plugin-report/src/__tests__/DatasetReportRenderer.chartMarkDrill-36256.test.tsx: a bar and its summary line emit the sameobjectFilterandfields.drilldown: falseoffers no click. Acrm_account.industryline drills on the nested condition with fields['crm_account', 'amount'].plugin-dashboard/src/__tests__/DatasetWidget.drillDialog-36256.test.tsx:DatasetWidgetitself opens the dialog (target="dialog",open), with these default columns:onSegmentClick): the grouped field, then the range field, thenmeasuredFieldsOf(scope), which gives['stage', 'close_date', 'amount'].measuredFieldsOf(readMeasureDrillScope(...)), which gives['amount'].crm_account.industryslice:['crm_account', 'amount'].plugin-dashboard/src/__tests__/ObjectMetricWidget.drillOpensRecord-36256.test.tsx: anobject-metricblock with no provider opens the drilled record in a dialog, from the standard list and from the data-table fallback.Changed tests:
DrillDownDrawer.chain.test.tsxis split by host: with a record page, the fallback rows are inert; with no record page, they stay drill-to-record.summarySubtotals-27975now expectsfields: ['owner_id']on the subtotal drill.Acceptance notes
HotCRM walk (round 4). Branch Console at 5af2f6e's source, against HotCRM booted from the published 18.6.0 packages. Desktop at 1440×1000, zh-CN. The executive dashboard (高管总览) and the 各阶段商机 report.
[], so there is no mark to drill.claude/issue-36256-shotsbranch, which holds no code.PATCH sys_user_preference(the dashboard's recent-visit entry) and the record page's ownPOST .../pageread.Browser walk on
examples/app-crm(Pipeline dashboard), desktop at 1440×900. The screenshots are in the project files underrepo-objectstack-7/card-36256/:1-bar-dialog.png: the bar 「Closed Won」. The dialog box measured 1008×585 px, which is exactly 70% × 65%. The overlay count is 0. Chips: Expected Close ≥ / ≤ (from the widget), Stage: Closed Won, Expected Close before 2027-01-01. Columns: Opportunity Name, Stage, Expected Close. 3 records.2-donut-dialog.png: the donut slice 「Prospecting」. Chips: Stage is none of Closed Won, Closed Lost; Deal Value is_not_null; Stage: Prospecting. Columns: Name, Stage, Deal Value.3-line-dialog.png: a line point 「2026-10」. Chips: the 12-month window plus the month bucket.4-kpi-dialog.png: the tile 「Won This Quarter」. Columns: Name, Deal Value.5-chip-removed.png: Stage: Closed Won removed. The list re-read and showed 6 records. Closing and reopening restores the original chips.6-added-column.png: View settings → Add column → Deal Value is added as a 4th column.7-record-page-1-of-3.pngand8-record-page-2-of-3.png: clicking a record name opens its full page reading 「1 of 3 · Pipeline Dashboard」, with no dialog left open. Next goes to 「2 of 3」. 「Pipeline Dashboard」 returns to the dashboard URL.9-phone-drawer.png: at 390 px wide the drawer keeps the phone list, with a filter badge of 5 and 3 records./api/requests were captured, apart from the dataset reads.PATCH sys_user_preferenceseen was the dashboard's own recent-visit entry (type: dashboard), fired on page load. A second one came from the record page's recent-visit entry. Neither comes from the dialog.$null: false, and 「阶段:not_equals 失败」 on the report drill (from$ne). The cause is plugin-listquickOperatorLabel, which has no words fornot_equals,greater_than,less_than,is_nulloris_not_nulland prints the stored id. The drill does not swap in a near-synonym. Carrier: plugin-list: a condition chip shows the raw operator id (is_not_null, less_than, ...) for operators only the advanced panel writes #36462.unavailablenotice and no read (a deviation from the round-7 recipe, accepted by the seat): no list can carry such a filter, and the list's owntoFilterNodewould read it as no filter and list every record.crm_account.industrylists the right records, but its locked chip reads 「所属客户:= [object Object]」 (see the industry shot above). Carrier: drill dialog: a relationship-path condition shows as a locked chip reading "= [object Object]" #36507.$orreads 「View filter」, while an operator the rows have no id for ($startsWith) reads 「Owner: startswith A」.ListViewBlockhandsListViewits ownonTotalChange={reportTabCount}after spreading the props, so the drill'sonTotalChangeis replaced (byundefinedoutside apage:tabspanel). Measured with the real list over a source answeringtotal: 40for 2 rows:openRecordreceived{ siblings: ['d1','d2'] }and nototal. So the stepper's M is the rows on screen, not the match count, once a drill holds more rows than one page. A fix needs a plugin-list edit, which is outside this PR. By the same code read, not measured: a drill opened from inside apage:tabspanel would report its count to that tab's badge.ui/packages/react/src/context/DrillNavigationContext.tsx(the optionalopenRecordmember) is outside the declared file surface.Clause-②: yes (widening)on the built.d.tsclosure reading (the four new optional members above); the declaration line above and the changeset follow it.pnpm dev:crmrefused oncheck-dev-prereqs(missing dists), so the walk ranobjectstack devdirectly inexamples/app-crm.claude/issue-36256-shots. It holds one orphan commit with 8 PNGs and went up in the samegit pushas this branch. GitHub has no other host for an agent-written body's images.Verification
Read first:
ui/packages/plugin-dashboard/src/drillConditions.ts: the filter-to-chip split. If a condition is dropped or mis-worded, the list shows the wrong records.ui/packages/plugin-dashboard/src/DrillRecordList.tsx: the read-only schema and theopenRecordset.ui/packages/plugin-report/src/DatasetReportRenderer.tsx:emitBucketDrill, now shared by the summary line and the chart mark.Two-minute check: run
pnpm dev:crm, open Analytics → Pipeline and click the 「Closed Won」 bar. Expect a centred dialog with nothing dimmed behind it, the Stage: Closed Won chip, and 3 records. Click 「Initech — Pilot」 and expect the record page to read 「1 of 3 · Pipeline Dashboard」.🤖 Generated with Claude Code
https://claude.ai/code/session_01QsR2jREBdDtYvSLn38xUCg