docs(openspec): archive completed changes and sync main specs
Archive three completed changes to archive/: - api-resource-standard (70 tasks, 14 resource classes) - capacity-expert-mode (68 tasks, expert mode planning grid) - enhanced-allocation (62 tasks, planning fidelity + reporting) Sync all delta specs to main specs/: - api-resource-standard: API response standardization - capacity-expert-mode: Expert mode toggle, grid, KPIs, batch API - resource-allocation: Month execution comparison, bulk, untracked - untracked-allocation: Null team member support - allocation-indicators: Variance indicators (red/amber/neutral) - monthly-budget: Explicit project-month planning All changes verified and tested (157 tests passing).
This commit is contained in:
@@ -0,0 +1,32 @@
|
||||
## Why
|
||||
|
||||
Capacity planning today requires switching between team members one at a time in a calendar card view — too slow for a daily standup. Managers need a spreadsheet-style grid where the entire team's availability for the month is visible and editable at a glance, in under a minute.
|
||||
|
||||
## What Changes
|
||||
|
||||
- Add an **Expert Mode toggle** to the Capacity Planning page (right-aligned on the tabs row), persisted in `localStorage`.
|
||||
- When Expert Mode is ON, replace the per-member calendar card view with a **dense planning grid**: team members as rows, days-of-month as columns.
|
||||
- Each cell accepts exactly one of: `H`, `O`, `0`, `.5`, `0.5`, `1` — any other value is invalid (red on blur, submit disabled globally).
|
||||
- `H` and `O` are interchangeable display tokens that both normalize to `0` for math; the frontend always preserves and displays the typed token.
|
||||
- Typing `0` on a weekend column auto-renders as `O`; typing `0` on a holiday column auto-renders as `H`.
|
||||
- Live KPI bar above the grid shows **Capacity (person-days)** and **Projected Revenue** updating as cells change.
|
||||
- Batch save: a single **Submit** button commits all pending changes; disabled while any invalid cell exists.
|
||||
- Backend gains a new **batch availability endpoint** to accept multiple `{team_member_id, date, availability}` entries in one request.
|
||||
|
||||
## Capabilities
|
||||
|
||||
### New Capabilities
|
||||
|
||||
- `capacity-expert-mode`: Spreadsheet-style planning grid for bulk team availability editing with token-based input, live KPI bar, and batch save.
|
||||
|
||||
### Modified Capabilities
|
||||
|
||||
- `capacity-planning`: Existing per-member calendar and summary remain unchanged; Expert Mode is purely additive. No requirement changes to existing scenarios.
|
||||
|
||||
## Impact
|
||||
|
||||
- **Frontend**: New `CapacityExpertGrid` component; `capacity/+page.svelte` gains mode toggle + localStorage persistence; `capacity.ts` API client gains batch update function; new `expertModeStore` or localStorage util.
|
||||
- **Backend**: New `POST /api/capacity/availability/batch` endpoint in `CapacityController`; `CapacityService` gains `batchUpsertAvailability()` with consolidated cache invalidation.
|
||||
- **No schema changes**: `team_member_daily_availabilities` table is unchanged; values stored remain `0`, `0.5`, `1`.
|
||||
- **No breaking changes**: Existing calendar mode, summary, holidays, and PTO tabs are unaffected.
|
||||
- **Tests**: New unit tests for token normalization/validation; new feature test for batch endpoint; new component tests for grid and toggle.
|
||||
Reference in New Issue
Block a user