From 7f5bcfe4e18a47e6d63496e6fed11e4a93495a0e Mon Sep 17 00:00:00 2001 From: bonamin Date: Mon, 20 Apr 2026 12:25:26 +0300 Subject: [PATCH] Update session instructions: document Phase 2 completion, fixes, and dev data --- PLANS AND STRATEGIES/CLAUDE_CODE_INSTRUCTIONS.md | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/PLANS AND STRATEGIES/CLAUDE_CODE_INSTRUCTIONS.md b/PLANS AND STRATEGIES/CLAUDE_CODE_INSTRUCTIONS.md index 20910b9..709f15a 100644 --- a/PLANS AND STRATEGIES/CLAUDE_CODE_INSTRUCTIONS.md +++ b/PLANS AND STRATEGIES/CLAUDE_CODE_INSTRUCTIONS.md @@ -35,11 +35,24 @@ We are building a local-first restaurant POS system. Full architecture and specs ## Current Build Phase > Update this line as you progress: > Phase 1: Local Backend — [x] Complete. Smoke tested: health, auth, products, tables, orders, printer routing all working. -> Phase 2: Waiter PWA — [x] Complete. Built with React+Vite+PWA: Login/PIN, TableList, TableDetail, AddItems, Offline pages; all components wired to backend API; dark theme; vite build passes clean. +> Phase 2: Waiter PWA — [x] Complete. Smoke tested end-to-end: login, table list, open order, add items, select/pay with confirmation, close order. See "Phase 2 Known Issues & Fixes" below. > Phase 3: Manager Dashboard — [ ] Not Started > Phase 4: Cloud Backend — [ ] Not Started > Phase 5: Sysadmin Panel — [ ] Not Started +## Phase 2 Known Issues & Fixes Applied +- `OrderItemOut` schema now includes `product { id, name }` via `ProductNameOut` — required for item names to show correctly in the PWA. +- `OrderOut` schema now includes `waiters: List[OrderWaiterOut]` — required for `isMyOrder` check on the frontend. +- Close order button is enabled when there are zero active items (not just when all are paid) — allows closing an empty order. +- Printing silently skips items with no `printer_zone_id` — **expected**. Printer zones are assigned in Phase 3 (Manager Dashboard). No code change needed. +- `selected_options` and `removed_ingredients` on `OrderItemInput` accept `List[dict]` from the PWA (name+price_delta objects and name strings respectively), stored as JSON in the DB. The printer service reads them as raw JSON — modifier names print correctly. + +## Phase 2 Dev Data (seeded manually, not in seed.py) +- Tables 1–6 exist (table 1 was from Phase 1 smoke test) +- Category "food" (id=1) exists from Phase 1 smoke test — contains product "arakas" +- Categories: Ποτά, Σαλάτες, Κυρίως — 3 products each +- No printer zones assigned to any product yet + ## Environment Variables ### Local Backend (.env)