A comprehensive school management system with features for students, teachers, and administrators.
src/
├── public/ # Publicly accessible files
│ ├── css/ # Stylesheets
│ ├── js/ # Client-side JavaScript
│ ├── images/ # Images and assets
│ └── uploads/ # File uploads
├── auth/ # Authentication related files
│ ├── login.html # Login page
│ └── register.html # Registration page
├── student/ # Student portal
│ ├── dashboard.html # Student dashboard
│ ├── academic.html # Academic records
│ ├── attendance.html # Attendance records
│ └── assignments.html # Assignments
├── admin/ # Admin portal
│ ├── dashboard.html # Admin dashboard
│ ├── students.html # Student management
│ └── teachers.html # Teacher management
├── shared/ # Shared resources
│ ├── styles/ # Shared stylesheets
│ └── utils/ # Shared utilities
├── database/ # Database related files
│ └── initDatabase.js # Database initialization
├── routes/ # API routes
├── controllers/ # Route controllers
├── models/ # Database models
├── middleware/ # Express middleware
└── config/ # Configuration files
-
Prerequisites
- Node.js (v14 or higher)
- MySQL (v8.0 or higher)
- npm or yarn
-
Installation
# Clone the repository git clone [repository-url] # Install dependencies npm install # Create .env file cp .env.example .env
-
Database Setup
# Start MySQL server sudo service mysql start # Create database and tables node src/database/initDatabase.js
-
Running the Application
# Start the server npm start or nom run dev # The application will be available at http://localhost:3001/0/2
-
Public Pages
- Homepage:
http://localhost:3001 - Registration:
http://localhost:3001/registration.html - Contact:
http://localhost:3001/contact.html
- Homepage:
-
Student Portal
- Login:
http://localhost:3001/src/auth/login.html - Dashboard:
http://localhost:3001/src/student/dashboard.html - Academic Records:
http://localhost:3001/src/student/academic.html - Attendance:
http://localhost:3001/src/student/attendance.html
- Login:
-
Admin Portal
- Login:
http://localhost:3001/admin-login.html - Dashboard:
http://localhost:3001/admin.html - Student Management:
http://localhost:3001/src/admin/students.html - Teacher Management:
http://localhost:3001/src/admin/teachers.html
- Login:
-
Admin
- Username:
admin - Password:
admin123
- Username:
-
Student
- Register at:
http://localhost:3001/registration.html - Use registered credentials to login
- Register at:
-
Student Features
- View academic records
- Check attendance
- Submit assignments
- View report cards
- Access library resources
-
Admin Features
- Manage students
- Manage teachers
- Track attendance
- Generate reports
- Manage academic records
-
Teacher Features
- Record attendance
- Submit grades
- Manage assignments
- View class lists
The system provides RESTful APIs for various operations. All API endpoints are prefixed with /api/.
- POST
/api/auth/login- User login - POST
/api/auth/register- User registration
- GET
/api/students- List all students - POST
/api/students- Register new student - GET
/api/students/:id- Get student details - PUT
/api/students/:id- Update student details
- GET
/api/grades/:studentId- Get student grades - POST
/api/grades- Submit grades - GET
/api/attendance/:studentId- Get attendance records
-
Database Connection Issues
- Verify MySQL is running
- Check database credentials in .env
- Ensure database and tables are created
-
Authentication Issues
- Clear browser cache and cookies
- Verify credentials
- Check server logs for errors
-
File Upload Issues
- Check uploads directory permissions
- Verify file size limits
- Check file type restrictions
- Fork the repository
- Create a feature branch
- Commit your changes
- Push to the branch
- Create a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.