Skip to content

Member detail page — open one person's duties without asking them #13

Description

@os-warren

The screen that removes the "can you send me a status update" mail. A manager opens a person and sees everything, having entered nothing.

Blocked-by: #8 (the scopes that decide what they may see).

Files you own

  • src/pages/member.page.ts (new), pushed into dulyPages in src/pages/index.ts
  • a nav entry in the Team group of src/apps/duly.app.ts
  • test/member-page.test.ts (new)

Content, in reading order

  1. Header — name, position, unit, manager.
  2. Right now — open tasks, of which late, of which not moving. Three numbers, the third emphasised.
  3. This period — their governed duties and the state of each. Grouped by frequency so a monthly rhythm reads differently from an annual one.
  4. Standing duties — listed, with no tick affordance anywhere near them. They never complete; a control that implies otherwise is a bug.
  5. Recent activity — last 20 task events by last_update_at.
  6. Assigned to them — tasks with source: 'assigned', showing who assigned each.

Not on this page

  • Their work log. duly_log_entry is readScope: 'own' for every position; the only widening is a record's own visibility: 'manager' flag via a sharing rule. Do not query the object here at all — not filtered, not counted, not "0 entries". A manager seeing a log count learns the log exists and that it is being watched, which is enough to stop people keeping one.
  • Any editable control. Read-only page. A manager's only write in this product is assigning, and the assign action lives on its own object.
  • Any comparison to other people. No percentile, no "vs team average", no rank. Their own trend over time is fine and useful; a position in a distribution is a performance score.

Rules

  • Everything must read correctly for a manager whose scope resolves through the ADR-0057 depths. In this open-edition checkout those fall back to owner-only, so the page will look empty for anyone but yourself — expected, not a bug (see Security model — positions, permission sets, sharing rules #8). Assert authored scopes and filters in tests rather than resolved rows.
  • Standing duties come from duly_duty where form = 'standing'; they have no tasks by construction, so do not join through tasks to find them.

Acceptance

  • the page renders from duly_task / duly_duty only; grep the file — no reference to duly_log_entry anywhere
  • standing duties appear with no completion control
  • nothing on the page is editable
  • no comparison-to-peers element exists
  • reachable from the Team nav group

Gates

pnpm validate && pnpm typecheck && pnpm test && pnpm build.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions