← All tests

R1.3 — Lockable POS shell + PIN unlock + beginning cash LOCAL

2026-04-21. Third cycle of R1 (NIX-OS-67 Phase 3 POS): a new fullscreen route /cafe/pos/register/[configId] opens in its own tab from the landing. Three-phase state machine: Locked (PIN keypad) → PreShift (beginning cash count) → Open (register UI). PIN verified via PBKDF2 hash from R1.1; active cashier rides a signed nix_active_cashier JWT cookie separate from the web session. New server actions: unlockRegister, openShift, lockRegister, closeShift. NIX cafe.sessions rows are created on cash-count confirm and mirror Odoo pos.session.

4/4 local Gate 1 checks passed. Verified: active-cashier cookie sign/verify round-trip with the shared JWT_SECRET; cafe.sessions DAO create → get → attach Odoo session id → close (7 assertions); both new fullscreen route and old landing return 307 cleanly unauthed (no SSR crashes from the route group restructure).
Gate 2 (prod) captures the three visual phases. Local can't run the authed click-through (no Commerce SSO on localhost), so the Locked / PreShift / Open screens will be screenshotted at Gate 2 on get-coffee.nixtech.app. A test cashier was left from R1.1; we'll reset its PIN, unlock the new-tab shell with it, enter a beginning cash amount, and verify the Register loads.

01Unit — active-cashier JWT cookie✓ 3 assertions

02DAO — cafe.sessions lifecycle✓ 7 assertions

Loading…

03What Gate 2 will exercise on prod

  1. Prod migration re-run (idempotent) — cafe.sessions already landed in R1.2.
  2. Sign in as owner on get-coffee.nixtech.app.
  3. Reset the test cashier's PIN from R1.1 to something known, then close that tab.
  4. /cafe/pos → click a register card → new tab opens at /cafe/pos/register/[configId].
  5. Lock screen renders (no sidebar, centered PIN keypad).
  6. Tap the digits + Unlock → PreShift dialog with the cashier's name.
  7. Enter beginning cash → Open Shift → Register UI renders with the cashier name in the top bar.
  8. Click Lock → returns to Lock screen, cookie cleared, session stays open in DB.
  9. Re-enter PIN → skips PreShift, goes straight to Register (resume path).
  10. Click Close shift → confirms → tab returns to Lock screen, NIX row state='closed' in DB.
  11. Regression sweep: 33/33 on phase1 + m1 + phase2-sso + phase2-cafe. R1.1 Cashier UI still works. R1.2 landing still works.