Skip to content

Internal dashboard for HR teams to manage employee records, track performance reviews, and generate compliance reports.

Notifications You must be signed in to change notification settings

vidhyavijayan3/HR_Control

Repository files navigation

# HR Dashboard Internal dashboard for HR teams to manage employee records, track performance reviews, and generate compliance reports. ## 🚀 Features - **Employee Management**: Complete employee lifecycle management with profiles, documents, and org charts - **Performance Reviews**: 360-degree feedback, configurable review cycles, and goal tracking - **Compliance Reports**: Pre-built and custom reports for regulatory compliance - **Role-Based Access Control**: 5 user roles with granular permissions - **Real-time Analytics**: Dashboard with key HR metrics and insights - **Third-party Integrations**: SSO, Payroll, ATS, and more ## 📋 Prerequisites - Node.js 20.x or higher - Docker and Docker Compose - PostgreSQL 16.x (or use Docker) - Redis 7.x (or use Docker) ## 🛠️ Tech Stack ### Frontend - React 18 with TypeScript - Vite 5 - Material-UI - Redux Toolkit - React Router v6 ### Backend - Node.js 20 with TypeScript - NestJS 10 - Prisma ORM - PostgreSQL 16 - Redis 7 - JWT Authentication ## 📦 Installation ### Using Docker (Recommended) 1. Clone the repository: ```bash git clone cd hr-dashboard ``` 2. Copy environment files: ```bash cp backend/.env.example backend/.env cp frontend/.env.example frontend/.env ``` 3. Update environment variables in `.env` files 4. Start all services: ```bash npm run docker:up ``` 5. Run database migrations: ```bash npm run db:migrate ``` 6. (Optional) Seed database with sample data: ```bash npm run db:seed ``` The application will be available at: - Frontend: http://localhost:3000 - Backend API: http://localhost:4000 - API Documentation: http://localhost:4000/api/docs ### Manual Installation 1. Install dependencies: ```bash npm install ``` 2. Set up environment variables (see `.env.example` files) 3. Start PostgreSQL and Redis locally 4. Run database migrations: ```bash npm run db:migrate ``` 5. Start development servers: ```bash npm run dev ``` ## 🧪 Testing ```bash # Run all tests npm test # Run frontend tests npm run test --workspace=frontend # Run backend tests npm run test --workspace=backend # Run with coverage npm run test:coverage ``` ## 🏗️ Building for Production ```bash # Build all workspaces npm run build # Build specific workspace npm run build:frontend npm run build:backend ``` ## 🐳 Docker Commands ```bash # Build containers npm run docker:build # Start containers npm run docker:up # Stop containers npm run docker:down # View logs docker-compose logs -f # Rebuild and restart docker-compose up -d --build ``` ## 📚 Project Structure ``` hr-dashboard/ ├── frontend/ # React frontend application │ ├── src/ │ │ ├── components/ # Reusable UI components │ │ ├── pages/ # Page components │ │ ├── store/ # Redux store and slices │ │ ├── services/ # API service layer │ │ ├── hooks/ # Custom React hooks │ │ ├── utils/ # Utility functions │ │ └── types/ # TypeScript type definitions │ ├── public/ # Static assets │ └── package.json │ ├── backend/ # NestJS backend application │ ├── src/ │ │ ├── modules/ # Feature modules │ │ ├── common/ # Shared code │ │ ├── config/ # Configuration │ │ └── main.ts # Application entry point │ ├── prisma/ # Database schema and migrations │ │ ├── schema.prisma # Prisma schema │ │ └── migrations/ # Migration files │ └── package.json │ ├── docker-compose.yml # Docker services configuration ├── .github/ # GitHub Actions CI/CD └── package.json # Root package.json (workspace) ``` ## 🔐 Environment Variables ### Backend (.env) ```env DATABASE_URL=postgresql://user:password@localhost:5432/hr_dashboard REDIS_URL=redis://localhost:6379 JWT_SECRET=your-secret-key JWT_REFRESH_SECRET=your-refresh-secret NODE_ENV=development PORT=4000 ``` ### Frontend (.env) ```env VITE_API_URL=http://localhost:4000 VITE_APP_NAME=HR Dashboard ``` ## 👥 Default Users After seeding the database, you can login with: - **Super Admin**: admin@company.com / Admin@123 - **HR Manager**: hr.manager@company.com / HRManager@123 - **HR Specialist**: hr.specialist@company.com / HRSpecialist@123 ## 📖 API Documentation Interactive API documentation is available at: - Swagger UI: http://localhost:4000/api/docs - OpenAPI JSON: http://localhost:4000/api/docs-json ## 🔒 Security - All passwords are hashed using bcrypt - JWT tokens with refresh token rotation - Rate limiting on API endpoints - CORS configuration - Helmet.js for security headers - Input validation and sanitization - SQL injection protection via Prisma ## 📝 License This project is proprietary and confidential. ## 🤝 Contributing 1. Create a feature branch: `git checkout -b feature/your-feature` 2. Commit your changes: `git commit -am 'Add some feature'` 3. Push to the branch: `git push origin feature/your-feature` 4. Submit a pull request ## 📞 Support For support, email it-support@company.com or create an issue in the repository.# HR_Control

About

Internal dashboard for HR teams to manage employee records, track performance reviews, and generate compliance reports.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published