Beautiful student attendance tracking system with Apple Glass design
Features β’ Screenshots β’ Quick Start β’ Tech Stack β’ API β’ Deployment
- Real-time attendance overview
- Today's session summary
- Quick action buttons
- Attendance alerts for low-performing students
- Full CRUD operations
- CSV import support
- Search and filter by class
- Individual attendance history
- Create and organize classes
- Assign teachers
- View class statistics
- Generate attendance reports
- Interactive attendance grid
- One-click status changes (Present/Absent/Late/Excused)
- Bulk operations
- Quick attendance mode
- Detailed attendance reports
- Export to CSV/Excel
- Low attendance alerts
- Trend analysis
- JWT-based authentication
- Role-based access (Admin/Teacher)
- Secure password handling
git clone https://github.com/bendudebot/attendance.git
cd attendance
chmod +x scripts/*.sh
./scripts/docker-start.shThat's it! π This will:
- β Start PostgreSQL database
- β Run all migrations
- β Seed test data (2 users, 3 classes, 15 students, ~150 attendance records)
- β Start the API server at http://localhost:3001
# Terminal 1: Database + Backend
cd backend
docker-compose up -d db # Start PostgreSQL
npm install
npx prisma migrate dev # Run migrations
npx prisma db seed # Seed test data
npm run dev # API at http://localhost:3001# Terminal 2: Web Frontend
cd web
npm install
npm run dev # Web at http://localhost:3000| Role | Password | |
|---|---|---|
| Admin | admin@attendance.app | admin123 |
| Teacher | teacher@attendance.app | teacher123 |
π Full setup guide: docs/QUICKSTART.md
| Role | Password | |
|---|---|---|
| Admin | admin@attendance.app | admin123 |
| Teacher | teacher@attendance.app | teacher123 |
- Runtime: Node.js 18+
- Framework: Express.js
- Database: PostgreSQL 15
- ORM: Prisma 5
- Authentication: JWT
- Validation: express-validator
- Framework: Next.js 14 (App Router)
- Styling: Tailwind CSS
- Icons: Lucide React
- Charts: Recharts
- Framework: React Native (Expo)
- Navigation: Expo Router
- Containerization: Docker
- Database: PostgreSQL (Alpine)
See docs/API.md for full API documentation.
| Method | Endpoint | Description |
|---|---|---|
| POST | /api/auth/login |
User login |
| POST | /api/auth/register |
User registration |
| GET | /api/classes |
List all classes |
| GET | /api/students |
List all students |
| POST | /api/attendance/mark |
Mark attendance |
| GET | /api/attendance/today |
Today's summary |
erDiagram
User ||--o{ Class : teaches
Class ||--o{ Student : contains
Class ||--o{ Session : has
Student ||--o{ Attendance : has
Session ||--o{ Attendance : records
User {
string id PK
string email UK
string password
string name
enum role
}
Class {
string id PK
string name
string code UK
string teacherId FK
}
Student {
string id PK
string firstName
string lastName
string studentId UK
string classId FK
}
Session {
string id PK
string classId FK
datetime date
string startTime
string endTime
}
Attendance {
string id PK
string studentId FK
string sessionId FK
enum status
string notes
}
# Database
DATABASE_URL="postgresql://user:password@localhost:5432/attendance"
# Authentication
JWT_SECRET="your-super-secret-jwt-key"
# Server
PORT=3001NEXT_PUBLIC_API_URL=http://localhost:3001/api# Build and run
docker-compose -f docker-compose.prod.yml up -d
# Run migrations
docker-compose exec api npx prisma migrate deploy- Set up a PostgreSQL database
- Configure environment variables
- Build and start the backend:
cd backend npm run build npm start - Build and deploy the frontend:
cd web npm run build npm start
attendance/
βββ backend/
β βββ src/
β β βββ index.ts # Express server
β β βββ routes/ # API routes
β β βββ middleware/ # Auth middleware
β β βββ services/ # Business logic
β βββ prisma/
β β βββ schema.prisma # Database schema
β β βββ seed.ts # Seed data
β βββ docker-compose.yml
β βββ Dockerfile
βββ web/
β βββ app/ # Next.js pages
β βββ components/ # React components
β βββ lib/ # Utilities
βββ mobile/ # React Native app
βββ docs/ # Documentation
βββ screenshots/ # App screenshots
See docs/CONTRIBUTING.md for contribution guidelines.
- Fork the repository
- Create a feature branch:
git checkout -b feature/amazing-feature - Commit your changes:
git commit -m 'Add amazing feature' - Push to the branch:
git push origin feature/amazing-feature - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
Made with β€οΈ by Benoit Liard






