A full-stack web application for managing employee leaves and reimbursement claims with role-based access control.
- Authentication — JWT-based login & signup
- Role-Based Dashboards — Employee, Manager, and Admin views
- Leave Management — Apply, approve, and reject leave requests
- Reimbursement Claims — Submit claims with optional bill uploads (via ImageKit)
- Bill Management — Upload, replace, delete, and download bills (images/PDFs)
- Charts & Analytics — Donut charts showing status breakdown on dashboards
- Toast Notifications — Real-time feedback for all actions
- Dark / Light Mode — Theme toggle with system preference support
| Layer | Technology |
|---|---|
| Frontend | React, Vite, TailwindCSS, Recharts |
| Backend | Node.js, Express, Mongoose |
| Database | MongoDB Atlas |
| Storage | ImageKit (bill uploads) |
| Auth | JWT (jsonwebtoken + bcryptjs) |
- Demo credential for admin
- username/email - test@gmail.com
- pass - test123456789
- Node.js v18+
- MongoDB Atlas connection string
- ImageKit account (for bill uploads)
git clone https://github.com/Abhishek-Verma0/Employee-Leave-Management-System.git
cd Employee-Leave-Management-Systemcd server
npm installCreate a .env file in server/:
MONGO_DB_URL=your_mongodb_connection_string
JWT_SECRET=your_jwt_secret
IMAGEKIT_PUBLIC_KEY=your_public_key
IMAGEKIT_PRIVATE_KEY=your_private_key
IMAGEKIT_URL_ENDPOINT=https://ik.imagekit.io/your_id
Start the server:
npm startNote: The very first user to register is automatically promoted to admin so you can start approving other users immediately. If you already have users in the database and need to create an admin, run the seed script instead:
node scripts/seedAdmin.jsYou can customise the seed credentials with environment variables:
ADMIN_NAME,ADMIN_EMAIL,ADMIN_PASSWORD.
cd client
npm installCreate a .env file in client/:
VITE_API_BASE_URL=http://localhost:3000
Start the client:
npm run devThe app will be available at http://localhost:5173.
| Role | Capabilities |
|---|---|
| Employee | Apply for leaves & reimbursements, upload bills |
| Manager | All employee actions + approve/reject employee requests |
| Admin | Manage users, approve/reject manager requests, view all data |
├── client/ # React frontend (Vite)
│ └── src/
│ ├── components/ # Reusable UI components
│ ├── context/ # Auth & Theme context providers
│ ├── pages/ # Dashboard & auth pages
│ └── utils/ # Axios instance
└── server/ # Express backend
├── config/ # DB & ImageKit config
├── controllers/ # Route handlers
├── middleware/ # Auth middleware
├── models/ # Mongoose schemas
└── routes/ # API routes
Contributions are welcome! If you'd like to improve this project:
- Fork the repository
- Create a new branch (
git checkout -b feature/your-feature) - Commit your changes (
git commit -m "Add your feature") - Push to the branch (
git push origin feature/your-feature) - Open a Pull Request
Abhishek Verma — @Abhishek-Verma0
- Improve heading hierarchy for better readability
- Ensure consistent spacing between sections
- Use proper Markdown formatting for code blocks and lists
- Align all installation and usage steps properly
- Introduction
- Features
- Tech Stack
- Installation
- Usage
- Project Structure
- Contribution Guidelines
- License
- Add badges (optional): build, license, contributors
- Add screenshots for better UI understanding
- Standardize code blocks for commands
Improve onboarding experience for new contributors and users by making README more structured, readable, and professional