How sivasabariganesan/odoo-x-gcet-stock-sense works
StockSense is a multi-warehouse inventory platform. Users work through a React SPA and authenticated API to manage product and location data, receive and deliver goods, transfer stock, adjust counts, and inspect balances and movement history. The README describes atomic inventory transactions and an immutable ledger, plus dashboard, AI, email, and real-time capabilities. Sampled routes confirm several API-to-service calls; unsampled service internals and frontend API wiring limit finer-grained links.
Main entry points: index.ts Hono server · client.ts Drizzle database · App.tsx React SPA · index.tsx App routes
Components 23
User application
- React SPA
frontend/src/app/App.tsx - App routes
frontend/src/app/router/index.tsx - Feature screens
frontend/src/features - API client
frontend/src/lib/apiClient.ts
Inventory operations
- Receipt processing
backend/src/modules/receipts/processing.service.ts - Delivery processing
backend/src/modules/deliveries/processing.service.ts - Internal transfers
backend/src/modules/transfers/service.ts - Inventory adjustments
backend/src/modules/adjustments/service.ts - Stock balances
backend/src/modules/stock-balances/service.ts - Movement ledger
backend/src/modules/stock-movements/service.ts
Platform services
- Hono server
backend/src/server/index.ts - Auth service
backend/src/modules/auth/service.ts - Auth routes
backend/src/modules/auth/route.ts - Dashboard
backend/src/modules/dashboard/service.ts - AI assistant
backend/src/modules/ai/orchestrator.ts - WebSocket pub/sub
backend/src/modules/websocket - Metrics
backend/src/lib/metrics.ts
Data layer
- Drizzle database
backend/src/db/client.ts - Inventory tables
backend/src/db/schema/index.ts
External systems
- PostgreSQL
- Groq API
- SMTP mail
Other components
- Operator
Connections 27
- Operator → React SPA: uses
- React SPA → App routes: renders
- App routes → Feature screens: routes to
- Feature screens → API client: requests data
- API client → Hono server: HTTP and WS
- Hono server → Auth routes: dispatches
- Auth routes → Auth service: calls
- Hono server → Receipt processing: dispatches
- Hono server → Delivery processing: dispatches
- Hono server → Internal transfers: dispatches
- Hono server → Inventory adjustments: dispatches
- Hono server → Stock balances: dispatches
- Hono server → Movement ledger: dispatches
- Hono server → Dashboard: dispatches
- Hono server → AI assistant: dispatches
- Hono server → WebSocket pub/sub: dispatches
- Receipt processing → Drizzle database: transactional updates
- Delivery processing → Drizzle database: transactional updates
- Internal transfers → Drizzle database: transactional updates
- Inventory adjustments → Drizzle database: transactional updates
- Drizzle database → Inventory tables: uses tables
- Drizzle database → PostgreSQL: queries
- Dashboard → Drizzle database: reads summaries
- AI assistant → Groq API: LLM requests
- WebSocket pub/sub → Operator: broadcasts events
- Hono server → Metrics: records metrics
- Auth service → SMTP mail: sends email