# danielredstudios/driveed-hub-capstone-project architecture

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

- Interactive diagram: https://gitdiagram.com/danielredstudios/driveed-hub-capstone-project
- Repository: https://github.com/danielredstudios/driveed-hub-capstone-project

## Overview

This is a multi-school driving-school training and operations platform. A learner’s main path is to browse courses, submit an enrollment request, complete payment and approval, then progress through lessons and scheduled practical sessions toward completion. School staff and instructors administer enrollment, scheduling, assessments, progress and reporting; system administrators manage schools and platform-wide operations. The graph reflects documented model relationships and sampled controller references, but most route wiring and several feature implementations were not excerpted, so those links are omitted rather than inferred.

Main entry points: [`app/Models/EnrollmentRequest.php`](https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Models/EnrollmentRequest.php) (Enrollment records), [`app/Http/Controllers/EnrollmentRequestController.php`](https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Http/Controllers/EnrollmentRequestController.php) (Enrollment requests), [`app/Http/Controllers/AdminController.php`](https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Http/Controllers/AdminController.php) (School administration), [`app/Models/School.php`](https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Models/School.php) (School tenant)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_intake["Access &amp; Enrollment"]
  node_enrollment_flow["Enrollment requests"]
  node_enrollment_store[("Enrollment records")]
end

subgraph group_learning["Training &amp; Progress"]
  node_course_catalog[("Courses<br/>[Course.php]")]
  node_student_records[("Learner records<br/>[Student.php]")]
  node_modules_lessons["Modules &amp; lessons"]
  node_assessments["Assessments"]
  node_progress[("Learning progress<br/>[Progress.php]")]
  node_phase[("Phase progression")]
end

subgraph group_operations["Scheduling &amp; Payments"]
  node_booking_controller["Booking workflow"]
  node_bookings[("Bookings<br/>[Booking.php]")]
  node_scheduling["Schedule conflicts"]
  node_slots[("Time slots<br/>[TimeSlot.php]")]
  node_session_completion[("Session completion")]
  node_payment_controller["Payment handling"]
  node_payments[("Payments<br/>[Payment.php]")]
  node_receipt_storage["Receipt storage"]
end

subgraph group_management["School Operations"]
  node_school_admin["School administration"]
  node_instructor[("Instructor records<br/>[Instructor.php]")]
  node_branch[("Branches<br/>[Branch.php]")]
  node_notifications[("Notifications<br/>[Notification.php]")]
  node_school[("School tenant<br/>[School.php]")]
end

subgraph group_platform["Platform Administration"]
  node_system_admin["Platform administration"]
  node_system_logs[("System logs<br/>[SystemLog.php]")]
  node_mail["Email delivery"]
end

node_learner(("Learner"))
node_instructor_actor(("Instructor"))
node_school_staff(("School staff"))

node_learner -->|"submits request"| node_enrollment_flow
node_enrollment_flow -->|"creates and updates"| node_enrollment_store
node_enrollment_flow -->|"sends status mail"| node_mail
node_enrollment_flow -->|"creates notifications"| node_notifications
node_enrollment_flow -->|"writes audit log"| node_system_logs
node_enrollment_store -->|"references learner"| node_student_records
node_enrollment_store -->|"references course"| node_course_catalog
node_enrollment_store -->|"has progress records"| node_progress
node_enrollment_store -->|"resolves progression"| node_phase
node_learner -.->|"browses courses"| node_course_catalog
node_course_catalog -.->|"provides course content"| node_modules_lessons
node_instructor_actor -.->|"manages assessments"| node_assessments
node_assessments -.->|"records outcomes"| node_progress
node_instructor_actor -.->|"manages sessions"| node_booking_controller
node_booking_controller -.->|"creates bookings"| node_bookings
node_booking_controller -.->|"checks conflicts"| node_scheduling
node_scheduling -->|"checks availability"| node_slots
node_bookings -->|"references time slot"| node_slots
node_instructor_actor -.->|"records completion"| node_session_completion
node_school_staff -.->|"reviews payment"| node_payment_controller
node_payment_controller -.->|"records payment"| node_payments
node_payment_controller -.->|"stores receipt"| node_receipt_storage
node_payments -->|"may reference booking"| node_bookings
node_payments -->|"may reference request"| node_enrollment_store
node_school_staff -.->|"administers school"| node_school_admin
node_school_admin -.->|"manages branches"| node_branch
node_school_admin -.->|"manages instructors"| node_instructor
node_school_admin -.->|"manages courses"| node_course_catalog
node_school_admin -.->|"reviews enrollment"| node_enrollment_flow
node_school -->|"owns courses"| node_course_catalog
node_school -->|"owns requests"| node_enrollment_store
node_school -->|"owns branches"| node_branch
node_school -.->|"owns instructors"| node_instructor
node_system_admin -.->|"manages tenants"| node_school

