Case / 06 of 07
Ashirwad
A restaurant shouldn’t need a marketplace to run its own orders.
Context
Ashirwad Hotel & Restaurant: a food ordering system with a customer application and an operational backend for the restaurant.
Customers order food, track deliveries and pay online while the restaurant manages orders, riders, promotions and operations.
System
Customer app · React NativeAdmin console · React
NestJS APISocket.io
MySQL
RazorpayExpo PushFirebaseS3
What I built
- Order management
- Cart
- Payments
- Wallet
- Coupons
- Referrals
- Rider management
- Notifications
- Admin console
- Kitchen printing
- Live order updates
The hard part
An order is being watched by several people at once.
Kitchen. Rider. Customer.
Instead of simply replacing the status, changes are recorded and pushed to the relevant surfaces in real time.
Engineering decisions
- 01
Record status changes, don’t overwrite them.
Every transition is kept, so each surface can reason about what happened.
- 02
Push, don’t poll.
Socket.io delivers changes to the kitchen, rider and customer as they happen.
- 03
Reconcile the money paths.
Payments, wallet, referrals and refunds have to agree with each other.
Shipped
- Google Play
- Admin console
- Kitchen printing
- Live order tracking
Stack
- React
- Material UI
- Redux Toolkit
- React Native
- Expo
- NestJS
- MySQL
- TypeORM
- Socket.io
Integrations
- Razorpay
- Expo Push
- Firebase
- AWS S3
- Textlocal
- Nodemailer