Ahmad HassanFull-Stack AI Engineer
WorkDecisionsStackExperienceContactWriting
Hire me
Ahmad HassanLahore, Pakistan
EmailWhatsAppLinkedInGitHub
© 2026 Ahmad Hassan · Full-Stack AI Engineer in Lahore
Selected workEasyQuranAriaRetrivo VaultLeadForge AIRetailFlowNoteMindFitMind AIThe Copper LarderMindScribeSpendSmartFitTrack
Ahmad Hassan/Work/RetailFlow05 of 11

Multi-tenant retail SaaS

RetailFlow

Retail software for shops that trade on khata.

Role
Solo · design, build and ship
Focus
Web · Product
Live demo ↗GitHub repository ↗
231231
tests
3535
tables
9292
migrations
2222
permissions

Overview

A multi-tenant POS, inventory and credit-ledger platform for South Asian shops — barcode billing, weighted-average costing, khata credit ledgers and shift reconciliation, on a Postgres schema where every tenant is isolated by Row Level Security and every rupee is an integer.

What it does

  • Barcode billing with mixed payment on one bill — cash, khata and JazzCash/Easypaisa
  • Shifts with declared float and expected-vs-actual variance, reconciled to the paisa
  • Multi-unit inventory (carton → packet → piece) with Urdu product names
  • Partial goods receipt and a weighted-average costing engine with historical cost snapshots
  • Khata ledgers with DB-enforced credit limits and aging buckets
  • Owner / manager / cashier roles over 22 permissions, with PIN counter hand-off

Engineering decisions

01

Money is never a float

Every amount is stored as an integer and the cash drawer reconciles to the paisa before anyone goes home.

02

One RPC, one transaction

A sale lands completely — stock, money, ledger, invoice number — or not at all. The drawer and the shelf can never disagree.

03

Tenants isolated by the database

SELECT-only RLS for clients and no client write policy on any financial table; writes go through permission-checked RPCs.

Stack

App
Next.js 15React 19 Server ComponentsTypeScript (strict)Tailwind
Data
Supabase PostgresRow Level Security41 RPCs
Ops
56 API routesResendWhatsApp Cloud API
Next projectNoteMind →Notes that think with you.