Mazari ERP
SaaS ERP for a shoe-store operation with inventory, sales, purchases, finance and reports.
Model
SaaS ERP
Tenancy
Multi-company
Scope
Multi-branch
Problem
A shoe business with several branches needs precise stock visibility, sales control, cash sessions, accounts receivable/payable and branch-aware reporting without mixing data between companies.
Contribution
Designed and built a TypeScript monorepo with Next.js, Express, PostgreSQL and Drizzle, using opaque HttpOnly-cookie sessions, tenant-aware repositories, role permissions and module-based frontend architecture.
Key points
Multi-tenant model with company and branch context carried from the authenticated session.
Inventory flows for shoe attributes such as size, color, brand, category and style, including transfers and low-stock states.
Finance modules for sales, purchases, cash sessions, receivables, payables, payroll, expenses and PDF-ready reports.
How it is built
Shared-database, shared-schema multi-tenancy using company and branch identifiers from the session.
Backend modules are organized by use-cases, repositories, validators, controllers and routes.
Frontend uses TanStack Query, Zustand, shared resource tables and module-specific domain schemas.