# shivshaktisahoo/django-vue-logistics-app architecture

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

- Interactive diagram: https://gitdiagram.com/shivshaktisahoo/django-vue-logistics-app
- Repository: https://github.com/shivshaktisahoo/django-vue-logistics-app

## Overview

CargoPulse is a multi-tenant freight-forwarding and shipment-visibility platform. Its main workflow spans shipment booking and milestone updates, carrier tendering, trip execution and delivery proof, with tracking and exception handling alongside it. The Vue SPA serves operations staff, carriers and customers through a Django REST API. The README documents the platform boundaries; source excerpts and index references support the shown internal service calls. Some UI-to-endpoint wiring and unsampled subsystems are not shown, so those links are omitted.

Main entry points: [`backend/apps/shipments/services.py`](https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/backend/apps/shipments/services.py) (Shipment lifecycle), [`frontend/src/App.vue`](https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/frontend/src/App.vue) (Vue application), [`backend/config/urls.py`](https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/backend/config/urls.py) (Django REST API), [`backend/apps/trips/services.py`](https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/backend/apps/trips/services.py) (Trip execution)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_client["Web application"]
  node_spa["Vue application<br/>[App.vue]"]
  node_auth_ui["Login and registration<br/>[LoginPage.vue]"]
  node_shipment_ui["Shipment workflows"]
  node_tender_ui["Tender workflows<br/>[TendersPage.vue]"]
  node_trip_ui["Trip workflows<br/>[TripDetailPage.vue]"]
  node_tracking_ui["Tracking views<br/>[LiveMapPage.vue]"]
  node_exceptions_ui["Exception workflow<br/>[ExceptionsPage.vue]"]
end

subgraph group_platform["Tenant platform"]
  node_api["Django REST API<br/>[urls.py]"]
  node_identity["Accounts and tenancy<br/>[services.py]"]
end

subgraph group_freight["Freight operations"]
  node_masterdata[("Freight master data<br/>[models.py]")]
  node_shipments["Shipment lifecycle<br/>[services.py]"]
  node_shipment_rules["Shipment domain rules<br/>[domain.py]"]
  node_tenders["Carrier tendering<br/>[services.py]"]
  node_trips["Trip execution<br/>[services.py]"]
end

subgraph group_visibility["Tracking and records"]
  node_tracking["Position calculation<br/>[services.py]"]
  node_exception_engine["Exception detection<br/>[detection.py]"]
  node_exceptions["Exception handling<br/>[services.py]"]
  node_documents["Shipment documents<br/>[services.py]"]
  node_audit[("Audit history<br/>[services.py]")]
end

subgraph group_runtime["Runtime services"]
  node_postgres[("PostgreSQL")]
  node_redis[("Redis")]
  node_celery["Celery worker and beat<br/>[celery.py]"]
end

node_personas(("Admin, ops, carrier, customer"))

node_personas -->|"use"| node_spa
node_spa -->|"calls /api"| node_api
node_auth_ui -.->|"renders in"| node_spa
node_shipment_ui -.->|"renders in"| node_spa
node_tender_ui -.->|"renders in"| node_spa
node_trip_ui -.->|"renders in"| node_spa
node_tracking_ui -.->|"renders in"| node_spa
node_exceptions_ui -.->|"renders in"| node_spa
node_api -.->|"routes requests"| node_identity
node_identity -->|"stores membership"| node_postgres
node_api -.->|"serves shipment operations"| node_shipments
node_api -.->|"serves bidding"| node_tenders
node_api -.->|"serves visibility"| node_tracking
node_api -.->|"serves exception actions"| node_exceptions
node_shipments -->|"uses rules"| node_shipment_rules
node_shipments -->|"checks exceptions"| node_exception_engine
node_shipments -->|"invokes handling"| node_exceptions
node_shipments -->|"records changes"| node_audit
node_tenders -->|"books award"| node_shipments
node_tenders -->|"creates trip"| node_trips
node_trips -->|"updates milestones"| node_shipments
node_trips -->|"uploads proof"| node_documents
node_trips -->|"records actions"| node_audit
node_documents -->|"records file changes"| node_audit
node_exceptions -->|"records actions"| node_audit
node_exception_engine -->|"evaluates logistics"| node_shipment_rules
node_tracking -->|"uses status rules"| node_shipment_rules
node_shipments -->|"persists freight"| node_postgres
node_tenders -->|"persists bids"| node_postgres
node_trips -->|"persists execution"| node_postgres
node_celery -->|"uses broker"| node_redis

