# prathamshetty18/odooonline architecture

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

- Interactive diagram: https://gitdiagram.com/prathamshetty18/odooonline
- Repository: https://github.com/prathamshetty18/odooonline

## Overview

Dayflow is a role-aware HRMS for administrators and employees. Users sign in or register, then the app routes them to permitted workforce or personal views. The main workflows cover employee records, attendance clocking and history, leave applications and decisions, and salary configuration and payslips. These views use a shared data service with local-storage behavior and optional Supabase synchronization. The graph follows documented features and shown imports/calls; unsampled source limits some detailed connections.

Main entry points: [`src/services/db.ts`](https://github.com/prathamshetty18/odooonline/blob/main/src/services/db.ts) (HR data service), [`src/App.tsx`](https://github.com/prathamshetty18/odooonline/blob/main/src/App.tsx) (Role-based app routing), [`src/components/leave/TimeOffView.tsx`](https://github.com/prathamshetty18/odooonline/blob/main/src/components/leave/TimeOffView.tsx) (Leave management), [`src/components/auth/LoginModal.tsx`](https://github.com/prathamshetty18/odooonline/blob/main/src/components/auth/LoginModal.tsx) (Login and signup)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_app["Application shell"]
  node_app["Role-based app routing<br/>[App.tsx]"]
  node_nav["Navigation and access<br/>[Navbar.tsx]"]
end

subgraph group_people["Identity and workforce"]
  node_login["Login and signup<br/>[LoginModal.tsx]"]
  node_directory["Employee directory"]
  node_addemployee["Add employee"]
  node_profile["Employee profile"]
  node_dashboard["Workforce dashboard<br/>[AdminDashboard.tsx]"]
end

subgraph group_timeoff["Time and leave"]
  node_attendance["Attendance clock and log<br/>[AttendanceView.tsx]"]
  node_timeoff["Leave management<br/>[TimeOffView.tsx]"]
  node_applyleave["Leave application"]
  node_rejectleave["Rejection details"]
end

subgraph group_payroll["Compensation"]
  node_salary["Salary management"]
  node_editsalary["Salary configuration"]
  node_payslip["Printable payslip<br/>[PayslipModal.tsx]"]
end

subgraph group_data["Data services"]
  node_db["HR data service<br/>[db.ts]"]
  node_local[("Browser local storage")]
  node_supabaseclient["Supabase configuration<br/>[supabase.ts]"]
  node_supabase[("Supabase database")]
end

node_employee(("Employee user"))
node_admin(("Admin / HR"))

node_employee -->|"signs in"| node_login
node_admin -->|"signs in"| node_login
node_login -->|"authenticates / registers"| node_db
node_app -->|"renders"| node_login
node_app -->|"renders"| node_nav
node_app -->|"routes admins"| node_dashboard
node_app -->|"routes workforce"| node_directory
node_app -->|"routes profiles"| node_profile
node_app -->|"routes attendance"| node_attendance
node_app -->|"routes leave"| node_timeoff
node_app -->|"routes salary"| node_salary
node_directory -->|"opens"| node_addemployee
node_addemployee -->|"creates employee"| node_db
node_profile -->|"updates profile"| node_db
node_attendance -->|"records punches"| node_db
node_timeoff -->|"opens"| node_applyleave
node_timeoff -->|"opens"| node_rejectleave
node_timeoff -->|"updates decisions"| node_db
node_applyleave -->|"submits request"| node_db
node_salary -->|"opens"| node_editsalary
node_salary -->|"opens"| node_payslip
node_editsalary -->|"saves salary"| node_db
node_db -->|"reads / writes"| node_local
node_db -->|"checks configuration"| node_supabaseclient
node_db -.->|"syncs when configured"| node_supabase
node_supabaseclient -->|"creates client"| node_supabase

click node_app "https://github.com/prathamshetty18/odooonline/blob/main/src/App.tsx"
click node_nav "https://github.com/prathamshetty18/odooonline/blob/main/src/components/layout/Navbar.tsx"
click node_login "https://github.com/prathamshetty18/odooonline/blob/main/src/components/auth/LoginModal.tsx"
click node_directory "https://github.com/prathamshetty18/odooonline/blob/main/src/components/employees/EmployeeDirectory.tsx"
click node_addemployee "https://github.com/prathamshetty18/odooonline/blob/main/src/components/employees/AddEmployeeModal.tsx"
click node_profile "https://github.com/prathamshetty18/odooonline/blob/main/src/components/employees/EmployeeProfileView.tsx"
click node_dashboard "https://github.com/prathamshetty18/odooonline/blob/main/src/components/dashboard/AdminDashboard.tsx"
click node_attendance "https://github.com/prathamshetty18/odooonline/blob/main/src/components/attendance/AttendanceView.tsx"
click node_timeoff "https://github.com/prathamshetty18/odooonline/blob/main/src/components/leave/TimeOffView.tsx"
click node_applyleave "https://github.com/prathamshetty18/odooonline/blob/main/src/components/leave/ApplyLeaveModal.tsx"
click node_rejectleave "https://github.com/prathamshetty18/odooonline/blob/main/src/components/leave/RejectLeaveModal.tsx"
click node_salary "https://github.com/prathamshetty18/odooonline/blob/main/src/components/salary/SalaryManagementView.tsx"
click node_editsalary "https://github.com/prathamshetty18/odooonline/blob/main/src/components/salary/EditSalaryModal.tsx"
click node_payslip "https://github.com/prathamshetty18/odooonline/blob/main/src/components/payslip/PayslipModal.tsx"
click node_db "https://github.com/prathamshetty18/odooonline/blob/main/src/services/db.ts"
click node_supabaseclient "https://github.com/prathamshetty18/odooonline/blob/main/src/services/supabase.ts"

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_nav,node_employee toneBlue
class node_login,node_directory,node_addemployee,node_profile,node_dashboard toneAmber
class node_attendance,node_timeoff,node_applyleave,node_rejectleave toneMint
class node_salary,node_editsalary,node_payslip toneRose
class node_db,node_local,node_supabaseclient,node_supabase,node_admin toneIndigo
```

## Components

### Application shell

- [Role-based app routing](https://github.com/prathamshetty18/odooonline/blob/main/src/App.tsx): `src/App.tsx`
- [Navigation and access](https://github.com/prathamshetty18/odooonline/blob/main/src/components/layout/Navbar.tsx): `src/components/layout/Navbar.tsx`

### Identity and workforce

- [Login and signup](https://github.com/prathamshetty18/odooonline/blob/main/src/components/auth/LoginModal.tsx): `src/components/auth/LoginModal.tsx`
- [Employee directory](https://github.com/prathamshetty18/odooonline/blob/main/src/components/employees/EmployeeDirectory.tsx): `src/components/employees/EmployeeDirectory.tsx`
- [Add employee](https://github.com/prathamshetty18/odooonline/blob/main/src/components/employees/AddEmployeeModal.tsx): `src/components/employees/AddEmployeeModal.tsx`
- [Employee profile](https://github.com/prathamshetty18/odooonline/blob/main/src/components/employees/EmployeeProfileView.tsx): `src/components/employees/EmployeeProfileView.tsx`
- [Workforce dashboard](https://github.com/prathamshetty18/odooonline/blob/main/src/components/dashboard/AdminDashboard.tsx): `src/components/dashboard/AdminDashboard.tsx`

### Time and leave

- [Attendance clock and log](https://github.com/prathamshetty18/odooonline/blob/main/src/components/attendance/AttendanceView.tsx): `src/components/attendance/AttendanceView.tsx`
- [Leave management](https://github.com/prathamshetty18/odooonline/blob/main/src/components/leave/TimeOffView.tsx): `src/components/leave/TimeOffView.tsx`
- [Leave application](https://github.com/prathamshetty18/odooonline/blob/main/src/components/leave/ApplyLeaveModal.tsx): `src/components/leave/ApplyLeaveModal.tsx`
- [Rejection details](https://github.com/prathamshetty18/odooonline/blob/main/src/components/leave/RejectLeaveModal.tsx): `src/components/leave/RejectLeaveModal.tsx`

### Compensation

- [Salary management](https://github.com/prathamshetty18/odooonline/blob/main/src/components/salary/SalaryManagementView.tsx): `src/components/salary/SalaryManagementView.tsx`
- [Salary configuration](https://github.com/prathamshetty18/odooonline/blob/main/src/components/salary/EditSalaryModal.tsx): `src/components/salary/EditSalaryModal.tsx`
- [Printable payslip](https://github.com/prathamshetty18/odooonline/blob/main/src/components/payslip/PayslipModal.tsx): `src/components/payslip/PayslipModal.tsx`

### Data services

- [HR data service](https://github.com/prathamshetty18/odooonline/blob/main/src/services/db.ts): `src/services/db.ts`
- **Browser local storage**
- [Supabase configuration](https://github.com/prathamshetty18/odooonline/blob/main/src/services/supabase.ts): `src/services/supabase.ts`
- **Supabase database**

### Other components

- **Employee user**
- **Admin / HR**

## Connections

- Employee user → Login and signup: signs in (evidence: `README.md`)
- Admin / HR → Login and signup: signs in (evidence: `README.md`)
- Login and signup → HR data service: authenticates / registers (evidence: `src/components/auth/LoginModal.tsx`)
- Role-based app routing → Login and signup: renders (evidence: `src/App.tsx`)
- Role-based app routing → Navigation and access: renders (evidence: `src/App.tsx`)
- Role-based app routing → Workforce dashboard: routes admins (evidence: `src/App.tsx`)
- Role-based app routing → Employee directory: routes workforce (evidence: `src/App.tsx`)
- Role-based app routing → Employee profile: routes profiles (evidence: `src/App.tsx`)
- Role-based app routing → Attendance clock and log: routes attendance (evidence: `src/App.tsx`)
- Role-based app routing → Leave management: routes leave (evidence: `src/App.tsx`)
- Role-based app routing → Salary management: routes salary (evidence: `src/App.tsx`)
- Employee directory → Add employee: opens (evidence: `src/components/employees/EmployeeDirectory.tsx`)
- Add employee → HR data service: creates employee (evidence: `src/components/employees/AddEmployeeModal.tsx`)
- Employee profile → HR data service: updates profile (evidence: `src/components/employees/EmployeeProfileView.tsx`)
- Attendance clock and log → HR data service: records punches (evidence: `src/components/attendance/AttendanceView.tsx`)
- Leave management → Leave application: opens (evidence: `src/components/leave/TimeOffView.tsx`)
- Leave management → Rejection details: opens (evidence: `src/components/leave/TimeOffView.tsx`)
- Leave management → HR data service: updates decisions (evidence: `src/components/leave/TimeOffView.tsx`)
- Leave application → HR data service: submits request (evidence: `src/components/leave/ApplyLeaveModal.tsx`)
- Salary management → Salary configuration: opens (evidence: `src/components/salary/SalaryManagementView.tsx`)
- Salary management → Printable payslip: opens (evidence: `src/components/salary/SalaryManagementView.tsx`)
- Salary configuration → HR data service: saves salary (evidence: `src/components/salary/EditSalaryModal.tsx`)
- HR data service → Browser local storage: reads / writes (evidence: `src/services/db.ts`)
- HR data service → Supabase configuration: checks configuration (evidence: `src/services/db.ts`)
- HR data service → Supabase database: syncs when configured (evidence: `src/services/db.ts`)
- Supabase configuration → Supabase database: creates client (evidence: `src/services/supabase.ts`)
