Skip to content

skills(ui actions):「新标签页打开」示例的 target 用了 spec 不支持的 ${record.id} 占位,且挂在没有当前记录的 list_toolbar 上 #35696

Closed as not planned

Description

@objectstack-fleet

repo:objectstack#1 · os-sales · session_01L6bhgUZrkMKgGrXXe8zPGq

Filing gate:① 已发布技能文字的教学错误。来源:PR #35673 的 os-dev-report 7024934065(out_of_scope_findings),经 delta L2 记录 7025422414 第 ③ 节核实并判为不在该 PR 范围;席位 2026-11-19T23:46Z 要求立卡。⛔ 不是认领。

Grade:交分诊。

现在的情况

skills/objectstack-ui/rules/actions.md「Opening in a New Tab」一节的已检查示例 PrintA3Action(name: 'crm_print_a3')写的是:

  type: 'url',
  target: '/print/a3?id=${record.id}',   // interpolated at click
  openIn: 'new-tab',
  locations: ['list_toolbar'],

有两处与 main 上的 spec 不符:

  1. 占位写法:packages/spec/src/ui/action.zod.ts 中 target 的 Interpolation 说明只列了两族占位,${param.X}(参数弹窗收集的值)和 ${ctx.X}(动作上下文),记录 id 写作 ${ctx.recordId};同文件 preflight 那条也用 ${ctx.recordId}。${record.X} 不在其中。packages/spec/src/ui/action.test.ts 能解析这串字符,所以 schema 不拦,但渲染时会不会填充没有测过。
  2. 位置:同文件的 locations 表把 list_toolbar 描述为对选中行的批量动作(input.selectedIds),那里没有「当前记录」。

PR #35673(S1)给这个示例补上了 objectName: 'lead',它从此会出现在 lead 列表工具栏上。作者照抄时更容易碰到这个问题。该行早于 #35673,#35673 没有改它。

期望

示例的占位写法和位置与 spec 一致。比如改用 ${ctx.recordId} 并放到有当前记录的位置(例如 record_header),或者保留 list_toolbar 但不引用单条记录。选哪种由负责人定。改完后示例仍是可检查的 os:check 块,token 不超过该文件上限(新增内容在同文件删词抵付)。

Done when

  • 该示例的 target 只用 spec 列出的占位,且所在 location 能提供它引用的值。
  • check:skill-examples、node scripts/check-skills-token-ratchet.mjs 与其余 skill 门禁 exit 0。
  • 若渲染器实际上也填 ${record.X},就改 spec 的 Interpolation 说明而不是改示例。这属于 spec 改动,要按规则另走裁决。

谁来做:area:build(skills 文字)。依赖:先等 #35673 合并(同一文件、同一示例)。

Activity

  1. added
    bug
    domain:skills
    on Nov 19, 2026
  2. objectstack-fleet commented on Nov 19, 2026

    @objectstack-fleet
    ContributorAuthor

    triage#1 · hotlong · session_01Q4EjjMnyLqJdzuktEmRPXH

    Triage: lands in domain:skills · pm:queue; rationale: area:build · Bug (shipped objectstack-ui actions.md shows a new-tab target with ${record.id}, a placeholder the spec does not resolve, on a list_toolbar action that has no current record; an author who copies it gets a broken link) · builders, often → p2 under the shipped-skill rule. It predates PR #35673; land it after that PR.

  3. added
    pm:queue
    priority:p2
    on Nov 19, 2026
  4. objectstack-fleet commented on Nov 20, 2026

    @objectstack-fleet
    ContributorAuthor

    triage#1 · hotlong · session_01Q4EjjMnyLqJdzuktEmRPXH

    Ruled: fold · maintainer 2026-11-20T05:1xZ, verbatim: 「只考虑合并没人认领的,没开始开发的,你负责处理」

    2026-11-20T05:31Z · Folded into #35647. This card's ask — "skills(ui actions):「新标签页打开」示例的 target 用了 spec 不支持的 ${record.id} 占位,且挂在没有当前记录的 list_toolbar 上" — is now a row on #35647, which carries its shared-mechanism group so one claimant fixes them in one PR. The body here stays the detail that row points to. Closed only as a separate card, not as work.

  5. removed
    pm:queue
    on Nov 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:buildbugdomain:skillspriority:p2

    Type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions