# mdarkhan/masudalimi-lms architecture

> Architecture diagram of the GitHub repository mdarkhan/masudalimi-lms, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-19). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/mdarkhan/masudalimi-lms
- Repository: https://github.com/mdarkhan/masudalimi-lms

## Overview

Masud Alimi is a Laravel Islamic learning and examination platform. Students authenticate, study courses, take scheduled official exams or free practice quizzes, then review released results and rankings; administrators manage content, learners, quizzes, and results. The map also preserves the public knowledge and calendar features and supporting communication, points, and migration capabilities. Relationships are limited to README statements and visible source-index references; unsampled feature links are omitted rather than inferred.

Main entry points: [`app/Services/Quiz/QuizAttemptService.php`](https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Services/Quiz/QuizAttemptService.php) (Attempt lifecycle), [`app/Http/Controllers/Student/DashboardController.php`](https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Http/Controllers/Student/DashboardController.php) (Student dashboard), [`app/Http/Controllers/Student/ExamAttemptController.php`](https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Http/Controllers/Student/ExamAttemptController.php) (Exam access), [`app/Http/Controllers/Admin/StudentController.php`](https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Http/Controllers/Admin/StudentController.php) (Student management)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_access["Access and learning"]
  node_login["Authentication"]
  node_dashboard["Student dashboard"]
  node_courses["Course archive<br/>[Course.php]"]
  node_progress["Lesson progress"]
end

subgraph group_assessment["Exams and results"]
  node_attempt_controller["Exam access"]
  node_attempt_service["Attempt lifecycle"]
  node_quiz["Quiz rules<br/>[Quiz.php]"]
  node_scoring["Quiz scoring"]
  node_attempt_data[("Attempts and answers<br/>[QuizAttempt.php]")]
  node_results["Results and regrade"]
  node_leaderboard["Leaderboards"]
  node_practice["Practice mode"]
end

subgraph group_admin["Administration"]
  node_admin_students["Student management"]
  node_admin_quiz["Quiz authoring<br/>[QuizController.php]"]
  node_imports["Legacy imports"]
end

subgraph group_public["Public knowledge"]
  node_public_site["Public site and CMS"]
  node_ask["Ask Ustaz"]
  node_zakat["Zakat calculator"]
  node_calendar["Calendar"]
end

subgraph group_services["Shared services"]
  node_points[("Points ledger<br/>[PointService.php]")]
  node_audit["Audit logging<br/>[AuditLogger.php]"]
  node_messaging["Messaging<br/>[MessageService.php]"]
  node_notifications["Notifications"]
  node_settings[("Settings<br/>[SettingService.php]")]
end

node_student(("Student"))
node_admin_actor(("Administrator"))
node_email{{"Email service"}}

node_student -->|"signs in"| node_login
node_student -->|"opens"| node_dashboard
node_dashboard -->|"loads progress"| node_progress
node_student -->|"studies"| node_courses
node_student -->|"starts exam"| node_attempt_controller
node_attempt_controller -.->|"manages attempt"| node_attempt_service
node_attempt_service -->|"checks availability"| node_quiz
node_attempt_service -->|"scores answers"| node_scoring
node_attempt_service -->|"persists answers"| node_attempt_data
node_student -->|"practices"| node_practice
node_student -->|"reviews results"| node_results
node_student -->|"views rankings"| node_leaderboard
node_admin_actor -->|"manages learners"| node_admin_students
node_admin_actor -->|"authors quizzes"| node_admin_quiz
node_admin_actor -->|"adjusts results"| node_results
node_admin_actor -->|"imports records"| node_imports
node_student -->|"reads content"| node_public_site
node_student -->|"submits question"| node_ask
node_ask -->|"sends email"| node_email
node_student -->|"calculates zakat"| node_zakat
node_public_site -->|"shows date"| node_calendar
node_attempt_service -->|"debits points"| node_points
node_admin_students -->|"records changes"| node_audit
node_messaging -->|"dispatches notices"| node_notifications
node_calendar -->|"reads settings"| node_settings

click node_login "https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Http/Controllers/Auth/LoginController.php"
click node_dashboard "https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Http/Controllers/Student/DashboardController.php"
click node_courses "https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Models/Course.php"
click node_progress "https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Services/Progress/LessonProgressService.php"
click node_attempt_controller "https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Http/Controllers/Student/ExamAttemptController.php"
click node_attempt_service "https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Services/Quiz/QuizAttemptService.php"
click node_quiz "https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Models/Quiz.php"
click node_scoring "https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Services/Quiz/QuizScoringService.php"
click node_attempt_data "https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Models/QuizAttempt.php"
click node_results "https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Http/Controllers/Admin/ResultController.php"
click node_leaderboard "https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Services/Quiz/LeaderboardService.php"
click node_practice "https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Http/Controllers/Student/PracticeController.php"
click node_admin_students "https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Http/Controllers/Admin/StudentController.php"
click node_admin_quiz "https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Http/Controllers/Admin/QuizController.php"
click node_imports "https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Services/Import/LegacyResultImporter.php"
click node_public_site "https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Http/Controllers/PublicController.php"
click node_ask "https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Http/Controllers/AskUstazController.php"
click node_zakat "https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Services/Zakat/ZakatCalculatorService.php"
click node_calendar "https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Services/Calendar/CalendarService.php"
click node_points "https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Services/Points/PointService.php"
click node_audit "https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Services/Audit/AuditLogger.php"
click node_messaging "https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Services/Messaging/MessageService.php"
click node_notifications "https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Services/Notifications/NotificationService.php"
click node_settings "https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Services/Settings/SettingService.php"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_login,node_dashboard,node_courses,node_progress toneBlue
class node_attempt_controller,node_attempt_service,node_quiz,node_scoring,node_attempt_data,node_results,node_leaderboard,node_practice toneAmber
class node_admin_students,node_admin_quiz,node_imports toneMint
class node_public_site,node_ask,node_zakat,node_calendar toneRose
class node_points,node_audit,node_messaging,node_notifications,node_settings,node_student,node_admin_actor,node_email toneIndigo
```

## Components

### Access and learning

- [Authentication](https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Http/Controllers/Auth/LoginController.php): `app/Http/Controllers/Auth/LoginController.php`
- [Student dashboard](https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Http/Controllers/Student/DashboardController.php): `app/Http/Controllers/Student/DashboardController.php`
- [Course archive](https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Models/Course.php): `app/Models/Course.php`
- [Lesson progress](https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Services/Progress/LessonProgressService.php): `app/Services/Progress/LessonProgressService.php`

### Exams and results

- [Exam access](https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Http/Controllers/Student/ExamAttemptController.php): `app/Http/Controllers/Student/ExamAttemptController.php`
- [Attempt lifecycle](https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Services/Quiz/QuizAttemptService.php): `app/Services/Quiz/QuizAttemptService.php`
- [Quiz rules](https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Models/Quiz.php): `app/Models/Quiz.php`
- [Quiz scoring](https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Services/Quiz/QuizScoringService.php): `app/Services/Quiz/QuizScoringService.php`
- [Attempts and answers](https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Models/QuizAttempt.php): `app/Models/QuizAttempt.php`
- [Results and regrade](https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Http/Controllers/Admin/ResultController.php): `app/Http/Controllers/Admin/ResultController.php`
- [Leaderboards](https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Services/Quiz/LeaderboardService.php): `app/Services/Quiz/LeaderboardService.php`
- [Practice mode](https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Http/Controllers/Student/PracticeController.php): `app/Http/Controllers/Student/PracticeController.php`

### Administration

- [Student management](https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Http/Controllers/Admin/StudentController.php): `app/Http/Controllers/Admin/StudentController.php`
- [Quiz authoring](https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Http/Controllers/Admin/QuizController.php): `app/Http/Controllers/Admin/QuizController.php`
- [Legacy imports](https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Services/Import/LegacyResultImporter.php): `app/Services/Import/LegacyResultImporter.php`

### Public knowledge

- [Public site and CMS](https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Http/Controllers/PublicController.php): `app/Http/Controllers/PublicController.php`
- [Ask Ustaz](https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Http/Controllers/AskUstazController.php): `app/Http/Controllers/AskUstazController.php`
- [Zakat calculator](https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Services/Zakat/ZakatCalculatorService.php): `app/Services/Zakat/ZakatCalculatorService.php`
- [Calendar](https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Services/Calendar/CalendarService.php): `app/Services/Calendar/CalendarService.php`

### Shared services

- [Points ledger](https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Services/Points/PointService.php): `app/Services/Points/PointService.php`
- [Audit logging](https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Services/Audit/AuditLogger.php): `app/Services/Audit/AuditLogger.php`
- [Messaging](https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Services/Messaging/MessageService.php): `app/Services/Messaging/MessageService.php`
- [Notifications](https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Services/Notifications/NotificationService.php): `app/Services/Notifications/NotificationService.php`
- [Settings](https://github.com/mdarkhan/masudalimi-lms/blob/main/app/Services/Settings/SettingService.php): `app/Services/Settings/SettingService.php`

### Other components

- **Student**
- **Administrator**
- **Email service**

## Connections

- Student → Authentication: signs in (evidence: `README.md`)
- Student → Student dashboard: opens (evidence: `README.md`)
- Student dashboard → Lesson progress: loads progress (evidence: `app/Http/Controllers/Student/DashboardController.php`)
- Student → Course archive: studies (evidence: `README.md`)
- Student → Exam access: starts exam (evidence: `README.md`)
- Exam access → Attempt lifecycle: manages attempt
- Attempt lifecycle → Quiz rules: checks availability (evidence: `app/Services/Quiz/QuizAttemptService.php`)
- Attempt lifecycle → Quiz scoring: scores answers (evidence: `app/Services/Quiz/QuizAttemptService.php`)
- Attempt lifecycle → Attempts and answers: persists answers (evidence: `app/Services/Quiz/QuizAttemptService.php`)
- Student → Practice mode: practices (evidence: `README.md`)
- Student → Results and regrade: reviews results (evidence: `README.md`)
- Student → Leaderboards: views rankings (evidence: `README.md`)
- Administrator → Student management: manages learners (evidence: `README.md`)
- Administrator → Quiz authoring: authors quizzes (evidence: `README.md`)
- Administrator → Results and regrade: adjusts results (evidence: `README.md`)
- Administrator → Legacy imports: imports records (evidence: `README.md`)
- Student → Public site and CMS: reads content (evidence: `README.md`)
- Student → Ask Ustaz: submits question (evidence: `README.md`)
- Ask Ustaz → Email service: sends email (evidence: `app/Http/Controllers/AskUstazController.php`)
- Student → Zakat calculator: calculates zakat (evidence: `README.md`)
- Public site and CMS → Calendar: shows date (evidence: `README.md`)
- Attempt lifecycle → Points ledger: debits points (evidence: `app/Services/Quiz/QuizAttemptService.php`)
- Student management → Audit logging: records changes (evidence: `app/Http/Controllers/Admin/StudentController.php`)
- Messaging → Notifications: dispatches notices (evidence: `app/Services/Messaging/MessageService.php`)
- Calendar → Settings: reads settings (evidence: `app/Services/Calendar/CalendarService.php`)
