# himateja27/factoryiq-manufacturing-management-portal-system architecture

> Architecture diagram of the GitHub repository himateja27/factoryiq-manufacturing-management-portal-system, 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/himateja27/factoryiq-manufacturing-management-portal-system
- Repository: https://github.com/himateja27/factoryiq-manufacturing-management-portal-system

## Overview

FactoryIQ is a manufacturing management portal. Users register or sign in, then access a protected dashboard and project, production, quality, and inventory workflows backed by Django REST APIs. The README documents JWT authentication, role-based access, and the domain modules; sampled source confirms frontend routing and profile loading. Backend endpoint wiring and individual domain operations were not sampled, so those relationships are shown only at the documented API and module level.

Main entry points: [`frontend/src/ui/AppLayout.jsx`](https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/frontend/src/ui/AppLayout.jsx) (Authenticated layout), [`backend/factoryiq/urls.py`](https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/backend/factoryiq/urls.py) (API routing), [`backend/factoryiq/settings.py`](https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/backend/factoryiq/settings.py) (Configured database), [`frontend/src/App.jsx`](https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/frontend/src/App.jsx) (Routes and provider)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_frontend["React application"]
  node_entry["SPA entry<br/>[main.jsx]"]
  node_app["Routes and provider<br/>[App.jsx]"]
  node_login["Login and registration<br/>[LoginPage.jsx]"]
  node_register["Registration form<br/>[RegisterPage.jsx]"]
  node_layout["Authenticated layout<br/>[AppLayout.jsx]"]
  node_client["API client<br/>[api.js]"]
  node_dashboard["Dashboard<br/>[DashboardPage.jsx]"]
  node_projectsui["Projects interface<br/>[ProjectsPage.jsx]"]
  node_productionui["Production interface<br/>[ProductionPage.jsx]"]
  node_qualityui["Quality interface<br/>[QualityPage.jsx]"]
  node_inventoryui["Inventory interface<br/>[InventoryPage.jsx]"]
end

subgraph group_identity["Identity and access"]
  node_guard["Route protection<br/>[RequireAuth.jsx]"]
  node_authstate["Auth state<br/>[AuthContext.jsx]"]
  node_token["JWT storage<br/>[auth.js]"]
  node_userapi["Authentication API<br/>[views.py]"]
  node_userdata["User model<br/>[models.py]"]
end

subgraph group_backend["Django API"]
  node_rooturls["API routing<br/>[urls.py]"]
  node_database[("Configured database<br/>[settings.py]")]
end

subgraph group_domains["Manufacturing domains"]
  node_projectsapi["Projects API<br/>[views.py]"]
  node_projectsdata["Project records<br/>[models.py]"]
  node_productionapi["Production API<br/>[views.py]"]
  node_productiondata["Production records<br/>[models.py]"]
  node_qualityapi["Quality API<br/>[views.py]"]
  node_qualitydata["Quality records<br/>[models.py]"]
  node_supplyapi["Supply chain API<br/>[views.py]"]
  node_supplydata["Inventory records<br/>[models.py]"]
end

node_user(("Portal user"))

node_user -->|"opens portal"| node_entry
node_entry -->|"mounts"| node_app
node_app -->|"routes"| node_login
node_app -->|"routes"| node_register
node_app -->|"protects routes"| node_guard
node_guard -->|"checks token"| node_token
node_guard -->|"allows access"| node_layout
node_layout -->|"hosts"| node_dashboard
node_layout -->|"hosts"| node_projectsui
node_layout -->|"hosts"| node_productionui
node_layout -->|"hosts"| node_qualityui
node_layout -->|"hosts"| node_inventoryui
node_login -->|"API requests"| node_client
node_register -->|"API requests"| node_client
node_authstate -->|"loads profile"| node_client
node_authstate -->|"reads and clears"| node_token
node_client -->|"REST requests"| node_rooturls
node_rooturls -->|"routes auth"| node_userapi
node_rooturls -->|"routes projects"| node_projectsapi
node_rooturls -->|"routes production"| node_productionapi
node_rooturls -->|"routes quality"| node_qualityapi
node_rooturls -->|"routes supply"| node_supplyapi
node_userapi -->|"manages users"| node_userdata
node_projectsapi -->|"manages projects"| node_projectsdata
node_productionapi -->|"manages records"| node_productiondata
node_qualityapi -->|"manages records"| node_qualitydata
node_supplyapi -->|"manages inventory"| node_supplydata
node_userdata -->|"persists"| node_database
node_projectsdata -->|"persists"| node_database
node_productiondata -->|"persists"| node_database
node_qualitydata -->|"persists"| node_database
node_supplydata -->|"persists"| node_database

