docs: add Plan 6 (subcontractor portal data + project parity)

This commit is contained in:
Satyam Rastogi
2026-05-29 19:54:05 +05:30
parent 9625aafd73
commit 5141d2adea
2 changed files with 173 additions and 1 deletions
+2 -1
View File
@@ -521,7 +521,8 @@ Each plan = one phase, produces working/verifiable software on its own, and is e
### Plan 6 — Subcontractor portal data + project parity
- **What:** realistic data on `/subcontractor/*`; a subcontractor viewing their task sees the **same project** the owner sees (permitted subset — address, scope, schedule, their slice of budget/payments).
- **Why:** coherence across logins is the demo's credibility test — the same job must look like the same job to owner and subcontractor.
- **How:** reuse the unified project entity (Plan 2) + the upcoming ABAC visibility (Plan 8) to render a scoped project view in the subcontractor pages; seed/enrich subcontractor-facing data in `mockStore.jsx`; build the portal views (component files → parallelizable). Verify: a sub's task links to the real project; the owner and sub views agree.
- **How:** reuse the unified project entity (Plan 2) + the upcoming ABAC visibility (Plan 8) to render a scoped project view in the subcontractor pages; seed/enrich subcontractor-facing data in `mockStore.jsx`; build the portal views (component files → parallelizable). Verify: a sub's task links to the real project; the owner and sub views agree. (Concretely: reconcile sub↔project linkage in `mockStore.jsx`; add `subcontractorProjects` + `scopedProjectForSub` selectors — the latter is the single guard that omits owner-private fields; ground the dashboard KPIs in real `subcontractorTasks`; build a scoped `/subcontractor/projects/:id` page; link the task detail to it. Plan 8 later replaces the hand-written field-omission with an ABAC policy.)
- **Plan file:** `docs/superpowers/plans/2026-05-29-plan6-subcontractor-portal-parity.md`.
### Plan 7 — Profiles, skill catalog & AI dispatch context
- **What:** two-layer profiles (self + company) per person; the self-service User Details page (all roles); the owner Employee/Subcontractor Details view; the org skill catalog; ProCanvas achievements surfaced; `DISPATCH_REPS` mapped to canonical people; dispatch `reasons`/`aiInsight`/`skillMatch` authored to cite real profile facts.