A full-stack payroll management system for maintaining employee master data and generating monthly salary calculations, payslip data, and period-wise salary history.
-
Employee Management (CRUD)
- Add, update, list, and delete employees
- Employee details stored in
employee_details
-
Payroll Generation
- Generate salary for a selected MMYY period
- Supports employee categories: H&F, SKS, Apprentice
- Creates salary tables dynamically per period + category (e.g.,
salary_1225_hf) - Blocks duplicate generation for the same period/category
-
Salary Calculation Components
- Basic salary based on attendance and calculated daily rate
- Allowances: CEA, CHA, HRA, OTHALLOW, SPA, UMA (+ totals)
- Deductions: CLUB, PF, TDS, ESIC, transport/medical/etc. (+ totals)
- Computes Net Salary = Basic + Total Allowance − Total Deduction
-
Payroll Period Operations
- List all generated payroll periods
- Fetch salary data for a period (optionally filter by category)
- Delete generated salary for a period (drops the corresponding tables)
- Frontend: React (Create React App)
- Backend: Node.js + Express
- Database: MySQL
- Uses dynamic salary tables named by period and category
-
Employees
GET /api/employeesPOST /api/employeesPUT /api/employees/:empCodeDELETE /api/employees/:empCode
-
Salaries
POST /api/salaries/generate(generate payroll for a period)GET /api/salaries/periods(list available periods)GET /api/salaries/period/:period(fetch salaries for a period)DELETE /api/salaries/period/:period(delete salaries for a period)
Refer to PAYROLL_DATABASE_DESCRIPTION.md for the full schema and design explanation, including:
employee_detailstable definition- Dynamic
salary_MMYY_categorytable structure - Salary/allowance/deduction fields
- Period/category naming conventions
- Set up the MySQL database and configure environment variables for the backend.
- Start the backend server.
- Start the React frontend.
- Use the UI to add employees and generate monthly payroll.