How chuduc2k5/oop works
This is a pharmacy commerce and back-office system: customers browse medicines, manage a cart, submit prescriptions when needed, place orders and pay by manual QR transfer; staff and administrators manage dispensing, payments, stock, sales and reporting. The documented runtime is Next.js → ASP.NET Core → SQLite. The graph preserves the documented capabilities, while edges for unsampled modules are limited to documented system boundaries or marked unverified; source-index references support the sampled service and controller relationships.
Main entry points: OrderService.cs Order and checkout · PharmacyDbContext.cs EF Core context · InventoryService.cs FEFO inventory · backoffice Back-office pages
Components 27
Web experience
- Next.js application
frontend/src/app - Cart and checkout
frontend/src/app/checkout/page.tsx - Prescription pages
frontend/src/app/prescriptions - Back-office pages
frontend/src/components/backoffice
API boundary
- ASP.NET API
backend/Pharmacy.Api/Program.cs - Accounts and auth
backend/Pharmacy.Api/Controllers/AuthController.cs - Drug catalog API
backend/Pharmacy.Api/Controllers/DrugsController.cs - Prescription API
backend/Pharmacy.Api/Controllers/PrescriptionsController.cs - Staff order API
backend/Pharmacy.Api/Controllers/StaffOrdersController.cs - Other API routes
backend/Pharmacy.Api/Controllers
Commerce workflows
- Account service
backend/Pharmacy.Core/Services/AccountService.cs - Product catalog
backend/Pharmacy.Core/Services/ProductService.cs - Cart service
backend/Pharmacy.Core/Services/CartService.cs - Order and checkout
backend/Pharmacy.Core/Services/OrderService.cs - Manual QR payments
backend/Pharmacy.Core/Services/ManualPaymentService.cs - Prescription workflow
backend/Pharmacy.Core/Services/PrescriptionService.cs
Pharmacy operations
- FEFO inventory
backend/Pharmacy.Core/Services/InventoryService.cs - Inventory reader
backend/Pharmacy.Core/Services/InventoryReader.cs - Counter sales
backend/Pharmacy.Core/Services/SaleService.cs - Invoices
backend/Pharmacy.Core/Services/InvoiceService.cs - Inventory reports
backend/Pharmacy.Core/Services/InventoryReportService.cs - Dashboard
backend/Pharmacy.Core/Services/DashboardService.cs
Domain and persistence
- Pharmacy domain
backend/Pharmacy.Core/Domain - EF Core context
backend/Pharmacy.Core/Data/PharmacyDbContext.cs - Relational database
Other components
- Customer
- Staff / admin
Connections 40
- Customer → Next.js application: uses
README.md - Staff / admin → Next.js application: uses
README.md - Next.js application → ASP.NET API: rewrites API calls
README.md - Customer → Cart and checkout: shops
- Customer → Prescription pages: submits prescriptions
README.md - Staff / admin → Back-office pages: operates pharmacy
README.md - Accounts and auth → Account service: calls
backend/Pharmacy.Api/Controllers/AuthController.cs - Drug catalog API → Product catalog: calls
backend/Pharmacy.Api/Controllers/DrugsController.cs - Drug catalog API → FEFO inventory: calls
backend/Pharmacy.Api/Controllers/DrugsController.cs - Prescription API → Prescription workflow: calls
backend/Pharmacy.Api/Controllers/PrescriptionsController.cs - Staff order API → Order and checkout: calls
backend/Pharmacy.Api/Controllers/StaffOrdersController.cs - Staff order API → Cart service: calls
backend/Pharmacy.Api/Controllers/StaffOrdersController.cs - Cart service → Inventory reader: reads availability
backend/Pharmacy.Core/Services/CartService.cs - Cart service → FEFO inventory: checks stock
backend/Pharmacy.Core/Services/CartService.cs - Order and checkout → Cart service: uses cart data
backend/Pharmacy.Core/Services/OrderService.cs - Order and checkout → Prescription workflow: checks quota
backend/Pharmacy.Core/Services/OrderService.cs - Order and checkout → Inventory reader: reads stock
backend/Pharmacy.Core/Services/OrderService.cs - Order and checkout → FEFO inventory: reserves stock
backend/Pharmacy.Core/Services/OrderService.cs - Prescription API → Prescription workflow: manages review
backend/Pharmacy.Core/Services/PrescriptionService.cs - ASP.NET API → Account service: registers service
backend/Pharmacy.Api/Program.cs - ASP.NET API → FEFO inventory: registers service
backend/Pharmacy.Api/Program.cs - ASP.NET API → Prescription workflow: registers service
backend/Pharmacy.Api/Program.cs - ASP.NET API → Order and checkout: registers service
backend/Pharmacy.Api/Program.cs - Cart and checkout → Order and checkout: places orders
- Order and checkout → Manual QR payments: payment workflow
- Back-office pages → Counter sales: records counter sales
- Back-office pages → FEFO inventory: manages batches
- Back-office pages → Invoices: views invoices
- Back-office pages → Inventory reports: views reports
- Back-office pages → Dashboard: views summary
- Order and checkout → Invoices: invoice workflow
- FEFO inventory → Inventory reader: uses reader
backend/Pharmacy.Core/Services/InventoryService.cs - Product catalog → EF Core context: queries catalog
- Inventory reader → EF Core context: reads stock
backend/Pharmacy.Core/Services/InventoryReader.cs - FEFO inventory → EF Core context: writes stock
backend/Pharmacy.Core/Services/InventoryService.cs - Order and checkout → EF Core context: persists orders
backend/Pharmacy.Core/Services/OrderService.cs - Prescription workflow → EF Core context: persists prescriptions
backend/Pharmacy.Core/Services/PrescriptionService.cs - Account service → EF Core context: persists accounts
backend/Pharmacy.Core/Services/AccountService.cs - EF Core context → Pharmacy domain: maps entities
backend/Pharmacy.Core/Data/PharmacyDbContext.cs - EF Core context → Relational database: reads and writes
README.md