- Migrate due_date/next_occurrence columns from TIMESTAMPTZ to DATE - Update serializeRow() to distinguish DATE vs TIMESTAMPTZ serialization - Simplify frontend date parsing (no more timezone workarounds) - Add Vitest + Testing Library test infrastructure - Add initial date parsing/formatting unit tests - Update package.json with dev dependencies (vitest, testing-library, jsdom)
2.4 KiB
2.4 KiB
VixTix Implementation Plan
Architecture
- Next.js 16 App Router (TypeScript + Tailwind)
- PostgreSQL database (Docker container, port 5433)
- Drizzle ORM for database access
- RESTful API routes under
/app/api/ - Multi-stage Docker build with PostgreSQL
Database Schema
- projects: id, name, description, color, sort_order, created_at, updated_at
- tasks: id, project_id (FK), title, description, completed, priority (low/medium/high/urgent), due_date, status (todo/in_progress/done), parent_task_id (FK, self-ref), recurrence_rule (daily/weekly/biweekly/monthly/yearly/none), recurrence_interval, next_occurrence, sort_order, created_at, updated_at
- Recurring tasks: Handled inline in tasks table. When completed, if recurrence_rule != 'none', create new task with same data, next_occurrence as new due_date, and increment sort_order.
API Routes
GET /api/tasks?project=&search=&status=&priority=&due_before=&due_after=&completed=— list with filtersPOST /api/tasks— create taskPUT /api/tasks/[id]— update taskDELETE /api/tasks/[id]— delete taskPATCH /api/tasks/[id]/done— toggle completion (handles recurrence)GET /api/projects— list projectsPOST /api/projects— create projectPUT /api/projects/[id]— update projectDELETE /api/projects/[id]— delete projectGET /api/kanban— tasks grouped by status
Frontend Views
- Sidebar: Projects list (click to filter), New Task button, view switcher (List/Kanban/Calendar)
- List View: Filterable task list with search, sort by due date/priority. Click task opens detail panel.
- Kanban Board: Three columns (Todo/In Progress/Done). Click to move between statuses.
- Calendar View: Monthly grid showing tasks on due dates. Click date to create task.
- Detail Panel: Right-side panel for viewing/editing task details (title, description, project, priority, due date, recurrence, subtasks).
- New Task Modal: Quick add from header.
- Recurring Task Modal: Configure recurrence rule and interval.
UI Design
- Clean, modern productivity app aesthetic
- Dark sidebar (#1a1a2e), white content area
- Color-coded priority badges (red=urgent, orange=high, yellow=medium, green=low)
- Project color indicators
- Responsive layout
Docker
- Multi-stage build: builder + runner
- PostgreSQL container on port 5433 (avoiding conflicts)
- App on port 3070
- Docker Compose for orchestration