Skip to content

列表:「In a queue」筛选只在真正用到队列的对象上显示,默认不显示 #34602

Closed

Description

@objectstack-fleet

coordinator#1 · hotlong · session_85eb0287cb754f0f9c2bed54cab9abff

立卡门类别:④ 协调节点的子单,承父单 #34571(控制台核心业务操作体验专题,维护者直派,「都是p1」)。⛔ 不是认领。
维护者 2026-11-17 原话:「大部分对象用不到 in a queue ,默认不应该显示」

现状(读码,objectstack origin/main ed45eb9;界面实测在 staging os-4e4qa4 与 hotcrm 本地实例)

  • 这个筛选在 ui/packages/plugin-list/src/ListView.tsx:6556–6570 画,条件在 :2583–2585:组织里至少有一个队列(hasAnyQueue),且对象有平台注入的 queue 列(objectHasOwnershipQueue,:1064–1073,即任何 ownership: 'user' 的对象)。
  • 所以组织只要建过一个队列,所有按用户归属的对象列表上都会出现它。实测:商机、报价单、AI 新搭的「会议」列表上都有。
  • 队列的元数据不挂对象:packages/spec/src/security/queue.zod.ts:96–98 只有 label、description、members,没有「哪些对象用队列」的信号。
  • 钉住现有条件的测试:ListView.queueSittingFilter-25769.test.tsx、ListView.emptyStateClearFilters-28908.test.tsx:177、e2e/list-toolbar-view-name-phone.spec.ts:112。

要做的

  1. 增加一个「该对象使用队列」的信号,并把它并进显示条件。形状由 domain:spec 定(对象或列表视图上的一个键,或由服务端按「该对象有记录或分配规则指向队列」给出),默认是不显示。
  2. 没有该信号的对象,列表上不出现这个筛选。

不做的

  • 不改队列的分配与归属机制。

验收

  1. 组织里有队列,但商机没有声明使用队列:商机列表上没有「In a queue」。
  2. 声明使用队列的对象(如工单)列表上有。

设计图(静态示意稿,标「新」的是改动;字段和文案以实际元数据为准)

图 15(左侧列表头部)

图 15(左侧列表头部)

Reader: domain:ui 车道,改 ListView.tsx 的 queueFilterOffered;键的形状需要 domain:spec 先出。

Dedupe: repo:objectstack-ai/objectstack "In a queue" chip list view queue filter object → 21,最近 #33957 / #29047 / #29052(均已关,手机工具栏与空状态),没有按对象收窄显示条件的卡。

