How mohamad8alkhatib/med-clinic works
This is a Laravel clinic appointment application. Patients browse active doctors and book or cancel appointments; doctors review appointments and manage their status; administrators manage doctors and specialties and view reports. Authentication and role-based access support these workflows. The graph emphasizes sampled controller/model behavior; some routes and screens are represented by directory paths because their implementation was not sampled, so those connections are dashed and unverified.
Main entry points: Doctor.php Doctor records · Appointment.php Appointments · User.php User accounts · Admin Doctor and specialty administration
Components 20
Access and identity
- Authentication
app/Http/Controllers/Auth - Login validation
app/Http/Requests/Auth/LoginRequest.php - Role access control
app/Http/Middleware/RoleMiddleware.php - Profile management
app/Http/Controllers/ProfileController.php
Appointment workflows
- Patient booking
app/Http/Controllers/Patient/PatientController.php - Doctor appointment management
app/Http/Controllers/Doctor/DoctorManagerController.php - Appointment screens
resources/views/patient/appointments - Doctor dashboard
resources/views/doctor/dashboard.blade.php
Clinic administration
- Doctor and specialty administration
app/Http/Controllers/Admin - Admin screens and reports
resources/views/admin
Domain and data
- User accounts
app/Models/User.php - Doctor records
app/Models/Doctor.php - Specialties
app/Models/Specialty.php - Doctor schedules
app/Models/DoctorSchedule.php - Appointments
app/Models/Appointment.php - Sample data seeding
database/seeders/DatabaseSeeder.php - Patient factory
database/factories/PatientFactory.php
Other components
- Patient
- Doctor
- Administrator
Connections 28
- Patient → Patient booking: books or cancels
- Patient booking → Appointments: creates and reads
app/Http/Controllers/Patient/PatientController.php - Patient booking → Doctor records: checks availability
app/Http/Controllers/Patient/PatientController.php - Patient booking → Appointment screens: renders
app/Http/Controllers/Patient/PatientController.php - Doctor → Doctor appointment management: manages appointments
- Doctor appointment management → Appointments: reads and updates
app/Http/Controllers/Doctor/DoctorManagerController.php - Doctor appointment management → Doctor dashboard: renders
app/Http/Controllers/Doctor/DoctorManagerController.php - Administrator → Doctor and specialty administration: administers clinic
- Doctor and specialty administration → Doctor records: manages
app/Http/Controllers/Admin/DoctorController.php - Doctor and specialty administration → Specialties: manages
app/Http/Controllers/Admin/SpecialtyController.php - Doctor and specialty administration → User accounts: creates and updates
app/Http/Controllers/Admin/DoctorController.php - Doctor and specialty administration → Appointments: reports on
app/Http/Controllers/Admin/AdminController.php - Doctor and specialty administration → Admin screens and reports: renders
- Authentication → Login validation: authenticates with
app/Http/Controllers/Auth/AuthenticatedSessionController.php - Authentication → User accounts: registers users
app/Http/Controllers/Auth/RegisteredUserController.php - Authentication → User accounts: auth routes target
app/Http/Controllers/Auth/RegisteredUserController.php - Profile management → User accounts: updates account
- User accounts → Doctor records: has doctor profile
app/Models/User.php - User accounts → Appointments: has patient appointments
app/Models/User.php - Doctor records → Specialties: belongs to
app/Models/Doctor.php - Doctor records → Doctor schedules: has schedules
app/Models/Doctor.php - Doctor records → Appointments: has appointments
app/Models/Doctor.php - Appointments → User accounts: belongs to patient
app/Models/Appointment.php - Appointments → Doctor records: belongs to doctor
app/Models/Appointment.php - Sample data seeding → Appointments: seeds sample records
- Sample data seeding → Doctor records: seeds sample records
- Sample data seeding → Specialties: seeds sample records
- Sample data seeding → Patient factory: calls patient seeder
database/seeders/DatabaseSeeder.php