How huobin1202/e-mart-c- works
Staff E-commerce is a retail operations and online-store system: staff use a protected dashboard for catalog, inventory, orders, point of sale, promotions, purchasing, customers, and reporting; shoppers browse and order through a separate customer app. Backend controllers expose these business capabilities, with services and repositories separating rules from persistence. The excerpts establish routing, selected controller/service and repository/data-layer relationships, and the product data model. The README is empty and most modules are unsampled, so uncertain client-to-server links are shown as unverified rather than asserted.
Main entry points: AppDbContext.cs Commerce database · apiClient.js API client · Order.cs Order model · ProductsController.cs Product catalog
Components 33
Staff operations
- Staff dashboard
Staff-E-commerce-main/frontend/src/App.jsx - API client
Staff-E-commerce-main/frontend/src/api/apiClient.js
Customer storefront
- Customer app
Staff-E-commerce-main/customer-app/src/App.jsx - Storefront API
Staff-E-commerce-main/customer-app/src/services/storefrontApi.js
Commerce API
- Product catalog
Staff-E-commerce-main/backend/Controllers/ProductsController.cs - Promotion management
Staff-E-commerce-main/backend/Controllers/PromotionsController.cs - Storefront orders
Staff-E-commerce-main/backend/Controllers/StorefrontController.cs - Reports
Staff-E-commerce-main/backend/Controllers/ReportsController.cs - Operations endpoints
Staff-E-commerce-main/backend/Controllers - Product categories
Staff-E-commerce-main/backend/Controllers/CategoriesController.cs - Customer records
Staff-E-commerce-main/backend/Controllers/CustomerController.cs - Inventory control
Staff-E-commerce-main/backend/Controllers/InventoryController.cs - Order processing
Staff-E-commerce-main/backend/Controllers/OrdersController.cs - Payments
Staff-E-commerce-main/backend/Controllers/PaymentController.cs - Purchase orders
Staff-E-commerce-main/backend/Controllers/PurchaseOrdersController.cs - Bulk import
Staff-E-commerce-main/backend/Controllers/ImportController.cs - Invoices
Staff-E-commerce-main/backend/Controllers/InvoiceController.cs - Statistics
Staff-E-commerce-main/backend/Controllers/StatisticsController.cs
Business and persistence
- Product service
Staff-E-commerce-main/backend/Services/ProductService.cs - Promotion rules
Staff-E-commerce-main/backend/Services/PromotionService.cs - Reports service
Staff-E-commerce-main/backend/Services/ReportsService.cs - Product repository
Staff-E-commerce-main/backend/Repository/ProductRepository.cs - Commerce database
Staff-E-commerce-main/backend/Data/AppDbContext.cs - Product model
Staff-E-commerce-main/backend/Models/Product.cs - Order model
Staff-E-commerce-main/backend/Models/Order.cs - Customer model
Staff-E-commerce-main/backend/Models/Customer.cs - Promotion model
Staff-E-commerce-main/backend/Models/Promotion.cs - Inventory model
Staff-E-commerce-main/backend/Models/Inventory.cs - Category model
Staff-E-commerce-main/backend/Models/Category.cs - User model
Staff-E-commerce-main/backend/Models/User.cs - Date rules
Staff-E-commerce-main/backend/Helpers/DateTimeHelper.cs
Other components
- Staff user
- Online shopper
Connections 31
- Staff user → Staff dashboard: uses
Staff-E-commerce-main/frontend/src/App.jsx - Staff dashboard → API client: requests data
- Online shopper → Customer app: shops with
- Customer app → Storefront API: uses
- Storefront API → Storefront orders: calls
- API client → Product catalog: calls API
- API client → Promotion management: calls API
- API client → Reports: calls API
- Product catalog → Product service: delegates to
Staff-E-commerce-main/backend/Controllers/ProductsController.cs - Promotion management → Promotion rules: delegates to
Staff-E-commerce-main/backend/Controllers/PromotionsController.cs - Reports → Reports service: delegates to
Staff-E-commerce-main/backend/Controllers/ReportsController.cs - Product service → Product repository: uses
Staff-E-commerce-main/backend/Services/ProductService.cs - Promotion rules → Date rules: uses dates
Staff-E-commerce-main/backend/Services/PromotionService.cs - Promotion rules → Promotion model: maps and validates
Staff-E-commerce-main/backend/Services/PromotionService.cs - Product repository → Commerce database: queries and saves
Staff-E-commerce-main/backend/Repository/ProductRepository.cs - Commerce database → Product model: maps entities
Staff-E-commerce-main/backend/Data/AppDbContext.cs - Commerce database → Order model: maps entities
Staff-E-commerce-main/backend/Data/AppDbContext.cs - Commerce database → Customer model: maps entities
Staff-E-commerce-main/backend/Data/AppDbContext.cs - Commerce database → Promotion model: maps entities
Staff-E-commerce-main/backend/Data/AppDbContext.cs - Commerce database → Inventory model: maps entities
Staff-E-commerce-main/backend/Data/AppDbContext.cs - Commerce database → Category model: maps entities
Staff-E-commerce-main/backend/Data/AppDbContext.cs - Commerce database → User model: maps entities
Staff-E-commerce-main/backend/Data/AppDbContext.cs - Product catalog → Product categories: serves catalog
- Customer records → Customer model: manages
- Inventory control → Inventory model: manages
- Order processing → Order model: manages
- Payments → Order model: handles order payments
- Purchase orders → Inventory model: supports replenishment
- Bulk import → Product repository: imports catalog data
- Invoices → Order model: invoices orders
- Statistics → Reports service: provides metrics