Activity

  1. added
    priority:p1
    domain:ui
    on Nov 17, 2026
  2. objectstack-fleet commented on Nov 17, 2026

    @objectstack-fleet
    ContributorAuthor

    triage#1 · hotlong · session_01Q4EjjMnyLqJdzuktEmRPXH

    Path: none

    Triage: first touch → pm:queue · 2026-11-17T03:27Z

    ⛔ Not a claim.

  3. added
    pm:queue
    on Nov 17, 2026
  4. objectstack-fleet commented on Nov 17, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#3 · os-support-ai · session_01WGufzgh1zkZzDXL36ckWAG

    Ruled · 2026-11-17T03:42Z

    The maintainer, in the os-support-ai fleet project (thread "Run objectstack seat 3 console experience") at 2026-11-17T03:40Z, answered the seat's four-question pack (reviewed first by an independent fable agent at his request) with one word, verbatim: 「同意」 — i.e. every recommendation below.

    Ruled: A (union) — the server answers per object whether the In-a-queue filter can do anything: rows of this object sit in a queue now, OR an assignment rule routes this object into a queue. The toggle shows only then. No authored key (ruling 6429748166 on #26359 rejected a per-object switch). The card's 要做的 1 (「形状由 domain:spec 定(对象或列表视图上的一个键…)」) narrows to the server-derived signal; acceptance reads accordingly.
    Conditions carried into the dispatch: measure the per-object cost and session staleness; state the disclosure against #28508's 「Only the boolean」; a widened response is a contract change (L2 review). Shares the chip with #34580 (PR #34623): lands after it.

  5. objectstack-fleet commented on Nov 17, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#3 · os-support-ai · session_01WGufzgh1zkZzDXL36ckWAG

    Claim: PM loop round 1 · 2026-11-17T03:44Z
    Session: session_01WGufzgh1zkZzDXL36ckWAG
    Thread session: session_01WGufziJJZ4CWE7fc4YEVnq
    Account: os-support-ai
    Branch: claude/project-thread-zu7kjp (card-thread pinned branch)
    Worktree: objectstack-issue-34602
    Domain: domain:ui (with the server half that serves hasAnyQueue; cross-domain per the ruling)
    Seat: repo:objectstack#3
    File surface: the server package that serves hasAnyQueue (#28508) + its tests; ui/packages/plugin-list/src/** and the client that reads the answer; root .changeset/. A shape under packages/spec/src/** ⇒ stop and report first.
    Container & model: L, mode:thread (large card: contract change; hands its head back to area o3-C), model: TIER_DEFAULT build; L2 contract review by the seat, effort: high
    Clause-②: yes (widening — a per-object queue answer added to a served response)
    Metadata-protocol: none
    Responsibility: n/a — not a defect card
    Ruling-ref: the seat's Ruled comment on this card (maintainer 「同意」, 2026-11-17); ruling 6429748166 (#26359 A, no per-object key) respected
    Thread-read: 6937524209
    Premise: corrected by the ruling — 要做的 1 narrows to the server-derived signal (rows queued now OR an assignment rule routes the object into a queue); no authored key
    Serial constraints cleared: after #34580 (PR #34623, same In-a-queue chip in ListView.tsx): merge origin/main after it lands

    Lease o3-C (seat post #34584); child of epic #34571.

  6. added
    pm:dispatched
    and removed
    pm:queue
    on Nov 17, 2026
  7. objectstack-fleet commented on Nov 17, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#3 · os-support-ai · session_01WGufzgh1zkZzDXL36ckWAG

    Claim amendment · 2026-11-17T03:46Z

    The thread measured that hasAnyQueue's served shape lives in spec: packages/spec/src/api/auth.zod.ts:202 (MePermissionsAuthenticatedResponseSchema, strict) and packages/spec/src/contracts/ownership-queue-service.ts:254. The file surface widens by exactly those two files (two additive edits: a sibling field on the response and one optional service method), their tests and the generated outputs the gates require; the rest stays as claimed (plugin-sharing, plugin-hono-server, client, ui permissions, plugin-list). Same single-PR shape as #28508. Spec edits stay in this lane per area-lease.md's keep-in-lane rule; this seat runs L1 and the L2 contract review.

    Clause-②: yes (widening — additive response field + optional service method in packages/spec)
    Metadata-protocol: none

  8. objectstack-fleet commented on Nov 17, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#3 · os-support-ai · session_01WGufziJJZ4CWE7fc4YEVnq
    os-dev-report
    Stamp: 2026-11-17T05:38Z

    {
      "issue": 34602,
      "status": "done",
      "branch": "claude/project-thread-zu7kjp",
      "pr": "https://github.com/objectstack-ai/objectstack/pull/34674",
      "session": "session_01WGufziJJZ4CWE7fc4YEVnq",
      "head": "a342f155624e2afee9005fb6bb247ecef3352ab5",
      "premise_still_valid": true,
      "summary": "Per the ruling (6937524209), GET /auth/me/permissions now carries objectsUsingQueues beside hasAnyQueue. It lists the objects where a record sits in a queue now or an active assignment rule (an org sys_assignment_rule row, or a declared rule not switched off) routes into a queue, narrowed to objects the caller may read, with no names and no counts. plugin-sharing implements the new optional IOwnershipQueueService.objectsUsingQueues; the route asks only when hasAnyQueue is true; the list toolbar offers the In a queue toggle only for a listed object. The spec surface grew by the two additive edits the seat approved (claim amendment 6937613028). PR body carries the cost and staleness measurements and the disclosure against #28508.",
      "tests": "All under os-verify-lock, exit 0: spec me-permissions-response + authorable surface (15), plugin-sharing ownership-queue (79, 12 new), hono has-any-queue/envelope/outer-catch (32), client auth-me-permissions (3), verify me-permissions-has-any-queue (9, 4 new through the real door), ui queueSittingFilter-25769/emptyStateClearFilters-28908/hasAnyQueue-28428 (34), 13 app-shell files touched for test-source-alias (77). Typecheck exit 0: spec, plugin-sharing, plugin-hono-server, client, verify, and type-check for permissions, plugin-list, app-shell, plugin-detail, plugin-form, plugin-grid, plugin-view, plugin-kanban, plugin-calendar, plugin-gantt, fields, plugin-report, console. Ablations via scripts/ablation-replace.mjs (landed, restored, git diff HEAD empty): ListView gate -> 2 failed/18; hono narrowing dropped -> 1 failed/16; sitting read forced false -> 4 failed/79.",
      "gates": "dispatch-gates --commands on a342f155: 125 commands, all run serially on that head, 125 x exit 0; dispatch-gates --ran: 125 derived, 125 run, 0 NOT-MEASURED, 0 UNRUN (exit 0). First pass on the prior head: 4 exit-3 prerequisites (teardown self-test fixture fetch; skill-examples, dual-build-cjs-loads, i18n needed a packages/** build) and 1 real finding (check:test-source-alias, 14 edited test files) fixed in a342f155. spec check:generated named content/docs/references/** stale; regenerated (ceb31f71). eslint on changed files: 0 errors. CI check-runs: pending at report time.",
      "measurements": "Temp verify probe (deleted), sqlite-wasm in memory, 30 owned objects x 2000 rows + one 50k-row object: 32 reads per call (1 sys_assignment_rule + 1 limit-1 sitting read per owned object); method alone median 11.0-13.0 ms, nothing sitting; route median 18.0-21.9 ms with vs 7.9 ms without. Staleness: the console reads the payload once per session, so a newly queued object shows the toggle from the next sign-in, org switch or reload.",
      "dogfood_battery": "n/a — no `!` in the PR title and no (narrowing) arm",
      "files_changed": "162 files, +971/-32. Core: packages/spec/src/api/auth.zod.ts, packages/spec/src/contracts/ownership-queue-service.ts, packages/spec/src/api/me-permissions-response.test.ts, packages/spec/authorable-surface/api.json, packages/plugins/plugin-sharing/src/ownership-queue-service.ts (+test), packages/plugins/plugin-hono-server/src/current-user-endpoints.ts (+3 tests), packages/client/src/index.ts (+test), packages/verify/src/me-permissions-has-any-queue.test.ts, ui/packages/permissions/src/{PermissionContext.ts,MePermissionsProvider.tsx,usePermissions.ts} (+test), ui/packages/plugin-list/src/ListView.tsx (+tests), .changeset/34602-queue-toggle-per-object.md, content/docs/automation/queues-and-assignment-rules.mdx, content/docs/references/api/auth.mdx (generated). Mechanical: ~140 ui test fixtures gained objectsUsingQueues: [] (required on the spec response type).",
      "deviations": [
        "Surface beyond the claim + amendment: ~140 ui test fixtures across app-shell, plugin-detail, plugin-form, plugin-grid, plugin-view, plugin-kanban, plugin-calendar, plugin-gantt, fields, plugin-report and apps/console, because MePermissionsAuthenticatedResponse now requires the field; 13 of the app-shell ones also got a module-top `import '@objectstack/lint'` that check:test-source-alias asks of edited test files.",
        "Also outside the named surface: packages/verify door test, packages/client doc comment + test, content/docs/automation/queues-and-assignment-rules.mdx (staleness paragraph), generated content/docs/references/api/auth.mdx.",
        "PR body thread link is this thread's (session context), not the seat's link in the order.",
        "Serial constraint not yet met: PR #34623 is still open; origin/main is merged after it lands."
      ],
      "mcp_calls": "0 GitHub MCP calls (subscribe_pr_activity is the session tool, not GitHub MCP)",
      "api_writes": "2 — POST /repos/objectstack-ai/objectstack/dispatches (relay pr_create, run 44025419638) and this comment via post-stamped.mjs; plus git push of the branch",
      "open_questions": [],
      "security_findings": "none",
      "out_of_scope_findings": ["noted, not filed: there is no index on the `queue` column; a very large tenant could make the per-object sitting read a scan. Carrier: PR body (Cost section)."]
    }

    L2 contract review owed by seat 3.


    Generated by Claude Code

  9. objectstack-fleet commented on Nov 17, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#3 · os-support-ai · session_01WGufzgh1zkZzDXL36ckWAG

    Claim amendment · 2026-11-17T05:40Z

    File surface widens to what PR #34674 (head a342f15) measured, beyond amendment 6937432906's spec files:

    • packages/client/src/index.ts + auth-me-permissions.test.ts: the client's typed /auth/me/permissions answer carries the new field.
    • packages/verify/src/me-permissions-has-any-queue.test.ts: the boot-level pin of the served answer.
    • content/docs/automation/queues-and-assignment-rules.mdx (toggle conditions; also edited by fix(plugin-list): withhold the In a queue toggle on a view whose filter pins owner_id #34623 — this PR merges main after fix(plugin-list): withhold the In a queue toggle on a view whose filter pins owner_id #34623 lands) and content/docs/references/api/auth.mdx (generated from the spec, no hand edit).
    • packages/spec/authorable-surface/api.json (generated baseline).
    • Test fixtures and warm-up imports across ui/packages/** and ui/apps/console/** (about 140 fixtures gain the required field; 13 app-shell tests gain the warm-up import). Non-test UI edits stay as claimed: ui/packages/permissions/src/{MePermissionsProvider.tsx,PermissionContext.ts,usePermissions.ts}, ui/packages/plugin-list/src/ListView.tsx.

    Size 1003 changed lines, not governed. Review: L1-a (whole PR) + seat-run L2 at CONTRACT_REVIEW_TIER (published spec schema face).

    Clause-②: unchanged (yes, widening — additive response field + optional service method in packages/spec)
    Metadata-protocol: none

  10. objectstack-fleet commented on Nov 17, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#3 · os-support-ai · session_01WGufzgh1zkZzDXL36ckWAG

    Claim amendment · 2026-11-17T05:44Z

    Metadata-protocol line corrected, measured by CI on PR #34674: the new response field moves the authorable-surface shard (api/MePermissionsAuthenticatedResponse:objectsUsingQueues), so the kind is added and @objectstack/spec ships minor (head 549be4b; precedent PR #28704, hasAnyQueue).

    Clause-②: yes (widening — additive response field + optional service method in packages/spec)
    Metadata-protocol: added
    Skills-docs: none — a served /auth/me/permissions answer read by the console; no skill under skills/** or ui/skills/** teaches that route (grep for hasAnyQueue / me/permissions on main: 0 hits)

  11. objectstack-fleet commented on Nov 17, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#3 · os-support-ai · session_01WGufzgh1zkZzDXL36ckWAG

    Ruled: seat 3 on S3 of the L2 contract review of PR #34674 (objectsUsingQueues) · 2026-11-17T07:15Z

    1. (earlier ruling, recorded here) A caller outside every organization (isOutsideEveryOrganization) gets objectsUsingQueues: []. hasAnyQueue is unchanged.
    2. (new, from the delta record on b92c81f) On the walled postures (isolated, group), any caller with no active organization, including a member who has memberships but none active, also gets []; the service is not called with null for them. Under single the environment-wide read stays as is. Reason: the schema says "in the caller's organization"; under isolated that caller can read no row yet would be served object names driven by other organizations, and under group the list would reach past their membership set.
    3. hasAnyQueue stays out of scope for this card; if it should follow the same rule, that is a note for the filer, not part of 列表:「In a queue」筛选只在真正用到队列的对象上显示,默认不显示 #34602.
    4. The schema description names the no-active-organization case in one clause so the contract states it.
  12. objectstack-fleet commented on Nov 17, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#3 · os-support-ai · session_01WGufziunkXbDT7wUWqfmWz

    Delivered by PR #34674 (merged, e61af97): the list's "In a queue" toggle now shows only on an object a queue can hold something on (a record of it sits in a queue now, or an active assignment rule routes its new records into a queue), answered by the server in /auth/me/permissions objectsUsingQueues and narrowed to objects the caller may read; nothing is authored. Every other object hides the toggle. Reviews: L1 ACCEPT 6942793389, seat L2 PASS 6941654216 (S3 closed under ruling 6941437476; N4 accepted deviation, in the PR body). Nothing remains on this card. pm:dispatched comes off with the close.

    Follow-ups named in L1/L2, left for the seat to file (not owed here): the changeset names 3 of the 5 empty-list cases (N5); the hasAnyQueue item that ruling 6941437476 left out of scope; an index on (organization_id, queue) if a large tenant shows the sitting read in profiling.

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

Metadata

Metadata

Assignees

Labels

domain:uipriority:p1

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions