# musheabdulhakim/laravel-smarthr architecture

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

- Interactive diagram: https://gitdiagram.com/musheabdulhakim/laravel-smarthr
- Repository: https://github.com/musheabdulhakim/laravel-smarthr

## Overview

Laravel SmartHR is a modular HRMS. Users authenticate and work through HR, payroll, collaboration, and business-management capabilities; administrators also manage roles and company settings. The documented domain stages include employee lifecycle, attendance, payroll, estimates/invoices/expenses, and project boards/tasks. The dashboard aggregates workforce and business data. Several module implementations are represented by their exact directories because only selected files were sampled; dashed edges mark workflow links not established by the excerpts.

Main entry points: [`Modules/Project/app/Models/Project.php`](https://github.com/musheabdulhakim/laravel-smarthr/blob/main/Modules/Project/app/Models/Project.php) (Project records), [`app/Http/Controllers/DashboardController.php`](https://github.com/musheabdulhakim/laravel-smarthr/blob/main/app/Http/Controllers/DashboardController.php) (Dashboard), [`Modules/Project/app/Http/Controllers/ProjectController.php`](https://github.com/musheabdulhakim/laravel-smarthr/blob/main/Modules/Project/app/Http/Controllers/ProjectController.php) (Projects), [`Modules/Sales/app/Http/Controllers/EstimatesController.php`](https://github.com/musheabdulhakim/laravel-smarthr/blob/main/Modules/Sales/app/Http/Controllers/EstimatesController.php) (Estimates)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_core["HR foundation"]
  node_auth["Authentication<br/>[AuthController.php]"]
  node_dashboard["Dashboard"]
  node_user_model[("User accounts<br/>[User.php]")]
end

subgraph group_people["People operations"]
  node_employee["Employee lifecycle"]
  node_attendance["Attendance"]
  node_payroll["Payroll"]
end

subgraph group_work["Work collaboration"]
  node_tickets["Tickets"]
  node_chat["Realtime chat<br/>[Box.php]"]
  node_projects["Projects"]
  node_project_model[("Project records<br/>[Project.php]")]
  node_task[("Tasks and boards<br/>[Task.php]")]
  node_whiteboard["Whiteboard"]
end

subgraph group_finance["Business finance"]
  node_estimates["Estimates"]
  node_estimate_model[("Estimate records<br/>[Estimate.php]")]
  node_invoices["Invoices"]
  node_accounting["Budgets"]
  node_budget_model[("Budget records<br/>[Budget.php]")]
  node_expenses["Expenses"]
end

subgraph group_admin["Administration"]
  node_roles["Role permissions"]
  node_settings["Company settings"]
end

node_user(("HRMS users"))

node_user -.->|"signs in"| node_auth
node_user -.->|"manages staff"| node_employee
node_user -.->|"records attendance"| node_attendance
node_user -.->|"runs payroll"| node_payroll
node_user -.->|"handles tickets"| node_tickets
node_user -.->|"collaborates"| node_chat
node_user -.->|"manages projects"| node_projects
node_user -.->|"uses whiteboard"| node_whiteboard
node_user -.->|"creates estimates"| node_estimates
node_user -.->|"manages invoices"| node_invoices
node_user -.->|"tracks budgets"| node_accounting
node_user -.->|"administers access"| node_roles
node_user -.->|"configures company"| node_settings
node_auth -->|"authenticates"| node_user_model
node_dashboard -->|"reads workforce"| node_user_model
node_dashboard -->|"reads projects"| node_project_model
node_dashboard -->|"reads budgets"| node_budget_model
node_projects -->|"creates projects"| node_project_model
node_projects -->|"seeds boards"| node_task
node_project_model -->|"owns tasks"| node_task
node_estimates -->|"creates estimates"| node_estimate_model
node_accounting -->|"reads and updates"| node_budget_model
node_budget_model -->|"associates project"| node_project_model
node_estimates -.->|"converts to"| node_invoices
node_employee -.->|"feeds payroll"| node_payroll
node_tickets -.->|"supports conversation"| node_chat

click node_auth "https://github.com/musheabdulhakim/laravel-smarthr/blob/main/app/Http/Controllers/Auth/AuthController.php"
click node_dashboard "https://github.com/musheabdulhakim/laravel-smarthr/blob/main/app/Http/Controllers/DashboardController.php"
click node_user_model "https://github.com/musheabdulhakim/laravel-smarthr/blob/main/app/Models/User.php"
click node_employee "https://github.com/musheabdulhakim/laravel-smarthr/blob/main/app/Http/Controllers/Admin/EmployeesController.php"
click node_attendance "https://github.com/musheabdulhakim/laravel-smarthr/blob/main/app/Livewire/EmployeeAttendance.php"
click node_payroll "https://github.com/musheabdulhakim/laravel-smarthr/blob/main/app/Http/Controllers/Admin/PayrollsController.php"
click node_tickets "https://github.com/musheabdulhakim/laravel-smarthr/blob/main/app/Http/Controllers/Admin/TicketsController.php"
click node_chat "https://github.com/musheabdulhakim/laravel-smarthr/blob/main/app/Livewire/Apps/Chat/Box.php"
click node_projects "https://github.com/musheabdulhakim/laravel-smarthr/blob/main/Modules/Project/app/Http/Controllers/ProjectController.php"
click node_project_model "https://github.com/musheabdulhakim/laravel-smarthr/blob/main/Modules/Project/app/Models/Project.php"
click node_task "https://github.com/musheabdulhakim/laravel-smarthr/blob/main/Modules/Project/app/Models/Task.php"
click node_whiteboard "https://github.com/musheabdulhakim/laravel-smarthr/blob/main/Modules/Whiteboard/app/Http/Controllers/WhiteboardController.php"
click node_estimates "https://github.com/musheabdulhakim/laravel-smarthr/blob/main/Modules/Sales/app/Http/Controllers/EstimatesController.php"
click node_estimate_model "https://github.com/musheabdulhakim/laravel-smarthr/blob/main/Modules/Sales/app/Models/Estimate.php"
click node_invoices "https://github.com/musheabdulhakim/laravel-smarthr/blob/main/Modules/Sales/app/Http/Controllers/InvoicesController.php"
click node_accounting "https://github.com/musheabdulhakim/laravel-smarthr/blob/main/Modules/Accounting/app/Http/Controllers/BudgetsController.php"
click node_budget_model "https://github.com/musheabdulhakim/laravel-smarthr/blob/main/Modules/Accounting/app/Models/Budget.php"
click node_expenses "https://github.com/musheabdulhakim/laravel-smarthr/blob/main/Modules/Sales/app/Http/Controllers/ExpensesController.php"
click node_roles "https://github.com/musheabdulhakim/laravel-smarthr/blob/main/Modules/Roles/app/Http/Controllers/RolesController.php"
click node_settings "https://github.com/musheabdulhakim/laravel-smarthr/blob/main/app/Http/Controllers/Admin/SettingsController.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_auth,node_dashboard,node_user_model,node_user toneBlue
class node_employee,node_attendance,node_payroll toneAmber
class node_tickets,node_chat,node_projects,node_project_model,node_task,node_whiteboard toneMint
class node_estimates,node_estimate_model,node_invoices,node_accounting,node_budget_model,node_expenses toneRose
class node_roles,node_settings toneIndigo
```

## Components

### HR foundation

- [Authentication](https://github.com/musheabdulhakim/laravel-smarthr/blob/main/app/Http/Controllers/Auth/AuthController.php): `app/Http/Controllers/Auth/AuthController.php`
- [Dashboard](https://github.com/musheabdulhakim/laravel-smarthr/blob/main/app/Http/Controllers/DashboardController.php): `app/Http/Controllers/DashboardController.php`
- [User accounts](https://github.com/musheabdulhakim/laravel-smarthr/blob/main/app/Models/User.php): `app/Models/User.php`

### People operations

- [Employee lifecycle](https://github.com/musheabdulhakim/laravel-smarthr/blob/main/app/Http/Controllers/Admin/EmployeesController.php): `app/Http/Controllers/Admin/EmployeesController.php`
- [Attendance](https://github.com/musheabdulhakim/laravel-smarthr/blob/main/app/Livewire/EmployeeAttendance.php): `app/Livewire/EmployeeAttendance.php`
- [Payroll](https://github.com/musheabdulhakim/laravel-smarthr/blob/main/app/Http/Controllers/Admin/PayrollsController.php): `app/Http/Controllers/Admin/PayrollsController.php`

### Work collaboration

- [Tickets](https://github.com/musheabdulhakim/laravel-smarthr/blob/main/app/Http/Controllers/Admin/TicketsController.php): `app/Http/Controllers/Admin/TicketsController.php`
- [Realtime chat](https://github.com/musheabdulhakim/laravel-smarthr/blob/main/app/Livewire/Apps/Chat/Box.php): `app/Livewire/Apps/Chat/Box.php`
- [Projects](https://github.com/musheabdulhakim/laravel-smarthr/blob/main/Modules/Project/app/Http/Controllers/ProjectController.php): `Modules/Project/app/Http/Controllers/ProjectController.php`
- [Project records](https://github.com/musheabdulhakim/laravel-smarthr/blob/main/Modules/Project/app/Models/Project.php): `Modules/Project/app/Models/Project.php`
- [Tasks and boards](https://github.com/musheabdulhakim/laravel-smarthr/blob/main/Modules/Project/app/Models/Task.php): `Modules/Project/app/Models/Task.php`
- [Whiteboard](https://github.com/musheabdulhakim/laravel-smarthr/blob/main/Modules/Whiteboard/app/Http/Controllers/WhiteboardController.php): `Modules/Whiteboard/app/Http/Controllers/WhiteboardController.php`

### Business finance

- [Estimates](https://github.com/musheabdulhakim/laravel-smarthr/blob/main/Modules/Sales/app/Http/Controllers/EstimatesController.php): `Modules/Sales/app/Http/Controllers/EstimatesController.php`
- [Estimate records](https://github.com/musheabdulhakim/laravel-smarthr/blob/main/Modules/Sales/app/Models/Estimate.php): `Modules/Sales/app/Models/Estimate.php`
- [Invoices](https://github.com/musheabdulhakim/laravel-smarthr/blob/main/Modules/Sales/app/Http/Controllers/InvoicesController.php): `Modules/Sales/app/Http/Controllers/InvoicesController.php`
- [Budgets](https://github.com/musheabdulhakim/laravel-smarthr/blob/main/Modules/Accounting/app/Http/Controllers/BudgetsController.php): `Modules/Accounting/app/Http/Controllers/BudgetsController.php`
- [Budget records](https://github.com/musheabdulhakim/laravel-smarthr/blob/main/Modules/Accounting/app/Models/Budget.php): `Modules/Accounting/app/Models/Budget.php`
- [Expenses](https://github.com/musheabdulhakim/laravel-smarthr/blob/main/Modules/Sales/app/Http/Controllers/ExpensesController.php): `Modules/Sales/app/Http/Controllers/ExpensesController.php`

### Administration

- [Role permissions](https://github.com/musheabdulhakim/laravel-smarthr/blob/main/Modules/Roles/app/Http/Controllers/RolesController.php): `Modules/Roles/app/Http/Controllers/RolesController.php`
- [Company settings](https://github.com/musheabdulhakim/laravel-smarthr/blob/main/app/Http/Controllers/Admin/SettingsController.php): `app/Http/Controllers/Admin/SettingsController.php`

### Other components

- **HRMS users**

## Connections

- HRMS users → Authentication: signs in
- HRMS users → Employee lifecycle: manages staff
- HRMS users → Attendance: records attendance
- HRMS users → Payroll: runs payroll
- HRMS users → Tickets: handles tickets
- HRMS users → Realtime chat: collaborates
- HRMS users → Projects: manages projects
- HRMS users → Whiteboard: uses whiteboard
- HRMS users → Estimates: creates estimates
- HRMS users → Invoices: manages invoices
- HRMS users → Budgets: tracks budgets
- HRMS users → Role permissions: administers access
- HRMS users → Company settings: configures company
- Authentication → User accounts: authenticates (evidence: `app/Http/Controllers/Auth/AuthController.php`)
- Dashboard → User accounts: reads workforce (evidence: `app/Http/Controllers/DashboardController.php`)
- Dashboard → Project records: reads projects (evidence: `app/Http/Controllers/DashboardController.php`)
- Dashboard → Budget records: reads budgets (evidence: `app/Http/Controllers/DashboardController.php`)
- Projects → Project records: creates projects (evidence: `Modules/Project/app/Http/Controllers/ProjectController.php`)
- Projects → Tasks and boards: seeds boards (evidence: `Modules/Project/app/Http/Controllers/ProjectController.php`)
- Project records → Tasks and boards: owns tasks (evidence: `Modules/Project/app/Models/Project.php`)
- Estimates → Estimate records: creates estimates (evidence: `Modules/Sales/app/Http/Controllers/EstimatesController.php`)
- Budgets → Budget records: reads and updates (evidence: `Modules/Accounting/app/Http/Controllers/BudgetsController.php`)
- Budget records → Project records: associates project (evidence: `Modules/Accounting/app/Models/Budget.php`)
- Estimates → Invoices: converts to
- Employee lifecycle → Payroll: feeds payroll
- Tickets → Realtime chat: supports conversation
