Web Applications · Commerce
Rice and Spice Pre-order Platform
A customer pre-order site and staff admin console where the database, not the browser, decides prices and availability.
- Status
- Prototype
- Year
- 2026
- Role
- Designer and developer
- Client
- Independent project
01
Overview
A Supabase-backed site where a Postgres function places each order: it re-prices every line from the catalogue and checks cut-off, notice, blackout dates, capacity and coupons. Row-level security limits what each staff role can read and do.
- React
- TypeScript
- Supabase
- PostgreSQL
- Zod
02
The challenge
A food business taking pre-orders for set delivery days needs to enforce cut-off times, capacity and pricing without trusting what the browser sends.
- Keeping capacity correct when several customers order for the same day at once
03
System requirements
- Pre-order checkout with delivery windows, zones and coupons
- Private tracking token, so only the customer can look up their order
- Staff roles (owner, manager, kitchen, delivery) with different permissions
- Order status changes through functions that enforce the state machine and the caller's role
- Unit tests for scheduling, pricing, the state machine and analytics
- Browser end-to-end tests against a real test database, guarded against accidental data resets
- Automated deploy of the front end to GitHub Pages
04
Solution architecture
Responsibility
Customer site
Menu, ordering and order tracking, served as a client-rendered app.
05
Implementation
Content needed: real screenshots (desktop and mobile). Generated mockups are never shown as screenshots.
06
Technical decisions
- The database is the authority: the browser never supplies a price
- A per-delivery-date lock so two customers cannot take the last slot
- Only staff can read orders, coupons, the audit log or the staff list
07
Results and validation
Content needed: measured results with period and method. Never estimated.
Evidence
- Public repository with an architecture and permissions write-up
- Documented list of what is not done yet, including payments and rate limiting
08
Lessons learned
Content needed: what you would do differently
Content checklist (remove once filled)
- Live URL and whether real customers have ordered
- Online payments, automatic messaging and per-IP rate limiting are not built yet. Do not claim them
- Real screenshots of the customer site and the admin console
- Any results, only with a period and method
09