# ansexp/sisat-manager architecture

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

- Interactive diagram: https://gitdiagram.com/ansexp/sisat-manager
- Repository: https://github.com/ansexp/sisat-manager

## Overview

This appears to be an occupational-health and workplace-risk management application: users manage companies and employees, then work through SISAT activities such as general diagnosis and process mapping. The tree also shows employee documents, generated occupational forms, and account security. Source excerpts support model relationships and several internal module dependencies; the README is empty and the page/controller wiring was not sampled, so those workflow links are shown as unverified rather than asserted.

Main entry points: [`app/Models/Company.php`](https://github.com/ansexp/sisat-manager/blob/main/app/Models/Company.php) (Company), [`app/Models/Employee.php`](https://github.com/ansexp/sisat-manager/blob/main/app/Models/Employee.php) (Employees), [`app/Models/SisatActivity.php`](https://github.com/ansexp/sisat-manager/blob/main/app/Models/SisatActivity.php) (SISAT activities), [`routes/web.php`](https://github.com/ansexp/sisat-manager/blob/main/routes/web.php) (Web entry)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_access["Access and security"]
  node_user["User account<br/>[User.php]"]
  node_auth["Login and 2FA"]
  node_web["Web entry<br/>[web.php]"]
end

subgraph group_organization["Organizations and workforce"]
  node_company["Company<br/>[Company.php]"]
  node_ciiu["Industry classification<br/>[CIIU.php]"]
  node_workspace["Workspaces<br/>[Workspace.php]"]
  node_employee["Employees<br/>[Employee.php]"]
  node_position["Positions<br/>[Position.php]"]
  node_company_ui["Company screens<br/>[index.php]"]
  node_employee_ui["Employee screens<br/>[show.php]"]
end

subgraph group_sisat["SISAT assessment"]
  node_sisat_module["SISAT modules<br/>[SisatModule.php]"]
  node_sisat_activity["SISAT activities<br/>[SisatActivity.php]"]
  node_sisat_result["Assessment results<br/>[SisatResult.php]"]
  node_activity_item["Activity items<br/>[ActivityItem.php]"]
  node_activity_calculator["Activity calculator"]
  node_module_checker["Module checker<br/>[ModuleChecker.php]"]
  node_general_diagnosis["General diagnosis"]
  node_process_mapping["Process mapping<br/>[ProcessMapping.php]"]
end

subgraph group_documents["Documents and records"]
  node_document["Employee documents<br/>[Document.php]"]
  node_document_forms["Generated forms"]
end

node_employee_actor(("Staff user"))
node_database[("Application database")]

node_employee_actor -.->|"uses"| node_web
node_web -.->|"routes to"| node_auth
node_web -.->|"serves screens"| node_company_ui
node_web -.->|"serves screens"| node_employee_ui
node_auth -.->|"authenticates"| node_user
node_company -->|"has many"| node_workspace
node_company -->|"has many"| node_employee
node_company -->|"belongs to"| node_ciiu
node_employee -->|"belongs to"| node_company
node_employee -->|"belongs to"| node_workspace
node_employee -->|"belongs to"| node_position
node_employee -->|"has many"| node_document
node_company -->|"has many"| node_sisat_result
node_sisat_module -->|"has many"| node_sisat_activity
node_sisat_activity -->|"belongs to"| node_sisat_module
node_activity_calculator -->|"uses"| node_company
node_activity_calculator -->|"uses"| node_sisat_activity
node_activity_calculator -->|"uses"| node_activity_item
node_module_checker -->|"uses"| node_company
node_module_checker -->|"uses"| node_sisat_activity
node_module_checker -->|"uses"| node_sisat_module
node_process_mapping -->|"uses"| node_company
node_process_mapping -->|"uses"| node_sisat_activity
node_process_mapping -->|"uses"| node_activity_item
node_company_ui -.->|"manages"| node_company
node_employee_ui -.->|"manages"| node_employee
node_document_forms -.->|"renders data"| node_employee
node_company -.->|"persists"| node_database
node_employee -.->|"persists"| node_database
node_sisat_result -.->|"persists"| node_database

click node_user "https://github.com/ansexp/sisat-manager/blob/main/app/Models/User.php"
click node_auth "https://github.com/ansexp/sisat-manager/blob/main/app/Providers/FortifyServiceProvider.php"
click node_web "https://github.com/ansexp/sisat-manager/blob/main/routes/web.php"
click node_company "https://github.com/ansexp/sisat-manager/blob/main/app/Models/Company.php"
click node_ciiu "https://github.com/ansexp/sisat-manager/blob/main/app/Models/CIIU.php"
click node_workspace "https://github.com/ansexp/sisat-manager/blob/main/app/Models/Workspace.php"
click node_employee "https://github.com/ansexp/sisat-manager/blob/main/app/Models/Employee.php"
click node_position "https://github.com/ansexp/sisat-manager/blob/main/app/Models/Position.php"
click node_company_ui "https://github.com/ansexp/sisat-manager/blob/main/resources/views/pages/companies/index/index.php"
click node_employee_ui "https://github.com/ansexp/sisat-manager/blob/main/resources/views/pages/employees/show/show.php"
click node_sisat_module "https://github.com/ansexp/sisat-manager/blob/main/app/Models/SisatModule.php"
click node_sisat_activity "https://github.com/ansexp/sisat-manager/blob/main/app/Models/SisatActivity.php"
click node_sisat_result "https://github.com/ansexp/sisat-manager/blob/main/app/Models/SisatResult.php"
click node_activity_item "https://github.com/ansexp/sisat-manager/blob/main/app/Modules/ActivityItem.php"
click node_activity_calculator "https://github.com/ansexp/sisat-manager/blob/main/app/Modules/ActivityCalculator.php"
click node_module_checker "https://github.com/ansexp/sisat-manager/blob/main/app/Modules/ModuleChecker.php"
click node_general_diagnosis "https://github.com/ansexp/sisat-manager/blob/main/app/Modules/GuidancePlanning/GeneralDiagnosis.php"
click node_process_mapping "https://github.com/ansexp/sisat-manager/blob/main/app/Modules/GuidancePlanning/ProcessMapping.php"
click node_document "https://github.com/ansexp/sisat-manager/blob/main/app/Models/Document.php"
click node_document_forms "https://github.com/ansexp/sisat-manager/blob/main/resources/views/documents/treatment-authorization.blade.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_user,node_auth,node_web,node_employee_actor toneBlue
class node_company,node_ciiu,node_workspace,node_employee,node_position,node_company_ui,node_employee_ui,node_database toneAmber
class node_sisat_module,node_sisat_activity,node_sisat_result,node_activity_item,node_activity_calculator,node_module_checker,node_general_diagnosis,node_process_mapping toneMint
class node_document,node_document_forms toneRose
```

## Components

### Access and security

- [User account](https://github.com/ansexp/sisat-manager/blob/main/app/Models/User.php): `app/Models/User.php`
- [Login and 2FA](https://github.com/ansexp/sisat-manager/blob/main/app/Providers/FortifyServiceProvider.php): `app/Providers/FortifyServiceProvider.php`
- [Web entry](https://github.com/ansexp/sisat-manager/blob/main/routes/web.php): `routes/web.php`

### Organizations and workforce

- [Company](https://github.com/ansexp/sisat-manager/blob/main/app/Models/Company.php): `app/Models/Company.php`
- [Industry classification](https://github.com/ansexp/sisat-manager/blob/main/app/Models/CIIU.php): `app/Models/CIIU.php`
- [Workspaces](https://github.com/ansexp/sisat-manager/blob/main/app/Models/Workspace.php): `app/Models/Workspace.php`
- [Employees](https://github.com/ansexp/sisat-manager/blob/main/app/Models/Employee.php): `app/Models/Employee.php`
- [Positions](https://github.com/ansexp/sisat-manager/blob/main/app/Models/Position.php): `app/Models/Position.php`
- [Company screens](https://github.com/ansexp/sisat-manager/blob/main/resources/views/pages/companies/index/index.php): `resources/views/pages/companies/index/index.php`
- [Employee screens](https://github.com/ansexp/sisat-manager/blob/main/resources/views/pages/employees/show/show.php): `resources/views/pages/employees/show/show.php`

### SISAT assessment

- [SISAT modules](https://github.com/ansexp/sisat-manager/blob/main/app/Models/SisatModule.php): `app/Models/SisatModule.php`
- [SISAT activities](https://github.com/ansexp/sisat-manager/blob/main/app/Models/SisatActivity.php): `app/Models/SisatActivity.php`
- [Assessment results](https://github.com/ansexp/sisat-manager/blob/main/app/Models/SisatResult.php): `app/Models/SisatResult.php`
- [Activity items](https://github.com/ansexp/sisat-manager/blob/main/app/Modules/ActivityItem.php): `app/Modules/ActivityItem.php`
- [Activity calculator](https://github.com/ansexp/sisat-manager/blob/main/app/Modules/ActivityCalculator.php): `app/Modules/ActivityCalculator.php`
- [Module checker](https://github.com/ansexp/sisat-manager/blob/main/app/Modules/ModuleChecker.php): `app/Modules/ModuleChecker.php`
- [General diagnosis](https://github.com/ansexp/sisat-manager/blob/main/app/Modules/GuidancePlanning/GeneralDiagnosis.php): `app/Modules/GuidancePlanning/GeneralDiagnosis.php`
- [Process mapping](https://github.com/ansexp/sisat-manager/blob/main/app/Modules/GuidancePlanning/ProcessMapping.php): `app/Modules/GuidancePlanning/ProcessMapping.php`

### Documents and records

- [Employee documents](https://github.com/ansexp/sisat-manager/blob/main/app/Models/Document.php): `app/Models/Document.php`
- [Generated forms](https://github.com/ansexp/sisat-manager/blob/main/resources/views/documents/treatment-authorization.blade.php): `resources/views/documents/treatment-authorization.blade.php`

### Other components

- **Staff user**
- **Application database**

## Connections

- Staff user → Web entry: uses
- Web entry → Login and 2FA: routes to
- Web entry → Company screens: serves screens
- Web entry → Employee screens: serves screens
- Login and 2FA → User account: authenticates
- Company → Workspaces: has many (evidence: `app/Models/Company.php`)
- Company → Employees: has many (evidence: `app/Models/Company.php`)
- Company → Industry classification: belongs to (evidence: `app/Models/Company.php`)
- Employees → Company: belongs to (evidence: `app/Models/Employee.php`)
- Employees → Workspaces: belongs to (evidence: `app/Models/Employee.php`)
- Employees → Positions: belongs to (evidence: `app/Models/Employee.php`)
- Employees → Employee documents: has many (evidence: `app/Models/Employee.php`)
- Company → Assessment results: has many (evidence: `app/Models/Company.php`)
- SISAT modules → SISAT activities: has many (evidence: `app/Models/SisatModule.php`)
- SISAT activities → SISAT modules: belongs to (evidence: `app/Models/SisatActivity.php`)
- Activity calculator → Company: uses (evidence: `app/Modules/ActivityCalculator.php`)
- Activity calculator → SISAT activities: uses (evidence: `app/Modules/ActivityCalculator.php`)
- Activity calculator → Activity items: uses (evidence: `app/Modules/ActivityCalculator.php`)
- Module checker → Company: uses (evidence: `app/Modules/ModuleChecker.php`)
- Module checker → SISAT activities: uses (evidence: `app/Modules/ModuleChecker.php`)
- Module checker → SISAT modules: uses (evidence: `app/Modules/ModuleChecker.php`)
- Process mapping → Company: uses (evidence: `app/Modules/GuidancePlanning/ProcessMapping.php`)
- Process mapping → SISAT activities: uses (evidence: `app/Modules/GuidancePlanning/ProcessMapping.php`)
- Process mapping → Activity items: uses (evidence: `app/Modules/GuidancePlanning/ProcessMapping.php`)
- Company screens → Company: manages
- Employee screens → Employees: manages
- Generated forms → Employees: renders data
- Company → Application database: persists
- Employees → Application database: persists
- Assessment results → Application database: persists
