Files
mercadodevida/work/artifacts/POS-FIX-1/implementer.md
chattie 18a518e58b F-201 F-202 F-203: POS cash close report + email + PIN admin
F-201: GET /pos/reports/cash-close/:id with financial summary, sales
  by state, payments breakdown, items sold. Extended /pos/sessions/:id.

F-202: Cash close email sent on session close to smtpReportEmail
  (best-effort). smtpReportEmail field added to admin SMTP settings.

F-203: Admin POS terminal config: selfpayMode, closeSessionRequiresPin,
  closeSessionPin (4-6 digits) with dedicated settings section.
2026-08-23 09:24:37 +02:00

438 B

POS-FIX-1 — Add explicit return transitions to POS order state machine

Fix

Added COMPLETED→REFUNDED and COMPLETED→PARTIALLY_REFUNDED to ALLOWED_TRANSITIONS. Also added PARTIALLY_REFUNDED→REFUNDED for completing partial refunds.

Files changed

  • src/modules/orders/domain/order.ts (ALLOWED_TRANSITIONS)
  • src/modules/orders/tests/order-state-machine.test.ts

Verification

  • npm test: 271 passed
  • tsc POS app: 0 errors