Commit Graph

4 Commits

Author SHA1 Message Date
Bas van Rossem
56e0162230 feat(api): orderable activities + admin reorder endpoint 2026-06-17 20:58:06 +02:00
Bas van Rossem
0d82b6efbc feat(shared,api): add pause + sort_order columns and contracts
Adds server-side pause accounting and activity ordering primitives.
- WorkSession contract gains paused_seconds (number) and paused_at (ISO string | null).
- Activity contract gains sort_order (number); new ReorderActivitiesInput zod.
- work_sessions += paused_seconds (int NOT NULL DEFAULT 0) + paused_at (timestamp_ms nullable).
- activities += sort_order (int NOT NULL DEFAULT 0).
- toWorkSession / toActivity map the new fields; generated migration 0003.

The new fields are additive; existing api/worker/admin tests stay green.

Products affected: SoleLog backend (apps/api), shared contracts (packages/shared)
2026-06-17 20:49:56 +02:00
Bas van Rossem
f2cc0973c7 feat(api): role-aware session helper + admin-only activity writes 2026-06-17 17:43:37 +02:00
Bas van Rossem
5e61b7720d feat(api): user-scoped activities CRUD with shared auth helper 2026-06-17 15:34:42 +02:00