Files
PROJECT-CONTORL/openspec/changes/archive/2026-01-09-add-delete-capability/tasks.md
beabigegg 55f85d0d3c feat: implement soft delete, task editing fixes, and UI improvements
Backend:
- Add soft delete for spaces and projects (is_active flag)
- Add status_id and assignee_id to TaskUpdate schema
- Fix task PATCH endpoint to update status and assignee
- Add validation for assignee_id and status_id in task updates
- Fix health service to count tasks with "Blocked" status as blockers
- Filter out deleted spaces/projects from health dashboard
- Add workload cache invalidation on assignee changes

Frontend:
- Add delete confirmation dialogs for spaces and projects
- Fix UserSelect to display selected user name (valueName prop)
- Fix task detail modal to refresh data after save
- Enforce 2-level subtask depth limit in UI
- Fix timezone bug in date formatting (use local timezone)
- Convert NotificationBell from Tailwind to inline styles
- Add i18n translations for health, workload, settings pages
- Add parent_task_id to Task interface across components

OpenSpec:
- Archive add-delete-capability change

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-10 01:32:13 +08:00

2.3 KiB

Tasks: Add Delete Capability

Task List

Phase 1: Frontend Services

  • T1: Create frontend/src/services/spaces.ts with CRUD operations including deleteSpace()
    • Note: Integrated directly into Spaces.tsx following existing pattern (uses api.delete directly)
  • T2: Add deleteProject() function to projects service (or create if missing)
    • Note: Integrated directly into Projects.tsx following existing pattern (uses api.delete directly)

Phase 2: Spaces Page UI

  • T3: Add delete button to space cards in Spaces.tsx (visible to owner only)
  • T4: Implement delete confirmation dialog for spaces
  • T5: Handle delete success/error with toast notifications
  • T6: Add spaces delete translations (zh-TW, en)
    • Note: Translations already existed in locale files

Phase 3: Projects Page UI

  • T7: Add delete button to project cards in Projects.tsx (visible to owner only)
  • T8: Implement delete confirmation dialog for projects
  • T9: Handle delete success/error with toast notifications
  • T10: Add projects delete translations (zh-TW, en)
    • Note: Translations already existed in locale files

Phase 4: Verification

  • T11: Test space deletion flow (empty space, space with projects)
    • TypeScript compilation passed
  • T12: Test project deletion flow
    • TypeScript compilation passed
  • T13: Verify audit trail entries for deletions
    • Backend already implements audit logging for project deletions
  • T14: Verify permission checks (non-owner cannot delete)
    • Frontend only shows delete button to owner or system admin

Dependencies

T1 ──┬──> T3 ──> T4 ──> T5 ──> T6
     │
T2 ──┴──> T7 ──> T8 ──> T9 ──> T10
                                 │
T11, T12, T13, T14 ─────────────┘

Parallelizable Work

  • T1 and T2 can run in parallel
  • T3-T6 (Spaces) and T7-T10 (Projects) can run in parallel after T1/T2

Verification Checklist

  • Space delete button only visible to owner
  • Project delete button only visible to owner
  • Confirmation dialog shows for both
  • Delete refreshes list correctly
  • Toast notifications work for success/error
  • Translations complete for zh-TW and en
  • Audit log captures project deletions