Mandi Khata: a digital ledger for commission agents
We rebuilt a fish market commission agent’s paper ledger as a web application where every balance is derived from entries rather than typed – a wrong total cannot be saved at all.

Starting point
In a Pakistani fish market a commission agent sells goods on behalf of suppliers and keeps a commission. Almost every buyer takes the goods on credit, so the business runs on knowing who owes whom. That record is a paper ledger: it cannot be searched, cannot be totalled without adding it up by hand, and is gone if the book is gone.
Solution
Every sale and cash movement is entered once; every balance, day total and report is derived from those entries. Money is stored as whole paisa and weight as whole grams, so no rounding error accumulates. The money identity (gross = commission + expenses + payout) is enforced as a database constraint, so an incorrect calculation cannot be saved. Nothing is ever deleted: a correction inserts a reversing entry and the original stays visible, struck through, like a line drawn in a paper ledger.
Implementation
React 19 with Vite and Tailwind on the front end, Supabase with Postgres as the backend. Two roles (owner, staff) are enforced in four layers, ending at row-level security in Postgres. The interface is available in English and Urdu with full right-to-left layout. Per-shop data isolation was proven by running two separate accounts against the same tables.
Workflow
How the data flows
- Sale / paymententered once
- Constraintmoney identity in Postgres
- Day bookfilterable, totalled
- Ledgersrunning balance per party
- Reportsowner only
Screens
Screenshots & mockups
Results
What changed
English + Urdu (RTL)
Languages
Verified result4 layers down to row-level security
Role enforcement
Verified resultProjects
Similar projects

Pharmacy, United Kingdom · Healthcare & pharmacy
Profit & loss web app for a pharmacy
A custom web application that lets a pharmacy record income and costs and see an up-to-date profit and loss statement at any time.

EchtSquad internal tool · Software & internal tools
Desktop command center for cold email campaigns
A desktop application we use to manage cold email campaigns, sending accounts and leads in bulk instead of jumping between dashboards.

Travel services provider · Travel & tourism
Service website for the Thailand arrival card
A service website with a guided form and built-in payment flow that helps travellers complete their Thailand arrival card.
Intro call
Something similar in mind? Let’s talk.
In a free intro call we clarify what you need, what it costs and when it will be done. No sales pressure.