click node_entry "https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/frontend/src/main.jsx"
click node_app "https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/frontend/src/App.jsx"
click node_login "https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/frontend/src/views/LoginPage.jsx"
click node_register "https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/frontend/src/views/RegisterPage.jsx"
click node_guard "https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/frontend/src/ui/RequireAuth.jsx"
click node_layout "https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/frontend/src/ui/AppLayout.jsx"
click node_authstate "https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/frontend/src/context/AuthContext.jsx"
click node_token "https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/frontend/src/lib/auth.js"
click node_client "https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/frontend/src/lib/api.js"
click node_dashboard "https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/frontend/src/views/DashboardPage.jsx"
click node_projectsui "https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/frontend/src/views/ProjectsPage.jsx"
click node_productionui "https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/frontend/src/views/ProductionPage.jsx"
click node_qualityui "https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/frontend/src/views/QualityPage.jsx"
click node_inventoryui "https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/frontend/src/views/InventoryPage.jsx"
click node_rooturls "https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/backend/factoryiq/urls.py"
click node_userapi "https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/backend/users/views.py"
click node_userdata "https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/backend/users/models.py"
click node_projectsapi "https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/backend/projects/views.py"
click node_projectsdata "https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/backend/projects/models.py"
click node_productionapi "https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/backend/production/views.py"
click node_productiondata "https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/backend/production/models.py"
click node_qualityapi "https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/backend/quality/views.py"
click node_qualitydata "https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/backend/quality/models.py"
click node_supplyapi "https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/backend/supplychain/views.py"
click node_supplydata "https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/backend/supplychain/models.py"
click node_database "https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/backend/factoryiq/settings.py"

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_entry,node_app,node_login,node_register,node_layout,node_client,node_dashboard,node_projectsui,node_productionui,node_qualityui,node_inventoryui,node_user toneBlue
class node_guard,node_authstate,node_token,node_userapi,node_userdata toneAmber
class node_rooturls,node_database toneMint
class node_projectsapi,node_projectsdata,node_productionapi,node_productiondata,node_qualityapi,node_qualitydata,node_supplyapi,node_supplydata toneRose
```

## Components

### React application

- [SPA entry](https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/frontend/src/main.jsx): `frontend/src/main.jsx`
- [Routes and provider](https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/frontend/src/App.jsx): `frontend/src/App.jsx`
- [Login and registration](https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/frontend/src/views/LoginPage.jsx): `frontend/src/views/LoginPage.jsx`
- [Registration form](https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/frontend/src/views/RegisterPage.jsx): `frontend/src/views/RegisterPage.jsx`
- [Authenticated layout](https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/frontend/src/ui/AppLayout.jsx): `frontend/src/ui/AppLayout.jsx`
- [API client](https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/frontend/src/lib/api.js): `frontend/src/lib/api.js`
- [Dashboard](https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/frontend/src/views/DashboardPage.jsx): `frontend/src/views/DashboardPage.jsx`
- [Projects interface](https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/frontend/src/views/ProjectsPage.jsx): `frontend/src/views/ProjectsPage.jsx`
- [Production interface](https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/frontend/src/views/ProductionPage.jsx): `frontend/src/views/ProductionPage.jsx`
- [Quality interface](https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/frontend/src/views/QualityPage.jsx): `frontend/src/views/QualityPage.jsx`
- [Inventory interface](https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/frontend/src/views/InventoryPage.jsx): `frontend/src/views/InventoryPage.jsx`

### Identity and access

- [Route protection](https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/frontend/src/ui/RequireAuth.jsx): `frontend/src/ui/RequireAuth.jsx`
- [Auth state](https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/frontend/src/context/AuthContext.jsx): `frontend/src/context/AuthContext.jsx`
- [JWT storage](https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/frontend/src/lib/auth.js): `frontend/src/lib/auth.js`
- [Authentication API](https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/backend/users/views.py): `backend/users/views.py`
- [User model](https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/backend/users/models.py): `backend/users/models.py`

### Django API

- [API routing](https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/backend/factoryiq/urls.py): `backend/factoryiq/urls.py`
- [Configured database](https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/backend/factoryiq/settings.py): `backend/factoryiq/settings.py`

### Manufacturing domains

- [Projects API](https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/backend/projects/views.py): `backend/projects/views.py`
- [Project records](https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/backend/projects/models.py): `backend/projects/models.py`
- [Production API](https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/backend/production/views.py): `backend/production/views.py`
- [Production records](https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/backend/production/models.py): `backend/production/models.py`
- [Quality API](https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/backend/quality/views.py): `backend/quality/views.py`
- [Quality records](https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/backend/quality/models.py): `backend/quality/models.py`
- [Supply chain API](https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/backend/supplychain/views.py): `backend/supplychain/views.py`
- [Inventory records](https://github.com/himateja27/factoryiq-manufacturing-management-portal-system/blob/main/backend/supplychain/models.py): `backend/supplychain/models.py`

### Other components

- **Portal user**

## Connections

- Portal user → SPA entry: opens portal
- SPA entry → Routes and provider: mounts
- Routes and provider → Login and registration: routes
- Routes and provider → Registration form: routes
- Routes and provider → Route protection: protects routes
- Route protection → JWT storage: checks token
- Route protection → Authenticated layout: allows access
- Authenticated layout → Dashboard: hosts
- Authenticated layout → Projects interface: hosts
- Authenticated layout → Production interface: hosts
- Authenticated layout → Quality interface: hosts
- Authenticated layout → Inventory interface: hosts
- Login and registration → API client: API requests
- Registration form → API client: API requests
- Auth state → API client: loads profile
- Auth state → JWT storage: reads and clears
- API client → API routing: REST requests
- API routing → Authentication API: routes auth
- API routing → Projects API: routes projects
- API routing → Production API: routes production
- API routing → Quality API: routes quality
- API routing → Supply chain API: routes supply
- Authentication API → User model: manages users
- Projects API → Project records: manages projects
- Production API → Production records: manages records
- Quality API → Quality records: manages records
- Supply chain API → Inventory records: manages inventory
- User model → Configured database: persists
- Project records → Configured database: persists
- Production records → Configured database: persists
- Quality records → Configured database: persists
- Inventory records → Configured database: persists
