How jeinciong/automotive-spare-parts-dss-thesis works
This repository implements a sales and inventory management application with forecasting and business reporting. Users sign in, navigate operational views, and manage inventory, sales, suppliers, notifications, and forecasts; frontend contexts fetch and update data through the backend API. Forecasting also has Python model modules for demand classification and revenue prediction. The README is empty, so capability coverage is based on the source tree and sampled frontend references; backend internals and some unsampled view interactions are not detailed here.
Main entry points: App.tsx Application Shell · SalesReportsContext.tsx Sales Report State · api.ts API URL Client · ForecastContext.tsx Forecast State
Components 21
Application Shell
- Application Shell
frontend/src/App.tsx - Sign In
frontend/src/components/LoginPage.tsx - Navigation
frontend/src/components/AppSidebar.tsx
Business Operations
- Inventory View
frontend/src/components/views/InventoryView.tsx - Inventory State
frontend/src/contexts/InventoryContext.tsx - Supplier Management
frontend/src/components/views/SuppliersView.tsx - Supplier State
frontend/src/contexts/SuppliersContext.tsx - Notifications
frontend/src/contexts/NotificationContext.tsx
Reporting And Forecasting
- Sales Reports View
frontend/src/components/views/SalesReportsView.tsx - Sales Report State
frontend/src/contexts/SalesReportsContext.tsx - Dashboard
frontend/src/components/views/DashboardView.tsx - Analytics
frontend/src/components/views/AnalyticsView.tsx - Forecast View
frontend/src/components/views/PredictionsTrendsView.tsx - Recommendations
frontend/src/components/views/RecommendationsView.tsx - Forecast State
frontend/src/contexts/ForecastContext.tsx
Data Services
- API URL Client
frontend/src/lib/api.ts - Backend API
backend/server.ts - ARIMA XGBoost
backend/python/models/arima_xgb_model.py - TSB XGBoost
backend/python/models/tsb_xgb_model.py - Demand Classifier
backend/python/utils/demand_classifier.py
Other components
- Business User
Connections 26
- Business User → Sign In: signs in
- Sign In → Application Shell: authenticates into
frontend/src/App.tsx - Application Shell → Navigation: renders
frontend/src/App.tsx - Application Shell → Inventory State: provides state
frontend/src/App.tsx - Application Shell → Supplier State: provides state
frontend/src/App.tsx - Application Shell → Sales Report State: provides state
frontend/src/App.tsx - Application Shell → Forecast State: provides state
frontend/src/App.tsx - Application Shell → Notifications: provides state
frontend/src/App.tsx - Application Shell → Sales Reports View: renders
frontend/src/App.tsx - Application Shell → Forecast View: renders
frontend/src/App.tsx - Application Shell → Recommendations: renders
frontend/src/App.tsx - Application Shell → Inventory View: renders
frontend/src/App.tsx - Application Shell → Dashboard: renders
frontend/src/App.tsx - Sales Reports View → Sales Report State: uses reports
frontend/src/components/views/SalesReportsView.tsx - Inventory View → Inventory State: uses inventory
frontend/src/components/views/InventoryView.tsx - Inventory View → Supplier State: uses suppliers
frontend/src/components/views/InventoryView.tsx - Forecast View → Forecast State: uses forecasts
frontend/src/components/views/PredictionsTrendsView.tsx - Forecast State → Sales Report State: reads sales
frontend/src/contexts/ForecastContext.tsx - Sales Report State → Inventory State: uses inventory
frontend/src/contexts/SalesReportsContext.tsx - Inventory State → API URL Client: builds API requests
frontend/src/contexts/InventoryContext.tsx - Sales Report State → API URL Client: builds API requests
frontend/src/contexts/SalesReportsContext.tsx - Forecast State → API URL Client: builds API requests
frontend/src/contexts/ForecastContext.tsx - Supplier State → API URL Client: uses API URL
frontend/src/contexts/SuppliersContext.tsx - API URL Client → Backend API: targets API
- ARIMA XGBoost → ARIMA XGBoost: fits and forecasts
backend/python/models/arima_xgb_model.py - Demand Classifier → ARIMA XGBoost: classifies demand