How parama-2004/smart-billing-solution works
Billing Suite is a desktop billing application with a React operational UI, a .NET Minimal API, and a MySQL-backed data layer. Users authenticate, operate sales and purchasing workflows, manage master data and payments, then review reports and tally records; the API also supports maintenance tasks. The graph preserves documented product capabilities, while sampled source confirms selected route-to-service and service-to-data relationships. Several UI-to-API and desktop-host links are documented only at product level, so those are marked unverified.
Main entry points: App.tsx UI routes · Program.cs API startup · BillingDbContext.cs EF data context · PurchaseService.cs Purchase processing
Components 24
Desktop runtime
- Electron host
electron/main.js
Operations UI
- UI routes
billing-ui/src/App.tsx - Login and session
billing-ui/src/pages/Login.tsx - Sales screens
billing-ui/src/pages/invoices/CreateInvoice.tsx - Purchase screens
billing-ui/src/pages/Purchase/PurchaseEntry.tsx - Master screens
billing-ui/src/pages/products/ProductMaster.tsx - Reports and tally
billing-ui/src/pages/Reports/SalesReport.tsx - Receipt rendering
billing-ui/src/components/Receipt80mm.tsx
Billing workflows
- Invoice endpoints
Billing.Api/Routes/InvoiceRoutes.cs - Invoice processing
Billing.Api/Services/InvoiceService.cs - Purchase endpoints
Billing.Api/Routes/PurchaseRoutes.cs - Purchase processing
Billing.Api/Services/PurchaseService.cs - Payments and refunds
Billing.Api/Routes/PaymentRoutes.cs
API and domain
- Authentication endpoints
Billing.Api/Routes/AuthRoutes.cs - JWT generation
Billing.Api/Security/JwtService.cs - Customer ledger
Billing.Api/Services/CustomerService.cs - Sales and VAT reports
Billing.Api/Services/SalesReportService.cs - API startup
Billing.Api/Program.cs - Backup and reset
Billing.Api/Routes/MaintenanceRoutes.cs - Product and master APIs
Billing.Api/Routes/MasterRoutes.cs - Daily tally and cheques
Billing.Api/Routes/DailyTallyRoutes.cs
Persistence
- EF data context
Billing.Api/Data/BillingDbContext.cs - MySQL database
Other components
- Staff user
Connections 25
- Staff user → UI routes: uses
- UI routes → Login and session: routes to
billing-ui/src/App.tsx - UI routes → Sales screens: routes to
billing-ui/src/App.tsx - UI routes → Purchase screens: routes to
billing-ui/src/App.tsx - UI routes → Master screens: routes to
billing-ui/src/App.tsx - UI routes → Reports and tally: routes to
billing-ui/src/App.tsx - Sales screens → Receipt rendering: previews bill
- Electron host → UI routes: hosts
- Electron host → API startup: starts packaged API
- UI routes → API startup: uses API
- API startup → EF data context: configures
Billing.Api/Program.cs - API startup → MySQL database: configures MySQL
Billing.Api/Program.cs - Invoice endpoints → Invoice processing: calls
Billing.Api/Routes/InvoiceRoutes.cs - Invoice processing → EF data context: reads and writes
Billing.Api/Services/InvoiceService.cs - Purchase endpoints → Purchase processing: calls
Billing.Api/Routes/PurchaseRoutes.cs - Purchase processing → EF data context: reads and writes
Billing.Api/Services/PurchaseService.cs - Purchase processing → Purchase processing: updates product stock
Billing.Api/Services/PurchaseService.cs - Customer ledger → EF data context: queries ledger data
Billing.Api/Services/CustomerService.cs - Sales and VAT reports → EF data context: queries
Billing.Api/Services/SalesReportService.cs - Authentication endpoints → JWT generation: generates token
Billing.Api/Routes/AuthRoutes.cs - JWT generation → API startup: validates via configured auth
- Master screens → Product and master APIs: uses master services
- Sales screens → Payments and refunds: uses transaction endpoints
- Reports and tally → Daily tally and cheques: uses tally endpoints
- API startup → Backup and reset: hosts maintenance routes