Hybrid Distributed POS — Offline-First Point of Sale
- Laravel
- Vue.js
- IndexedDB
- WebSocket
- Capacitor
- Bootstrap
- WhatsApp API
- REST API
The problem: branch cashiers kept losing transactions on unstable mobile networks, while management needed centralized real-time data.
The approach is offline-first. Product catalogs, active cashier shifts, and transaction tables are cached locally in IndexedDB via Dexie.js, so cashiers never stop serving. Synchronization uses a non-destructive upsert topology: delayed offline receipts are pushed to the Laravel cloud while pulling remote database state, eliminating double entries and data loss.
- Daily shift closing uses double-key fallback logic to combine local and cloud revenue states.
- Transaction voiding is gated behind a 6-digit OTP delivered to owners via WhatsApp, preventing cashier-side fraud.
- Thermal receipt printing over Bluetooth on a Capacitor wrapper, plus automatic petty cash approval over WebSocket.