How shashikant-panchal/sbe-enterprise-backend works
SBE Enterprise is a REST backend for industrial manpower supply and facility management. Administrators or client HR users authenticate, then manage client companies and workforce rosters, record daily attendance, receive manpower proposals, and retrieve operational/compliance reports. Express dispatches requests, while each route selects MongoDB or the synchronized in-memory fallback. The sampled implementation confirms these main flows; proposal and report capabilities are represented from their route sources and README endpoint documentation.
Components 20
API Runtime
- Express API
index.js
Identity Access
- JWT Middleware
middleware/authMiddleware.js - Authentication API
routes/authRoutes.js - Password Generator
utils/passwordGenerator.js
Workforce Operations
- Client Management
routes/clientRoutes.js - Workforce Roster
routes/employeeRoutes.js - Shift Attendance
routes/attendanceRoutes.js - Manpower Proposals
routes/proposalRoutes.js
Persistence Layer
- Database Connector
config/db.js - Admin Records
models/Admin.js - Client Records
models/Client.js - Employee Records
models/Employee.js - Attendance Records
models/Attendance.js - Proposal Records
models/Proposal.js - Fallback Store
data/store.js
Reports Insights
- Operational Reports
routes/reportRoutes.js
Other components
- SBE Admin
- Client HR
- Contact Submitter
- MongoDB Atlas
Connections 33
- SBE Admin → Express API: sends requests
- Client HR → Express API: sends requests
- Contact Submitter → Express API: submits inquiry
- Express API → Database Connector: connects database
- Express API → Authentication API: mounts routes
- Express API → Client Management: mounts routes
- Express API → Workforce Roster: mounts routes
- Express API → Shift Attendance: mounts routes
- Express API → Manpower Proposals: mounts routes
- Express API → Operational Reports: mounts routes
- Authentication API → JWT Middleware: protects profile
- Authentication API → Admin Records: reads admin
- Authentication API → Client Records: reads client
- Authentication API → Fallback Store: falls back
- Client Management → Client Records: manages clients
- Client Management → Password Generator: generates credentials
- Client Management → Fallback Store: falls back
- Workforce Roster → Employee Records: manages workers
- Workforce Roster → Fallback Store: falls back
- Shift Attendance → Attendance Records: stores rollcall
- Shift Attendance → Fallback Store: falls back
- Manpower Proposals → Proposal Records: stores requests
- Manpower Proposals → Fallback Store: falls back
- Operational Reports → Employee Records: reads workforce
- Operational Reports → Client Records: reads clients
- Operational Reports → Fallback Store: falls back
- Database Connector → MongoDB Atlas: connects MongoDB
- Database Connector → Fallback Store: enables fallback
- Admin Records → MongoDB Atlas: persists records
- Client Records → MongoDB Atlas: persists records
- Employee Records → MongoDB Atlas: persists records
- Attendance Records → MongoDB Atlas: persists records
- Proposal Records → MongoDB Atlas: persists records