click node_enrollment_flow "https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Http/Controllers/EnrollmentRequestController.php"
click node_enrollment_store "https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Models/EnrollmentRequest.php"
click node_course_catalog "https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Models/Course.php"
click node_student_records "https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Models/Student.php"
click node_modules_lessons "https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Http/Controllers/ModuleLessonController.php"
click node_assessments "https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Http/Controllers/AssessmentController.php"
click node_progress "https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Models/Progress.php"
click node_phase "https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Models/PhaseProgression.php"
click node_booking_controller "https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Http/Controllers/BookingController.php"
click node_bookings "https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Models/Booking.php"
click node_scheduling "https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Services/SchedulingConflictService.php"
click node_slots "https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Models/TimeSlot.php"
click node_session_completion "https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Models/SessionCompletion.php"
click node_payment_controller "https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Http/Controllers/PaymentController.php"
click node_payments "https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Models/Payment.php"
click node_receipt_storage "https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Services/ReceiptStorageService.php"
click node_school_admin "https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Http/Controllers/AdminController.php"
click node_instructor "https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Models/Instructor.php"
click node_branch "https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Models/Branch.php"
click node_notifications "https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Models/Notification.php"
click node_school "https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Models/School.php"
click node_system_admin "https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Http/Controllers/SystemAdminController.php"
click node_system_logs "https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Models/SystemLog.php"
click node_mail "https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Mail/EnrollmentApproved.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_enrollment_flow,node_enrollment_store toneBlue
class node_course_catalog,node_student_records,node_modules_lessons,node_assessments,node_progress,node_phase toneAmber
class node_booking_controller,node_bookings,node_scheduling,node_slots,node_session_completion,node_payment_controller,node_payments,node_receipt_storage toneMint
class node_school_admin,node_instructor,node_branch,node_notifications,node_school toneRose
class node_system_admin,node_system_logs,node_mail,node_learner,node_instructor_actor,node_school_staff toneIndigo
```

## Components

### Access & Enrollment

- [Enrollment requests](https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Http/Controllers/EnrollmentRequestController.php): `app/Http/Controllers/EnrollmentRequestController.php`
- [Enrollment records](https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Models/EnrollmentRequest.php): `app/Models/EnrollmentRequest.php`

### Training & Progress

- [Courses](https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Models/Course.php): `app/Models/Course.php`
- [Learner records](https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Models/Student.php): `app/Models/Student.php`
- [Modules & lessons](https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Http/Controllers/ModuleLessonController.php): `app/Http/Controllers/ModuleLessonController.php`
- [Assessments](https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Http/Controllers/AssessmentController.php): `app/Http/Controllers/AssessmentController.php`
- [Learning progress](https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Models/Progress.php): `app/Models/Progress.php`
- [Phase progression](https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Models/PhaseProgression.php): `app/Models/PhaseProgression.php`

### Scheduling & Payments

- [Booking workflow](https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Http/Controllers/BookingController.php): `app/Http/Controllers/BookingController.php`
- [Bookings](https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Models/Booking.php): `app/Models/Booking.php`
- [Schedule conflicts](https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Services/SchedulingConflictService.php): `app/Services/SchedulingConflictService.php`
- [Time slots](https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Models/TimeSlot.php): `app/Models/TimeSlot.php`
- [Session completion](https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Models/SessionCompletion.php): `app/Models/SessionCompletion.php`
- [Payment handling](https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Http/Controllers/PaymentController.php): `app/Http/Controllers/PaymentController.php`
- [Payments](https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Models/Payment.php): `app/Models/Payment.php`
- [Receipt storage](https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Services/ReceiptStorageService.php): `app/Services/ReceiptStorageService.php`

### School Operations

- [School administration](https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Http/Controllers/AdminController.php): `app/Http/Controllers/AdminController.php`
- [Instructor records](https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Models/Instructor.php): `app/Models/Instructor.php`
- [Branches](https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Models/Branch.php): `app/Models/Branch.php`
- [Notifications](https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Models/Notification.php): `app/Models/Notification.php`
- [School tenant](https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Models/School.php): `app/Models/School.php`

### Platform Administration

- [Platform administration](https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Http/Controllers/SystemAdminController.php): `app/Http/Controllers/SystemAdminController.php`
- [System logs](https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Models/SystemLog.php): `app/Models/SystemLog.php`
- [Email delivery](https://github.com/danielredstudios/driveed-hub-capstone-project/blob/main/app/Mail/EnrollmentApproved.php): `app/Mail/EnrollmentApproved.php`

### Other components

- **Learner**
- **Instructor**
- **School staff**

## Connections

- Learner → Enrollment requests: submits request (evidence: `app/Http/Controllers/EnrollmentRequestController.php`)
- Enrollment requests → Enrollment records: creates and updates (evidence: `app/Http/Controllers/EnrollmentRequestController.php`)
- Enrollment requests → Email delivery: sends status mail (evidence: `app/Http/Controllers/EnrollmentRequestController.php`)
- Enrollment requests → Notifications: creates notifications (evidence: `app/Http/Controllers/EnrollmentRequestController.php`)
- Enrollment requests → System logs: writes audit log (evidence: `app/Http/Controllers/EnrollmentRequestController.php`)
- Enrollment records → Learner records: references learner (evidence: `app/Models/EnrollmentRequest.php`)
- Enrollment records → Courses: references course (evidence: `app/Models/EnrollmentRequest.php`)
- Enrollment records → Learning progress: has progress records (evidence: `app/Models/EnrollmentRequest.php`)
- Enrollment records → Phase progression: resolves progression (evidence: `app/Models/EnrollmentRequest.php`)
- Learner → Courses: browses courses
- Courses → Modules & lessons: provides course content
- Instructor → Assessments: manages assessments
- Assessments → Learning progress: records outcomes
- Instructor → Booking workflow: manages sessions
- Booking workflow → Bookings: creates bookings
- Booking workflow → Schedule conflicts: checks conflicts
- Schedule conflicts → Time slots: checks availability (evidence: `app/Services/SchedulingConflictService.php`)
- Bookings → Time slots: references time slot (evidence: `app/Models/Booking.php`)
- Instructor → Session completion: records completion
- School staff → Payment handling: reviews payment
- Payment handling → Payments: records payment
- Payment handling → Receipt storage: stores receipt
- Payments → Bookings: may reference booking (evidence: `app/Models/Payment.php`)
- Payments → Enrollment records: may reference request (evidence: `app/Models/Payment.php`)
- School staff → School administration: administers school
- School administration → Branches: manages branches (evidence: `app/Http/Controllers/AdminController.php`)
- School administration → Instructor records: manages instructors (evidence: `app/Http/Controllers/AdminController.php`)
- School administration → Courses: manages courses (evidence: `app/Http/Controllers/AdminController.php`)
- School administration → Enrollment requests: reviews enrollment
- School tenant → Courses: owns courses (evidence: `app/Models/School.php`)
- School tenant → Enrollment records: owns requests (evidence: `app/Models/School.php`)
- School tenant → Branches: owns branches (evidence: `app/Models/School.php`)
- School tenant → Instructor records: owns instructors (evidence: `app/Models/School.php`)
- Platform administration → School tenant: manages tenants
