How imperio-cse/attendtrax works
AttendTrax is a role-based attendance management system. Admins maintain classes, students, subjects and faculty, and can import records; faculty select a class, subject and hour, submit attendance once for a slot, and view class reports; students view their profile and attendance summary. The browser pages use a shared API client to reach a FastAPI backend, which enforces roles and delegates attendance and records to Google Sheets. The README documents spreadsheet initialization and class-register formatting; their detailed runtime relationships are not fully shown in the excerpts.
Main entry points: main.py FastAPI app · sheets.py Sheets data operations · api.js API client · index.html Login page
Components 20
Web interface
- Login page
frontend/index.html - Admin dashboard
frontend/admin.html - Faculty dashboard
frontend/faculty.html - Student dashboard
frontend/student.html - API client
frontend/api.js
API and security
- FastAPI app
backend/main.py - Login and passwords
backend/routers/auth_router.py - JWT and hashing
backend/auth.py - Role guards
backend/dependencies.py - Backend settings
backend/config.py
Attendance workflows
- Attendance endpoints
backend/routers/faculty_router.py - Student endpoints
backend/routers/student_router.py
Records and reporting
- Admin management
backend/routers/admin_router.py - Sheets data operations
backend/sheets.py - Google Sheets
Sheets setup
- Sheet initializer
backend/setup_sheets.py - Daily register builder
backend/setup_daily_registers.py
Other components
- Administrator
- Faculty
- Student
Connections 26
- Administrator → Login page: signs in
README.md - Faculty → Login page: signs in
README.md - Student → Login page: signs in
README.md - Login page → API client: uses
- Admin dashboard → API client: uses
- Faculty dashboard → API client: uses
- Student dashboard → API client: uses
- API client → FastAPI app: sends API requests
README.md - FastAPI app → Login and passwords: registers
backend/main.py - FastAPI app → Attendance endpoints: registers
backend/main.py - FastAPI app → Student endpoints: registers
backend/main.py - FastAPI app → Admin management: registers
backend/main.py - FastAPI app → Backend settings: loads
backend/main.py - FastAPI app → Sheets data operations: warms cache
backend/main.py - Login and passwords → JWT and hashing: verifies and signs
backend/routers/auth_router.py - Login and passwords → Sheets data operations: looks up and updates users
backend/routers/auth_router.py - Role guards → JWT and hashing: decodes token
backend/dependencies.py - Role guards → Sheets data operations: looks up user
backend/dependencies.py - Role guards → Backend settings: checks admin
backend/dependencies.py - Admin management → Sheets data operations: manages records and imports
backend/routers/admin_router.py - Attendance endpoints → Sheets data operations: checks and saves attendance
backend/routers/faculty_router.py - Student endpoints → Sheets data operations: reads profile and summary
backend/routers/student_router.py - Sheets data operations → Google Sheets: reads and writes
README.md - Sheet initializer → Google Sheets: initializes spreadsheets
backend/setup_sheets.py - Daily register builder → Sheets data operations: reads attendance data
backend/setup_daily_registers.py - Daily register builder → Google Sheets: formats class registers
backend/setup_daily_registers.py