How mploye/meditech-attendance-payroll-hr works
Genetics Meditech is a multi-tenant HR, attendance, and payroll SaaS. Users work through authenticated Next.js pages, which call a FastAPI API for workforce administration, attendance/device sync, and payroll outputs such as reports and payslips. The backend separates route registration, business services, payroll calculations, persistence models, and eSSL integration; an optional standalone connector uploads device transactions. Some domain routes and services are unsampled, so their documented capabilities are shown without asserting unverified internal calls.
Main entry points: endpoints HR and payroll routes · router.py API routes · attendance.py Attendance routes · sync_worker.py Device connector
Components 24
Web application
- HR pages
frontend/app/(app) - App shell
frontend/components/Shell.tsx - API client
frontend/lib/api.ts - Login page
frontend/app/login/page.tsx
API and services
- FastAPI application
backend/app/main.py - API routes
backend/app/api/v1/router.py - Authentication routes
backend/app/api/v1/endpoints/auth.py - Attendance routes
backend/app/api/v1/endpoints/attendance.py - HR and payroll routes
backend/app/api/v1/endpoints - Device sync routes
backend/app/api/v1/endpoints/device_sync.py
HR and payroll domains
- Attendance service
backend/app/services/attendance_service.py - Employee service
backend/app/services/employee_service.py - Payroll service
backend/app/services/payroll_service.py - Payroll calculations
backend/app/payroll/calculator.py - Payslip service
backend/app/services/payslip_service.py - Reports service
backend/app/services/report_service.py - SQLAlchemy models
backend/app/models - Relational database
Device synchronization
- eSSL integration
backend/app/integrations/essl/service.py - eSSL client
backend/app/integrations/essl/client.py - Device connector
backend/connector/sync_worker.py - File outbox
backend/connector/queue.py
Other components
- HR user
- eSSL terminals
Connections 26
- HR user → HR pages: uses
README.md - HR user → Login page: signs in
README.md - HR pages → App shell: renders
README.md - HR pages → API client: requests API
- Login page → API client: authenticates
- FastAPI application → API routes: registers
backend/app/main.py - API routes → Authentication routes: routes to
backend/app/api/v1/router.py - API routes → Attendance routes: routes to
backend/app/api/v1/router.py - API routes → HR and payroll routes: registers
backend/app/api/v1/router.py - Attendance routes → Attendance service: calls
backend/app/api/v1/endpoints/attendance.py - Attendance routes → SQLAlchemy models: queries
backend/app/api/v1/endpoints/attendance.py - Attendance routes → Device sync routes: uses sync service
backend/app/api/v1/endpoints/attendance.py - Device sync routes → Device connector: accepts uploads
- HR and payroll routes → Employee service: delegates
- HR and payroll routes → Payroll service: delegates
- HR and payroll routes → Payslip service: delegates
- HR and payroll routes → Reports service: delegates
- Payroll service → Payroll calculations: calculates with
- Payslip service → SQLAlchemy models: reads payroll data
backend/app/services/payslip_service.py - Relational database → SQLAlchemy models: stores
README.md - FastAPI application → Relational database: initializes
backend/app/main.py - eSSL integration → eSSL client: dispatches
backend/app/integrations/essl/service.py - eSSL integration → eSSL terminals: reads transactions
- Device connector → eSSL terminals: polls
backend/connector/sync_worker.py - Device connector → File outbox: queues records
backend/connector/sync_worker.py - Device connector → FastAPI application: uploads transactions
backend/connector/sync_worker.py