A modern Human Resource Information System (HRIS) and employee attendance management platform built with Laravel 12, Blade, Tailwind CSS, and MySQL.
The system is designed to help organizations manage employee information, departments, positions, attendance, leave requests, office locations, and location-based attendance validation through a secure role-based access control system.
e-Absensi HRIS is a web-based HR management application focused on digitizing employee administration and attendance workflows.
The system supports three user roles:
- Admin โ Full system and master-data management
- HR โ Employee, attendance, leave, and reporting management
- Employee โ Personal attendance, leave requests, and profile management
A key feature of this project is the geolocation-based attendance system, which validates an employee's location against a configured office radius using the Haversine formula.
Version: v1.1.0
- Office Management
- Office Location Configuration
- Configurable Attendance Radius
- Browser Geolocation API
- Haversine Distance Calculation
- Geolocation Radius Validation
- GPS Accuracy Recording
- Latitude & Longitude Recording
- Google Maps Location Integration
- Improved Attendance Validation
- Manual authentication without Laravel Breeze
- Login & Logout
- Session-based authentication
- Role-Based Access Control (RBAC)
- Protected routes using middleware
- Role-specific dashboards and features
| Role | Access |
|---|---|
| Admin | Full system management |
| HR | HR & employee management |
| Employee | Personal attendance & leave |
- Employee statistics
- Attendance statistics
- Leave request statistics
- HR overview
- Create department
- Edit department
- Delete department
- Search department
- Pagination
- Create position
- Edit position
- Delete position
- Search position
- Pagination
- Create employee
- Edit employee
- Delete employee
- Employee search
- Department filtering
- Employee status management
- Avatar upload
- Pagination
- Create office
- Edit office
- Delete office
- Search office
- Configure office coordinates
- Configure attendance radius
Office location and radius configuration are restricted to Admin.
- Employee overview
- Attendance statistics
- Leave request overview
- View employees
- Search employees
- Filter by department
- Manage employee information
- Manage positions and departments
- View attendance records
- Search attendance
- Filter by date
- Filter by department
- Filter by attendance status
- View attendance history
- View employee location
- View GPS accuracy
- View distance from office
- View attendance location status
- Open attendance coordinates in Google Maps
- View leave requests
- Review leave requests
- Approve leave requests
- Reject leave requests
- Manage leave status
- Attendance summary
- Date filtering
- Department filtering
- Attendance statistics
HR users can also perform their own:
- Check In
- Check Out
- Attendance history
- Geolocation validation
- Personal dashboard
- Attendance summary
- Leave request summary
- Check In
- Check Out
- Daily check-in validation
- Daily check-out validation
- Late attendance detection
- Attendance history
The attendance system uses the browser's Geolocation API to validate the employee's physical location.
- GPS permission request
- Automatic latitude detection
- Automatic longitude detection
- GPS accuracy detection
- Distance calculation
- Office radius validation
- Attendance location recording
- Google Maps coordinate integration
Employee
โ
โผ
Login
โ
โผ
Attendance Check In
โ
โผ
Request Browser GPS
โ
โผ
Get Latitude / Longitude
โ
โผ
Calculate Distance
โ
โผ
Haversine Formula
โ
โผ
Compare With Office Radius
โ
โโโโโโโโโโโโโโโโโ
โ โ
โผ โผ
Inside Radius Outside Radius
โ โ
โผ โผ
Attendance Attendance
Recorded Rejected
Employees can submit:
- Vacation leave
- Sick leave
- Other leave requests
Employees can also:
- View submitted requests
- Check request status
- View leave history
Employee
โ
โผ
Submit Leave Request
โ
โผ
Pending
โ
โโโโโโโโโโโโโโโโโ
โ โ
โผ โผ
Approved Rejected
Attendance records contain important information such as:
- Employee
- Office
- Attendance date
- Check-in time
- Check-out time
- Attendance status
- Late minutes
- Latitude
- Longitude
- GPS accuracy
- Distance from office
- Notes
This allows HR and Admin users to review attendance history and verify whether an attendance record was submitted from an authorized office location.
Each office can have a configured:
- Office name
- Latitude
- Longitude
- Attendance radius
Example:
Office
โโโ Name
โโโ Latitude
โโโ Longitude
โโโ Radius
The office coordinates act as the reference point for geolocation attendance validation.
The system uses the Haversine formula to calculate the distance between:
Employee GPS Location
โ
โผ
Latitude + Longitude
โ
โผ
Office Coordinates
โ
โผ
Haversine Calculation
โ
โผ
Distance in Meters
The calculated distance is then compared with the configured office attendance radius.
The system provides attendance reporting with:
- Date filtering
- Department filtering
- Attendance status filtering
- Attendance summary
- Attendance statistics
This allows HR and Admin users to monitor attendance patterns and generate useful operational information.
- Laravel 12
- PHP 8.2+
- Eloquent ORM
- Blade
- Tailwind CSS
- JavaScript
- MySQL
- Geolocation API
- MVC Architecture
- Role-Based Access Control
- RESTful Resource Controllers
- Form Request Validation
- Eloquent Relationships
e-Absensi/
โ
โโโ app/
โ โโโ Http/
โ โ โโโ Controllers/
โ โ โ โโโ Admin/
โ โ โ โโโ Employee/
โ โ โ โโโ HR/
โ โ โ โโโ Report/
โ โ โ
โ โ โโโ Middleware/
โ โ โโโ Requests/
โ โ
โ โโโ Models/
โ โโโ Services/
โ
โโโ database/
โ โโโ factories/
โ โโโ migrations/
โ โโโ seeders/
โ
โโโ resources/
โ โโโ views/
โ โโโ admin/
โ โโโ employee/
โ โโโ hr/
โ โโโ layouts/
โ โโโ reports/
โ
โโโ routes/
โ โโโ web.php
โ โโโ auth.php
โ โโโ profile.php
โ โโโ admin.php
โ โโโ hr.php
โ โโโ employee.php
โ โโโ management.php
โ โโโ reports.php
โ
โโโ public/
โโโ storage/
โโโ tests/
โโโ .env.example
โโโ artisan
โโโ composer.json
โโโ README.md
users
departemens
positions
offices
attendances
leave_requests
User
โ
โโโ Department
โโโ Position
โโโ Attendances
โโโ Leave Requests
Department
โ
โโโ Users
โโโ Positions
Office
โ
โโโ Attendances
The application separates access based on user roles.
โโโโโโโโโโโโโโโโ
โ USER โ
โโโโโโโโฌโโโโโโโโ
โ
โโโโโโโโโโโโโโโผโโโโโโโโโโโโโโ
โ โ โ
โผ โผ โผ
ADMIN HR EMPLOYEE
โ โ โ
โผ โผ โผ
Full Access HR Access Personal Access
Backend authorization is enforced using role middleware to prevent unauthorized access even when users manually access protected URLs.
git clone https://github.com/MasMuham24/e-absensi.gitcd e-absensicomposer installcp .env.example .envFor Windows PowerShell, you can use:
Copy-Item .env.example .envphp artisan key:generateUpdate the .env file:
DB_CONNECTION=mysql
DB_HOST=127.0.0.1
DB_PORT=3306
DB_DATABASE=e_absensi
DB_USERNAME=root
DB_PASSWORD=php artisan migrate --seedphp artisan storage:linkphp artisan serveApplication:
http://127.0.0.1:8000
Clear Laravel caches when necessary:
php artisan optimize:clearCheck registered routes:
php artisan route:listRun tests:
php artisan test LOGIN
โ
โผ
Role Validation
โ
โโโโโโโโโโโโโโโผโโโโโโโโโโโโโโ
โ โ โ
โผ โผ โผ
ADMIN HR EMPLOYEE
โ โ โ
โ โ โผ
โ โ Attendance
โ โ โ
โ โผ โผ
โ HR Management Leave Request
โ โ โ
โโโโโโโโฌโโโโโโโดโโโโโโโโโโโโโโ
โ
โผ
Attendance & Leave
Reports
This project demonstrates practical implementation of:
- Laravel MVC architecture
- Manual authentication
- Role-Based Access Control
- Middleware authorization
- CRUD operations
- Eloquent ORM
- Model relationships
- Form Request validation
- Search & filtering
- Pagination
- File upload
- Attendance business logic
- Leave management workflow
- Office management
- Browser Geolocation API
- Haversine distance calculation
- Radius-based validation
- GPS accuracy handling
- Reporting system
- Modular route architecture
- Service-based business logic
- Office Management
- Office Location Configuration
- Attendance Radius Configuration
- Browser Geolocation Integration
- Haversine Distance Calculation
- Radius Validation
- GPS Accuracy Recording
- Latitude & Longitude Recording
- Google Maps Coordinate Integration
- Attendance validation
- Attendance workflow
- Database structure
- Role-based access control
- Management route separation
- Authentication
- Role-Based Access Control
- Employee Management
- Department Management
- Position Management
- Attendance Management
- Leave Management
- Attendance Reporting
Planned improvements may include:
- Payroll Management
- Overtime Management
- Shift Management
- Work Schedule Management
- Holiday Calendar
- Employee Performance Management
- Notification System
- Export Attendance Reports
- Advanced Analytics Dashboard
- Audit Logs
- API Integration
- Mobile Application
This project is intended for educational purposes and portfolio demonstration.
Muhammad Syafi'i
GitHub: MasMuham24
Active Development
This project is continuously being improved with new HR management features, attendance capabilities, security improvements, and production-oriented architecture.