Case study — 01 / 27
Offline-First Ticketing & POS System
Modern ferry ticketing and point-of-sale platform with offline-first reliability.
- Category
- Systems
- Engagement
- Freelance Developer Group
- Year
- 2024
- Core stack
- Vue 3, Node.js, PWA
Overview
An offline-first Progressive Web App and mobile solution for ferry ticketing, POS operations, and real-time vessel management with cloud synchronization.
Built with Vue 3 and Quasar Framework, this platform supports ticket sales even without internet connectivity and syncs data automatically when the connection returns.
The system combines offline-capable POS terminals with a cloud-backed sync engine. It includes QR code ticketing, vessel scheduling, fare management, and secure multi-role access controls. The platform runs as both a PWA and an Android WebView APK for mobile terminals.
Role & contribution
Enabled continuous ferry operations through an offline-first architecture, keeping ticketing and transactions running even during network disruptions.
- 01Developed an offline-first ferry ticketing and point-of-sale (POS) platform with automatic background synchronisation.
- 02Built QR code ticket generation and boarding verification modules for passenger management.
- 03Implemented real-time vessel scheduling and management features.
- 04Created role-based access controls for administrators, cashiers and scanners.
- 05Designed and optimised a responsive Progressive Web App (PWA) with Android APK support through WebView deployment.
- 06Integrated cloud synchronisation to keep data consistent across terminals.
- 07Kept ticket sales and validation running during internet outages.
Key features
- 01
Offline-First Architecture
Full POS functionality without internet connectivity using LocalForage and service workers.
- 02
Cloud Synchronization
Automatic background sync with timestamp-based conflict merging when network access returns.
- 03
QR Code Ticketing
Generate and scan QR boarding passes for fast passenger validation.
- 04
Role-Based Access
Secure JWT authentication with Admin, Cashier, and Scanner roles.
- 05
Real-Time Dashboard
Interactive business intelligence dashboard with live sales and vessel performance metrics.
- 06
Mobile PWA + APK
Runs as a Progressive Web App or Android WebView APK with extended caching strategies.
Core modules
- Point-of-Sale Terminal
- Intuitive POS interface for selling tickets, managing fare types, cart creation, and instant QR boarding pass generation.
- Dashboard & Analytics
- Real-time sales metrics, passenger counts, vessel statuses, and financial summaries with Chart.js visualizations.
- Scanner & Verification
- QR code scanner for passenger verification, offline validation, and boarding gate checks.
- Admin Panel - Vessel Management
- Vessel registration, route assignments, scheduling, and vessel history tracking.
- Admin Panel - User Management
- User account creation, role assignment, permission controls, and login audit logs.
- Admin Panel - Routes & Fares
- Route configuration, origin/destination management, and dynamic fare matrix setup.
- Reports & Export
- Filtering, date range reporting, and export capabilities for financial and operational analysis.
- Sync API Backend
- Node.js/Express backend with authentication, health probes, and sync endpoints for offline-ready terminals.
Architecture
- Architecture Type
- PWA with offline-first service workers and a RESTful Node.js backend.
- Database Design
- MySQL relational database with versioned migrations and offline LocalForage persistence.
- Security Features
- JWT auth, bcrypt password hashing, CORS protection, rate limiting, and input sanitization.
- Deployment
- Frontend deployed as PWA and APK, backend on Node.js with health probes and monitoring.
- State Management
- Pinia stores for auth, transactions, vessels, fares, users, and sync queue logic.
Challenges & solutions
- 01
Offline Data Persistence
Implemented LocalForage for IndexedDB storage and Pinia state management so POS operations continue uninterrupted offline.
- 02
Data Synchronization Conflicts
Built a server-authoritative sync engine with timestamp-based merging to handle offline terminal conflicts.
- 03
Mobile APK Offline Performance
Used Workbox caching strategies and APK WebView settings for fast loading and reliable offline behavior.
- 04
Real-Time QR Code Generation & Scanning
Integrated qrcode and jsQR libraries for instant ticket generation and camera-based scanning.
- 05
UI Consistency Across Components
Designed an SCSS system with semantic tokens and an 8px spacing scale for consistent interface layouts.
- 06
Production Security & Monitoring
Implemented JWT auth, bcrypt hashing, rate limiting, health checks, and monitoring endpoints.
Outcomes & impact
Zero Downtime Operations
Ferry operations remain uninterrupted during internet outages, with automatic sync once the network is restored.
Improved Transaction Speed
POS transactions complete in under 3 seconds, including QR code ticket generation.
Comprehensive Design System
Standardized SCSS patterns reduced development time and improved design consistency.
Multi-Platform Deployment
Delivered as both a PWA and Android APK for flexible terminal deployment.
Scalable Backend Architecture
Node.js API with connection pooling and rate limiting supports multiple concurrent terminals.
Enhanced Security
Role-based JWT authentication and audit logging provide secure operations and accountability.
Real-Time Business Intelligence
Dashboard insights improve operational visibility and decision making.
Developer-Friendly Documentation
Detailed guides and runbooks enable faster maintenance and onboarding.
Roadmap
Phase 1 - Core FoundationShipped
- Quasar and Vue 3 project setup
- PWA configuration with service workers
- User authentication and JWT security
- Basic POS interface with cart flows
- Offline storage using LocalForage
- Database schema and migration setup
Phase 2 - POS & TicketingShipped
- Complete POS terminal with fare calculations
- QR code generation and scanning
- Passenger type and vessel selection
- Receipt generation and transaction logging
- Dashboard with sales overview
Phase 3 - Admin & SyncShipped
- Vessel, route, and fare admin panels
- Role-based user management
- Offline sync API backend with Express
- Conflict resolution and background sync
- Login logs and audit tracing
Phase 4 - Analytics & PolishShipped
- Advanced dashboard visualizations
- Comprehensive report filtering
- Design system implementation
- Mobile optimization and APK build
- Monitoring and health probes
Phase 5 - Production & DeploymentShipped
- Production environment hardening
- Rate limiting and security controls
- Metrics and monitoring endpoints
- Live deployment and APK distribution
- Developer documentation and runbooks
Tech stack
- Vue 3
- Quasar Framework
- Vite
- Pinia
- Node.js
- Express.js
- MySQL2
- LocalForage
- Workbox
- Chart.js
- JWT Authentication
- Bcrypt.js
- QRCode
- jsQR
- Axios
- Day.js
- SCSS/PostCSS