# asimomran/internship architecture

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

- Interactive diagram: https://gitdiagram.com/asimomran/internship
- Repository: https://github.com/asimomran/internship

## Overview

CourseTrack is a learning platform for student course enrollment and progress tracking, with admin course management and analytics. The main flow is sign-in, enroll or open a course, record module/video activity, and view updated progress; admins create courses and review platform metrics. The graph follows the React app through Spring controllers and the shared course-tracking service to JPA repositories. README details are minimal, and some controller/service wiring is inferred only where the sampled code or UI explicitly supports the capability.

Main entry points: [`frontend/src/App.jsx`](https://github.com/asimomran/internship/blob/main/frontend/src/App.jsx) (App and Routing), [`frontend/src/lib/api.js`](https://github.com/asimomran/internship/blob/main/frontend/src/lib/api.js) (API Client), [`backend/src/main/java/com/learnflow/backend/services/CourseTrackService.java`](https://github.com/asimomran/internship/blob/main/backend/src/main/java/com/learnflow/backend/services/CourseTrackService.java) (Course Tracking), [`backend/src/main/java/com/learnflow/backend/repositories`](https://github.com/asimomran/internship/tree/main/backend/src/main/java/com/learnflow/backend/repositories) (JPA Repositories)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_frontend["Learner and Admin UI"]
  node_app["App and Routing<br/>[App.jsx]"]
  node_auth_ui["Sign-in UI<br/>[AuthScreen.jsx]"]
  node_student_ui["Student Dashboard"]
  node_course_ui["Course Detail<br/>[CourseDetail.jsx]"]
  node_admin_ui["Admin Dashboard<br/>[AdminDashboard.jsx]"]
  node_api_client["API Client<br/>[api.js]"]
end

subgraph group_identity["Identity and Access"]
  node_auth_controller["Authentication"]
  node_security["JWT Security"]
  node_user_details["User Lookup"]
end

subgraph group_learning["Course and Learning"]
  node_course_controller["Course Catalog"]
  node_enrollment_controller["Enrollment"]
  node_session_controller["Study Sessions"]
  node_progress_controller["Progress Updates"]
  node_track_service["Course Tracking"]
end

subgraph group_insights["Progress and Analytics"]
  node_dashboard_controller["Dashboard API"]
end

subgraph group_data["Persistence"]
  node_repositories["JPA Repositories"]
  node_database[("Application Database")]
end

node_learner(("Learner"))
node_administrator(("Administrator"))

node_learner -->|"signs in"| node_auth_ui
node_administrator -->|"signs in"| node_auth_ui
node_auth_ui -->|"submits credentials"| node_app
node_app -->|"requests"| node_api_client
node_api_client -->|"calls auth API"| node_auth_controller
node_auth_controller -->|"reads and saves users"| node_repositories
node_auth_controller -->|"builds session user"| node_track_service
node_auth_controller -->|"authenticates and issues JWT"| node_security
node_security -->|"loads account"| node_user_details
node_user_details -->|"finds user"| node_repositories
node_app -->|"renders learner view"| node_student_ui
node_app -->|"renders admin view"| node_admin_ui
node_app -->|"renders course view"| node_course_ui
node_learner -->|"views dashboard"| node_student_ui
node_administrator -->|"manages courses"| node_admin_ui
node_student_ui -->|"opens course"| node_app
node_course_ui -->|"submits activity"| node_app
node_app -->|"loads and updates data"| node_api_client
node_api_client -->|"requests courses"| node_course_controller
node_api_client -->|"enrolls learner"| node_enrollment_controller
node_enrollment_controller -->|"reads and saves enrollment"| node_repositories
node_api_client -->|"updates module or video"| node_progress_controller
node_progress_controller -->|"delegates progress"| node_track_service
node_api_client -->|"records study time"| node_session_controller
node_session_controller -->|"reads and saves sessions"| node_repositories
node_course_controller -->|"serves course details"| node_track_service
node_track_service -->|"reads and updates learning data"| node_repositories
node_app -->|"loads dashboard"| node_dashboard_controller
node_dashboard_controller -->|"requests metrics"| node_track_service
node_track_service -->|"returns summaries"| node_dashboard_controller
node_repositories -->|"persists entities"| node_database

click node_app "https://github.com/asimomran/internship/blob/main/frontend/src/App.jsx"
click node_auth_ui "https://github.com/asimomran/internship/blob/main/frontend/src/components/AuthScreen.jsx"
click node_student_ui "https://github.com/asimomran/internship/blob/main/frontend/src/components/StudentDashboard.jsx"
click node_course_ui "https://github.com/asimomran/internship/blob/main/frontend/src/components/CourseDetail.jsx"
click node_admin_ui "https://github.com/asimomran/internship/blob/main/frontend/src/components/AdminDashboard.jsx"
click node_api_client "https://github.com/asimomran/internship/blob/main/frontend/src/lib/api.js"
click node_auth_controller "https://github.com/asimomran/internship/blob/main/backend/src/main/java/com/learnflow/backend/controllers/AuthController.java"
click node_security "https://github.com/asimomran/internship/blob/main/backend/src/main/java/com/learnflow/backend/security/SecurityConfig.java"
click node_user_details "https://github.com/asimomran/internship/blob/main/backend/src/main/java/com/learnflow/backend/security/UserDetailsServiceImpl.java"
click node_course_controller "https://github.com/asimomran/internship/blob/main/backend/src/main/java/com/learnflow/backend/controllers/CourseController.java"
click node_enrollment_controller "https://github.com/asimomran/internship/blob/main/backend/src/main/java/com/learnflow/backend/controllers/EnrollmentController.java"
click node_session_controller "https://github.com/asimomran/internship/blob/main/backend/src/main/java/com/learnflow/backend/controllers/SessionController.java"
click node_progress_controller "https://github.com/asimomran/internship/blob/main/backend/src/main/java/com/learnflow/backend/controllers/ProgressController.java"
click node_track_service "https://github.com/asimomran/internship/blob/main/backend/src/main/java/com/learnflow/backend/services/CourseTrackService.java"
click node_dashboard_controller "https://github.com/asimomran/internship/blob/main/backend/src/main/java/com/learnflow/backend/controllers/DashboardController.java"
click node_repositories "https://github.com/asimomran/internship/tree/main/backend/src/main/java/com/learnflow/backend/repositories"

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_app,node_auth_ui,node_student_ui,node_course_ui,node_admin_ui,node_api_client toneBlue
class node_auth_controller,node_security,node_user_details toneAmber
class node_course_controller,node_enrollment_controller,node_session_controller,node_progress_controller,node_track_service toneMint
class node_dashboard_controller toneRose
class node_repositories,node_database,node_learner,node_administrator toneIndigo
```

## Components

### Learner and Admin UI

- [App and Routing](https://github.com/asimomran/internship/blob/main/frontend/src/App.jsx): `frontend/src/App.jsx`
- [Sign-in UI](https://github.com/asimomran/internship/blob/main/frontend/src/components/AuthScreen.jsx): `frontend/src/components/AuthScreen.jsx`
- [Student Dashboard](https://github.com/asimomran/internship/blob/main/frontend/src/components/StudentDashboard.jsx): `frontend/src/components/StudentDashboard.jsx`
- [Course Detail](https://github.com/asimomran/internship/blob/main/frontend/src/components/CourseDetail.jsx): `frontend/src/components/CourseDetail.jsx`
- [Admin Dashboard](https://github.com/asimomran/internship/blob/main/frontend/src/components/AdminDashboard.jsx): `frontend/src/components/AdminDashboard.jsx`
- [API Client](https://github.com/asimomran/internship/blob/main/frontend/src/lib/api.js): `frontend/src/lib/api.js`

### Identity and Access

- [Authentication](https://github.com/asimomran/internship/blob/main/backend/src/main/java/com/learnflow/backend/controllers/AuthController.java): `backend/src/main/java/com/learnflow/backend/controllers/AuthController.java`
- [JWT Security](https://github.com/asimomran/internship/blob/main/backend/src/main/java/com/learnflow/backend/security/SecurityConfig.java): `backend/src/main/java/com/learnflow/backend/security/SecurityConfig.java`
- [User Lookup](https://github.com/asimomran/internship/blob/main/backend/src/main/java/com/learnflow/backend/security/UserDetailsServiceImpl.java): `backend/src/main/java/com/learnflow/backend/security/UserDetailsServiceImpl.java`

### Course and Learning

- [Course Catalog](https://github.com/asimomran/internship/blob/main/backend/src/main/java/com/learnflow/backend/controllers/CourseController.java): `backend/src/main/java/com/learnflow/backend/controllers/CourseController.java`
- [Enrollment](https://github.com/asimomran/internship/blob/main/backend/src/main/java/com/learnflow/backend/controllers/EnrollmentController.java): `backend/src/main/java/com/learnflow/backend/controllers/EnrollmentController.java`
- [Study Sessions](https://github.com/asimomran/internship/blob/main/backend/src/main/java/com/learnflow/backend/controllers/SessionController.java): `backend/src/main/java/com/learnflow/backend/controllers/SessionController.java`
- [Progress Updates](https://github.com/asimomran/internship/blob/main/backend/src/main/java/com/learnflow/backend/controllers/ProgressController.java): `backend/src/main/java/com/learnflow/backend/controllers/ProgressController.java`
- [Course Tracking](https://github.com/asimomran/internship/blob/main/backend/src/main/java/com/learnflow/backend/services/CourseTrackService.java): `backend/src/main/java/com/learnflow/backend/services/CourseTrackService.java`

### Progress and Analytics

- [Dashboard API](https://github.com/asimomran/internship/blob/main/backend/src/main/java/com/learnflow/backend/controllers/DashboardController.java): `backend/src/main/java/com/learnflow/backend/controllers/DashboardController.java`

### Persistence

- [JPA Repositories](https://github.com/asimomran/internship/tree/main/backend/src/main/java/com/learnflow/backend/repositories): `backend/src/main/java/com/learnflow/backend/repositories`
- **Application Database**

### Other components

- **Learner**
- **Administrator**

## Connections

- Learner → Sign-in UI: signs in
- Administrator → Sign-in UI: signs in
- Sign-in UI → App and Routing: submits credentials
- App and Routing → API Client: requests
- API Client → Authentication: calls auth API
- Authentication → JPA Repositories: reads and saves users
- Authentication → Course Tracking: builds session user
- Authentication → JWT Security: authenticates and issues JWT
- JWT Security → User Lookup: loads account
- User Lookup → JPA Repositories: finds user
- App and Routing → Student Dashboard: renders learner view
- App and Routing → Admin Dashboard: renders admin view
- App and Routing → Course Detail: renders course view
- Learner → Student Dashboard: views dashboard
- Administrator → Admin Dashboard: manages courses
- Student Dashboard → App and Routing: opens course
- Course Detail → App and Routing: submits activity
- App and Routing → API Client: loads and updates data
- API Client → Course Catalog: requests courses
- API Client → Enrollment: enrolls learner
- Enrollment → JPA Repositories: reads and saves enrollment
- API Client → Progress Updates: updates module or video
- Progress Updates → Course Tracking: delegates progress
- API Client → Study Sessions: records study time
- Study Sessions → JPA Repositories: reads and saves sessions
- Course Catalog → Course Tracking: serves course details
- Course Tracking → JPA Repositories: reads and updates learning data
- App and Routing → Dashboard API: loads dashboard
- Dashboard API → Course Tracking: requests metrics
- Course Tracking → Dashboard API: returns summaries
- JPA Repositories → Application Database: persists entities
