A full-stack web application for managing computer lab faults β from report submission to technician assignment, resolution tracking, and feedback collection.
LabDesk is a web-based platform designed to simplify computer laboratory maintenance and fault management. Students can report hardware and software issues, technicians can manage assigned tasks, and administrators can monitor, assign, and analyze fault reports through a centralized dashboard.
The system improves communication between students, technicians, and administrators while reducing downtime in computer laboratories.
- Submit fault reports (hardware or software)
- Track real-time status of submitted faults
- Search the self-help solutions library before raising a ticket
- Mark a fault as self-resolved
- Receive in-app notifications on fault updates
- Rate resolved faults with star feedback
- View assigned tasks dashboard
- Accept, decline, or complete assigned tasks
- Add problem and solution notes per ticket
- Full fault management with search & filter (status, type, keyword)
- Assign faults to technicians with workload visibility
- Analytics dashboard β 7-day fault trend chart + top faulty labs
- Technician performance cards with completion rate %
- Feedback analytics β star rating distribution
- CSV export of all fault reports
- Notify students directly from the panel
- Manage the software solutions library (add/edit/delete)
- Secure session-based authentication (role-based: Admin / Technician / Student)
- Login brute-force protection (15-min block after failed attempts)
- Password reset via email (token-based)
- Mobile responsive UI with hamburger menu
- Toast notifications (no alert() dialogs)
| Layer | Technology |
|---|---|
| Backend | Node.js, Express.js |
| Frontend | HTML5, CSS3, Vanilla JavaScript |
| Database | MySQL 8.0 |
| Auth | express-session, bcryptjs |
| Nodemailer (Gmail) | |
| Deployment | Render (backend), Railway (MySQL) |
users β id, name, email, password, role, student_id,
reset_token, reset_token_expiry
fault_reports β id, student_id, lab_name, computer_number, fault_type,
description, status, assigned_technician_id,
resolution_notes, resolved_by_student,
created_at, updated_at
technician_tasks β id, fault_id, technician_id, assigned_by, status,
problem_description, solution_description,
assigned_at, updated_at
software_solutions β id, category, problem, solution, steps
notifications β id, user_id, message, type, is_read, created_at
feedback β id, fault_id, student_id, rating, comment, created_at
- Node.js 18+
- MySQL 8.0
- Gmail account (for email notifications)
git clone https://github.com/ug8yogesh/LabDesk.git
cd LabDesknpm installOpen MySQL and run:
mysql -u root -p < databasesetup.sqlcp .env.example .envEdit .env:
DB_HOST=localhost
DB_USER=root
DB_PASSWORD=your_mysql_password
DB_NAME=lab_fault_system
PORT=3000
NODE_ENV=development
SESSION_SECRET=your_long_random_secret_here
EMAIL_USER=your_email@gmail.com
EMAIL_PASS=your_gmail_app_passwordGmail App Password: Google Account β Security β 2-Step Verification β App Passwords β Generate
npm start- railway.app β New Project β MySQL
- Go to Query tab β paste and run
databasesetup.sql - Copy connection credentials from Variables tab
- render.com β New β Web Service
- Connect GitHub repo
- Set:
- Build Command:
npm install - Start Command:
node server.js
- Build Command:
- Add environment variables (DB credentials from Railway + session secret + Gmail)
- Deploy β
| Role | Password | |
|---|---|---|
| Admin | admin@lab.com | admin123 |
| Student | student@lab.com | student123 |
| Technician | tech@lab.com | tech123 |
β οΈ These are default seed accounts created automatically for testing and demonstration purposes.
| Method | Endpoint | Role | Description |
|---|---|---|---|
| POST | /api/auth/login |
All | Login |
| POST | /api/auth/register |
All | Register |
| POST | /api/auth/logout |
All | Logout |
| GET | /api/auth/me |
All | Get current session user |
| POST | /api/auth/forgot-password |
All | Send reset email |
| POST | /api/auth/reset-password |
All | Reset password via token |
| GET | /api/solutions |
All | Self-help library |
| POST | /api/faults |
Student | Submit fault report |
| GET | /api/faults/my |
Student | View my reports |
| PATCH | /api/faults/:id/self-resolved |
Student | Mark fault as self-resolved |
| POST | /api/feedback |
Student | Submit feedback |
| GET | /api/technician/tasks |
Technician | View assigned tasks |
| PATCH | /api/technician/tasks/:id |
Technician | Update task status/notes |
| GET | /api/admin/faults |
Admin | All fault reports |
| GET | /api/admin/technicians |
Admin | Technician workload list |
| POST | /api/admin/assign |
Admin | Assign fault to technician |
| POST | /api/admin/notify-student |
Admin | Notify student of resolution |
| GET | /api/admin/feedback |
Admin | All feedback entries |
| GET | /api/admin/stats |
Admin | Dashboard analytics |
| GET | /api/admin/export/faults |
Admin | Download CSV |
| GET | /api/admin/db/:table |
Admin | Raw table viewer |
| GET/POST/PUT/DELETE | /api/admin/solutions |
Admin | Manage solutions library |
| GET | /api/notifications |
All | View notifications |
| PATCH | /api/notifications/read |
All | Mark notifications as read |
LabDesk/
βββ server.js # Express app + all API routes
βββ databasesetup.sql # Full DB schema + seed data
βββ package.json
βββ .env.example
βββ public/
βββ index.html # Redirect to frontend
βββ frontend/
βββ index.html # Main SPA
βββ reset-password.html
βββ css/
β βββ style.css
βββ js/
βββ main.js # All frontend logic
- Passwords hashed with bcryptjs
- Brute-force login protection (15-min block)
- Session cookie:
httpOnly,sameSite: strict, HTTPS-only in production - Request body size limited (50KB)
- Role-based route protection on all API endpoints
- Environment variables for all secrets β no hardcoded credentials
π https://labdesk-93hf.onrender.com
MIT License β free to use and modify.
Yogesh U G
- π IT-Anna University Student
- π GitHub: https://github.com/ug8yogesh



