# programmersagara-cell/mytara architecture

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

- Interactive diagram: https://gitdiagram.com/programmersagara-cell/mytara
- Repository: https://github.com/programmersagara-cell/mytara

## Overview

ITSaAMS is a PHP IT asset and service-management application. Users enter through the web front controller, authenticate, and use role-appropriate screens to manage assets or submit and track IT concerns; administrators accept, repair, and complete tickets. The product also documents topology, audit history, analytics, licensing, department and user management, messaging, and import/export. The map combines documented capabilities with source-index references and excerpts; several feature implementations were not sampled, so their internal call paths are omitted.

Main entry points: [`src/Models/Asset.php`](https://github.com/programmersagara-cell/mytara/blob/main/src/Models/Asset.php) (Asset records), [`src/Services/AuditService.php`](https://github.com/programmersagara-cell/mytara/blob/main/src/Services/AuditService.php) (Audit history), [`src/Services/TicketService.php`](https://github.com/programmersagara-cell/mytara/blob/main/src/Services/TicketService.php) (Ticket operations), [`src/Core/Database.php`](https://github.com/programmersagara-cell/mytara/blob/main/src/Core/Database.php) (PDO database)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_entry["Web and access"]
  node_front["Web entry<br/>[index.php]"]
  node_router["Route dispatch<br/>[Router.php]"]
  node_auth["Authentication<br/>[AuthService.php]"]
end

subgraph group_assets["Asset operations"]
  node_assets_ui["Asset management"]
  node_asset_model["Asset records<br/>[Asset.php]"]
  node_topology["Network topology"]
  node_disposal["Asset disposal"]
end

subgraph group_service["IT service workflow"]
  node_ticket_ui["Ticket workflow"]
  node_ticket_service["Ticket operations<br/>[TicketService.php]"]
  node_ticket_model["Concern records<br/>[Concern.php]"]
  node_notifications["Ticket notifications"]
  node_mail["Mail queue"]
end

subgraph group_insight["Administration and insight"]
  node_dashboard["Dashboard analytics"]
  node_history["Audit history<br/>[AuditService.php]"]
  node_departments["Departments<br/>[Department.php]"]
  node_users["User administration<br/>[UserController.php]"]
  node_licenses["Software licensing"]
  node_messages["Internal messaging"]
end

subgraph group_runtime["Application runtime"]
  node_view["View rendering<br/>[View.php]"]
  node_controller["Controller base<br/>[Controller.php]"]
  node_database[("PDO database<br/>[Database.php]")]
end

node_user(("User"))
node_mysql[("MySQL / MariaDB")]

node_user -->|"submits requests"| node_front
node_front -->|"boots"| node_router
node_router -->|"dispatches"| node_controller
node_router -.->|"routes to"| node_auth
node_auth -.->|"authenticates users"| node_users
node_controller -->|"renders pages"| node_view
node_assets_ui -->|"creates records"| node_asset_model
node_assets_ui -->|"logs changes"| node_history
node_assets_ui -->|"loads options"| node_departments
node_topology -.->|"uses assets"| node_asset_model
node_disposal -->|"manages retirement"| node_asset_model
node_ticket_ui -->|"handles workflow"| node_ticket_service
node_ticket_ui -->|"logs actions"| node_history
node_ticket_service -->|"updates concerns"| node_ticket_model
node_ticket_service -->|"records notifications"| node_notifications
node_ticket_service -->|"queues email"| node_mail
node_dashboard -->|"summarizes assets"| node_asset_model
node_dashboard -.->|"shows activity"| node_history
node_licenses -->|"audits changes"| node_history
node_asset_model -->|"queries through"| node_database
node_ticket_model -->|"queries through"| node_database
node_history -->|"persists audit log"| node_database
node_database -->|"stores records"| node_mysql

click node_front "https://github.com/programmersagara-cell/mytara/blob/main/index.php"
click node_router "https://github.com/programmersagara-cell/mytara/blob/main/src/Core/Router.php"
click node_auth "https://github.com/programmersagara-cell/mytara/blob/main/src/Services/AuthService.php"
click node_assets_ui "https://github.com/programmersagara-cell/mytara/blob/main/src/Controllers/AssetController.php"
click node_asset_model "https://github.com/programmersagara-cell/mytara/blob/main/src/Models/Asset.php"
click node_topology "https://github.com/programmersagara-cell/mytara/blob/main/src/Controllers/TopologyController.php"
click node_disposal "https://github.com/programmersagara-cell/mytara/blob/main/src/Controllers/DisposalController.php"
click node_ticket_ui "https://github.com/programmersagara-cell/mytara/blob/main/src/Controllers/TicketController.php"
click node_ticket_service "https://github.com/programmersagara-cell/mytara/blob/main/src/Services/TicketService.php"
click node_ticket_model "https://github.com/programmersagara-cell/mytara/blob/main/src/Models/Concern.php"
click node_notifications "https://github.com/programmersagara-cell/mytara/blob/main/src/Models/TroubleNotification.php"
click node_mail "https://github.com/programmersagara-cell/mytara/blob/main/src/Services/MailQueueService.php"
click node_dashboard "https://github.com/programmersagara-cell/mytara/blob/main/src/Controllers/DashboardController.php"
click node_history "https://github.com/programmersagara-cell/mytara/blob/main/src/Services/AuditService.php"
click node_departments "https://github.com/programmersagara-cell/mytara/blob/main/src/Models/Department.php"
click node_users "https://github.com/programmersagara-cell/mytara/blob/main/src/Controllers/UserController.php"
click node_licenses "https://github.com/programmersagara-cell/mytara/blob/main/src/Controllers/LicenseController.php"
click node_messages "https://github.com/programmersagara-cell/mytara/blob/main/src/Controllers/MessageController.php"
click node_view "https://github.com/programmersagara-cell/mytara/blob/main/src/Core/View.php"
click node_controller "https://github.com/programmersagara-cell/mytara/blob/main/src/Core/Controller.php"
click node_database "https://github.com/programmersagara-cell/mytara/blob/main/src/Core/Database.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_front,node_router,node_auth,node_user toneBlue
class node_assets_ui,node_asset_model,node_topology,node_disposal,node_mysql toneAmber
class node_ticket_ui,node_ticket_service,node_ticket_model,node_notifications,node_mail toneMint
class node_dashboard,node_history,node_departments,node_users,node_licenses,node_messages toneRose
class node_view,node_controller,node_database toneIndigo
```

## Components

### Web and access

- [Web entry](https://github.com/programmersagara-cell/mytara/blob/main/index.php): `index.php`
- [Route dispatch](https://github.com/programmersagara-cell/mytara/blob/main/src/Core/Router.php): `src/Core/Router.php`
- [Authentication](https://github.com/programmersagara-cell/mytara/blob/main/src/Services/AuthService.php): `src/Services/AuthService.php`

### Asset operations

- [Asset management](https://github.com/programmersagara-cell/mytara/blob/main/src/Controllers/AssetController.php): `src/Controllers/AssetController.php`
- [Asset records](https://github.com/programmersagara-cell/mytara/blob/main/src/Models/Asset.php): `src/Models/Asset.php`
- [Network topology](https://github.com/programmersagara-cell/mytara/blob/main/src/Controllers/TopologyController.php): `src/Controllers/TopologyController.php`
- [Asset disposal](https://github.com/programmersagara-cell/mytara/blob/main/src/Controllers/DisposalController.php): `src/Controllers/DisposalController.php`

### IT service workflow

- [Ticket workflow](https://github.com/programmersagara-cell/mytara/blob/main/src/Controllers/TicketController.php): `src/Controllers/TicketController.php`
- [Ticket operations](https://github.com/programmersagara-cell/mytara/blob/main/src/Services/TicketService.php): `src/Services/TicketService.php`
- [Concern records](https://github.com/programmersagara-cell/mytara/blob/main/src/Models/Concern.php): `src/Models/Concern.php`
- [Ticket notifications](https://github.com/programmersagara-cell/mytara/blob/main/src/Models/TroubleNotification.php): `src/Models/TroubleNotification.php`
- [Mail queue](https://github.com/programmersagara-cell/mytara/blob/main/src/Services/MailQueueService.php): `src/Services/MailQueueService.php`

### Administration and insight

- [Dashboard analytics](https://github.com/programmersagara-cell/mytara/blob/main/src/Controllers/DashboardController.php): `src/Controllers/DashboardController.php`
- [Audit history](https://github.com/programmersagara-cell/mytara/blob/main/src/Services/AuditService.php): `src/Services/AuditService.php`
- [Departments](https://github.com/programmersagara-cell/mytara/blob/main/src/Models/Department.php): `src/Models/Department.php`
- [User administration](https://github.com/programmersagara-cell/mytara/blob/main/src/Controllers/UserController.php): `src/Controllers/UserController.php`
- [Software licensing](https://github.com/programmersagara-cell/mytara/blob/main/src/Controllers/LicenseController.php): `src/Controllers/LicenseController.php`
- [Internal messaging](https://github.com/programmersagara-cell/mytara/blob/main/src/Controllers/MessageController.php): `src/Controllers/MessageController.php`

### Application runtime

- [View rendering](https://github.com/programmersagara-cell/mytara/blob/main/src/Core/View.php): `src/Core/View.php`
- [Controller base](https://github.com/programmersagara-cell/mytara/blob/main/src/Core/Controller.php): `src/Core/Controller.php`
- [PDO database](https://github.com/programmersagara-cell/mytara/blob/main/src/Core/Database.php): `src/Core/Database.php`

### Other components

- **User**
- **MySQL / MariaDB**

## Connections

- User → Web entry: submits requests
- Web entry → Route dispatch: boots (evidence: `index.php`)
- Route dispatch → Controller base: dispatches (evidence: `src/Core/Router.php`)
- Route dispatch → Authentication: routes to
- Authentication → User administration: authenticates users
- Controller base → View rendering: renders pages (evidence: `src/Core/Controller.php`)
- Asset management → Asset records: creates records (evidence: `src/Controllers/AssetController.php`)
- Asset management → Audit history: logs changes (evidence: `src/Controllers/AssetController.php`)
- Asset management → Departments: loads options (evidence: `src/Controllers/AssetController.php`)
- Network topology → Asset records: uses assets
- Asset disposal → Asset records: manages retirement (evidence: `src/Controllers/DisposalController.php`)
- Ticket workflow → Ticket operations: handles workflow (evidence: `src/Controllers/TicketController.php`)
- Ticket workflow → Audit history: logs actions (evidence: `src/Controllers/TicketController.php`)
- Ticket operations → Concern records: updates concerns (evidence: `src/Services/TicketService.php`)
- Ticket operations → Ticket notifications: records notifications (evidence: `src/Services/TicketService.php`)
- Ticket operations → Mail queue: queues email (evidence: `src/Services/TicketService.php`)
- Dashboard analytics → Asset records: summarizes assets
- Dashboard analytics → Audit history: shows activity
- Software licensing → Audit history: audits changes (evidence: `src/Controllers/LicenseController.php`)
- Asset records → PDO database: queries through (evidence: `src/Models/Asset.php`)
- Concern records → PDO database: queries through (evidence: `src/Models/Concern.php`)
- Audit history → PDO database: persists audit log (evidence: `src/Services/AuditService.php`)
- PDO database → MySQL / MariaDB: stores records (evidence: `src/Core/Database.php`)