click node_spa "https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/frontend/src/App.vue"
click node_auth_ui "https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/frontend/src/modules/auth/pages/LoginPage.vue"
click node_shipment_ui "https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/frontend/src/modules/shipments/pages/ShipmentFormPage.vue"
click node_tender_ui "https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/frontend/src/modules/tenders/pages/TendersPage.vue"
click node_trip_ui "https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/frontend/src/modules/trips/pages/TripDetailPage.vue"
click node_tracking_ui "https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/frontend/src/modules/tracking/pages/LiveMapPage.vue"
click node_exceptions_ui "https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/frontend/src/modules/exceptions/pages/ExceptionsPage.vue"
click node_api "https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/backend/config/urls.py"
click node_identity "https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/backend/apps/organizations/services.py"
click node_masterdata "https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/backend/apps/masterdata/models.py"
click node_shipments "https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/backend/apps/shipments/services.py"
click node_shipment_rules "https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/backend/apps/shipments/domain.py"
click node_tenders "https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/backend/apps/tenders/services.py"
click node_trips "https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/backend/apps/trips/services.py"
click node_tracking "https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/backend/apps/tracking/services.py"
click node_exception_engine "https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/backend/apps/exceptions/detection.py"
click node_exceptions "https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/backend/apps/exceptions/services.py"
click node_documents "https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/backend/apps/documents/services.py"
click node_audit "https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/backend/apps/audit/services.py"
click node_celery "https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/backend/config/celery.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_spa,node_auth_ui,node_shipment_ui,node_tender_ui,node_trip_ui,node_tracking_ui,node_exceptions_ui toneBlue
class node_api,node_identity toneAmber
class node_masterdata,node_shipments,node_shipment_rules,node_tenders,node_trips toneMint
class node_tracking,node_exception_engine,node_exceptions,node_documents,node_audit toneRose
class node_postgres,node_redis,node_celery,node_personas toneIndigo
```

## Components

### Web application

- [Vue application](https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/frontend/src/App.vue): `frontend/src/App.vue`
- [Login and registration](https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/frontend/src/modules/auth/pages/LoginPage.vue): `frontend/src/modules/auth/pages/LoginPage.vue`
- [Shipment workflows](https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/frontend/src/modules/shipments/pages/ShipmentFormPage.vue): `frontend/src/modules/shipments/pages/ShipmentFormPage.vue`
- [Tender workflows](https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/frontend/src/modules/tenders/pages/TendersPage.vue): `frontend/src/modules/tenders/pages/TendersPage.vue`
- [Trip workflows](https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/frontend/src/modules/trips/pages/TripDetailPage.vue): `frontend/src/modules/trips/pages/TripDetailPage.vue`
- [Tracking views](https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/frontend/src/modules/tracking/pages/LiveMapPage.vue): `frontend/src/modules/tracking/pages/LiveMapPage.vue`
- [Exception workflow](https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/frontend/src/modules/exceptions/pages/ExceptionsPage.vue): `frontend/src/modules/exceptions/pages/ExceptionsPage.vue`

### Tenant platform

- [Django REST API](https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/backend/config/urls.py): `backend/config/urls.py`
- [Accounts and tenancy](https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/backend/apps/organizations/services.py): `backend/apps/organizations/services.py`

### Freight operations

- [Freight master data](https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/backend/apps/masterdata/models.py): `backend/apps/masterdata/models.py`
- [Shipment lifecycle](https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/backend/apps/shipments/services.py): `backend/apps/shipments/services.py`
- [Shipment domain rules](https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/backend/apps/shipments/domain.py): `backend/apps/shipments/domain.py`
- [Carrier tendering](https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/backend/apps/tenders/services.py): `backend/apps/tenders/services.py`
- [Trip execution](https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/backend/apps/trips/services.py): `backend/apps/trips/services.py`

### Tracking and records

- [Position calculation](https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/backend/apps/tracking/services.py): `backend/apps/tracking/services.py`
- [Exception detection](https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/backend/apps/exceptions/detection.py): `backend/apps/exceptions/detection.py`
- [Exception handling](https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/backend/apps/exceptions/services.py): `backend/apps/exceptions/services.py`
- [Shipment documents](https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/backend/apps/documents/services.py): `backend/apps/documents/services.py`
- [Audit history](https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/backend/apps/audit/services.py): `backend/apps/audit/services.py`

### Runtime services

- **PostgreSQL**
- **Redis**
- [Celery worker and beat](https://github.com/shivshaktisahoo/django-vue-logistics-app/blob/main/backend/config/celery.py): `backend/config/celery.py`

### Other components

- **Admin, ops, carrier, customer**

## Connections

- Admin, ops, carrier, customer → Vue application: use
- Vue application → Django REST API: calls /api
- Login and registration → Vue application: renders in
- Shipment workflows → Vue application: renders in
- Tender workflows → Vue application: renders in
- Trip workflows → Vue application: renders in
- Tracking views → Vue application: renders in
- Exception workflow → Vue application: renders in
- Django REST API → Accounts and tenancy: routes requests
- Accounts and tenancy → PostgreSQL: stores membership
- Django REST API → Shipment lifecycle: serves shipment operations
- Django REST API → Carrier tendering: serves bidding
- Django REST API → Position calculation: serves visibility
- Django REST API → Exception handling: serves exception actions
- Shipment lifecycle → Shipment domain rules: uses rules (evidence: `backend/apps/shipments/services.py`)
- Shipment lifecycle → Exception detection: checks exceptions (evidence: `backend/apps/shipments/services.py`)
- Shipment lifecycle → Exception handling: invokes handling (evidence: `backend/apps/shipments/services.py`)
- Shipment lifecycle → Audit history: records changes (evidence: `backend/apps/shipments/services.py`)
- Carrier tendering → Shipment lifecycle: books award (evidence: `backend/apps/tenders/services.py`)
- Carrier tendering → Trip execution: creates trip (evidence: `backend/apps/tenders/services.py`)
- Trip execution → Shipment lifecycle: updates milestones (evidence: `backend/apps/trips/services.py`)
- Trip execution → Shipment documents: uploads proof (evidence: `backend/apps/trips/services.py`)
- Trip execution → Audit history: records actions (evidence: `backend/apps/trips/services.py`)
- Shipment documents → Audit history: records file changes (evidence: `backend/apps/documents/services.py`)
- Exception handling → Audit history: records actions (evidence: `backend/apps/exceptions/services.py`)
- Exception detection → Shipment domain rules: evaluates logistics (evidence: `backend/apps/exceptions/detection.py`)
- Position calculation → Shipment domain rules: uses status rules (evidence: `backend/apps/tracking/services.py`)
- Shipment lifecycle → PostgreSQL: persists freight
- Carrier tendering → PostgreSQL: persists bids
- Trip execution → PostgreSQL: persists execution
- Celery worker and beat → Redis: uses broker
