# jimmy-network1/tp_restaurant architecture

> Architecture diagram of the GitHub repository jimmy-network1/tp_restaurant, 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/jimmy-network1/tp_restaurant
- Repository: https://github.com/jimmy-network1/tp_restaurant

## Overview

Restaurant Web is a French-language Django restaurant-management application. Customers browse the public menu and make reservations or orders; staff manage tables, orders, kitchen progress, deliveries, and payments, while managers review reports and inventory. The main order lifecycle spans order creation, kitchen preparation, delivery or service, and cash-desk payment. The map includes documented capabilities whose detailed implementations were not sampled; edges are limited to documented relationships or connections named in the source index.

Main entry points: [`orders/views.py`](https://github.com/jimmy-network1/tp_restaurant/blob/main/orders/views.py) (Order handling), [`orders/models.py`](https://github.com/jimmy-network1/tp_restaurant/blob/main/orders/models.py) (Orders and status), [`reports/views.py`](https://github.com/jimmy-network1/tp_restaurant/blob/main/reports/views.py) (Reports and statistics), [`dashboard/views.py`](https://github.com/jimmy-network1/tp_restaurant/blob/main/dashboard/views.py) (Operational dashboard)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_front["Public access"]
  node_public["Public menu and ordering<br/>[public_views.py]"]
end

subgraph group_operations["Restaurant operations"]
  node_menu[("Menu and dishes<br/>[models.py]")]
  node_tables[("Dining tables<br/>[models.py]")]
  node_reservations[("Reservations<br/>[models.py]")]
  node_reservationflow["Reservation handling<br/>[views.py]"]
  node_orders[("Orders and status<br/>[models.py]")]
  node_orderflow["Order handling<br/>[views.py]"]
  node_billing[("Cash desk and payments<br/>[models.py]")]
  node_billingflow["Payment handling<br/>[views.py]"]
end

subgraph group_fulfillment["Kitchen and delivery"]
  node_kitchen[("Kitchen tickets<br/>[models.py]")]
  node_kitchenflow["Kitchen workflow<br/>[views.py]"]
  node_delivery["Delivery operations<br/>[views.py]"]
end

subgraph group_management["Management"]
  node_inventory[("Stock and suppliers<br/>[models.py]")]
  node_inventoryflow["Inventory handling<br/>[views.py]"]
  node_reports["Reports and statistics<br/>[views.py]"]
  node_dashboard["Operational dashboard<br/>[views.py]"]
end

subgraph group_identity["Accounts and access"]
  node_accounts[("Accounts and profiles<br/>[models.py]")]
  node_authflows["Authentication and roles<br/>[views.py]"]
end

node_customer(("Customer"))
node_staff(("Restaurant staff"))

node_customer -->|"browses and orders"| node_public
node_customer -->|"requests reservations"| node_reservationflow
node_staff -->|"signs in"| node_authflows
node_staff -->|"manages orders"| node_orderflow
node_staff -->|"manages bookings"| node_reservationflow
node_staff -->|"manages stock"| node_inventoryflow
node_staff -->|"reviews reports"| node_reports
node_public -->|"reads menu"| node_menu
node_public -.->|"creates orders"| node_orders
node_reservationflow -->|"reads and updates"| node_reservations
node_reservationflow -->|"checks availability"| node_tables
node_orderflow -->|"creates and updates"| node_orders
node_orderflow -->|"reads dishes"| node_menu
node_orderflow -->|"checks tables"| node_tables
node_orderflow -->|"reads reservations"| node_reservations
node_orderflow -->|"records kitchen work"| node_kitchen
node_kitchenflow -->|"updates order status"| node_orders
node_delivery -->|"assigns and updates"| node_orders
node_billingflow -->|"records payments"| node_billing
node_billingflow -->|"marks paid"| node_orders
node_billingflow -->|"writes audit logs"| node_accounts
node_inventoryflow -->|"manages stock records"| node_inventory
node_reports -->|"aggregates payments"| node_billing
node_reports -->|"aggregates orders"| node_orders
node_reports -->|"reads stock data"| node_inventory
node_reports -->|"ranks dishes"| node_menu
node_dashboard -->|"reads payments"| node_billing
node_dashboard -->|"reads orders"| node_orders
node_dashboard -->|"reads reservations"| node_reservations
node_dashboard -->|"reads inventory"| node_inventory
node_authflows -->|"manages profiles"| node_accounts

click node_public "https://github.com/jimmy-network1/tp_restaurant/blob/main/restaurant_web/public_views.py"
click node_menu "https://github.com/jimmy-network1/tp_restaurant/blob/main/menu/models.py"
click node_accounts "https://github.com/jimmy-network1/tp_restaurant/blob/main/accounts/models.py"
click node_authflows "https://github.com/jimmy-network1/tp_restaurant/blob/main/accounts/views.py"
click node_tables "https://github.com/jimmy-network1/tp_restaurant/blob/main/tablesapp/models.py"
click node_reservations "https://github.com/jimmy-network1/tp_restaurant/blob/main/reservations/models.py"
click node_reservationflow "https://github.com/jimmy-network1/tp_restaurant/blob/main/reservations/views.py"
click node_orders "https://github.com/jimmy-network1/tp_restaurant/blob/main/orders/models.py"
click node_orderflow "https://github.com/jimmy-network1/tp_restaurant/blob/main/orders/views.py"
click node_kitchen "https://github.com/jimmy-network1/tp_restaurant/blob/main/kitchen/models.py"
click node_kitchenflow "https://github.com/jimmy-network1/tp_restaurant/blob/main/kitchen/views.py"
click node_delivery "https://github.com/jimmy-network1/tp_restaurant/blob/main/delivery/views.py"
click node_billing "https://github.com/jimmy-network1/tp_restaurant/blob/main/billing/models.py"
click node_billingflow "https://github.com/jimmy-network1/tp_restaurant/blob/main/billing/views.py"
click node_inventory "https://github.com/jimmy-network1/tp_restaurant/blob/main/inventory/models.py"
click node_inventoryflow "https://github.com/jimmy-network1/tp_restaurant/blob/main/inventory/views.py"
click node_reports "https://github.com/jimmy-network1/tp_restaurant/blob/main/reports/views.py"
click node_dashboard "https://github.com/jimmy-network1/tp_restaurant/blob/main/dashboard/views.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_public toneBlue
class node_menu,node_tables,node_reservations,node_reservationflow,node_orders,node_orderflow,node_billing,node_billingflow toneAmber
class node_kitchen,node_kitchenflow,node_delivery toneMint
class node_inventory,node_inventoryflow,node_reports,node_dashboard toneRose
class node_accounts,node_authflows,node_customer,node_staff toneIndigo
```

## Components

### Public access

- [Public menu and ordering](https://github.com/jimmy-network1/tp_restaurant/blob/main/restaurant_web/public_views.py): `restaurant_web/public_views.py`

### Restaurant operations

- [Menu and dishes](https://github.com/jimmy-network1/tp_restaurant/blob/main/menu/models.py): `menu/models.py`
- [Dining tables](https://github.com/jimmy-network1/tp_restaurant/blob/main/tablesapp/models.py): `tablesapp/models.py`
- [Reservations](https://github.com/jimmy-network1/tp_restaurant/blob/main/reservations/models.py): `reservations/models.py`
- [Reservation handling](https://github.com/jimmy-network1/tp_restaurant/blob/main/reservations/views.py): `reservations/views.py`
- [Orders and status](https://github.com/jimmy-network1/tp_restaurant/blob/main/orders/models.py): `orders/models.py`
- [Order handling](https://github.com/jimmy-network1/tp_restaurant/blob/main/orders/views.py): `orders/views.py`
- [Cash desk and payments](https://github.com/jimmy-network1/tp_restaurant/blob/main/billing/models.py): `billing/models.py`
- [Payment handling](https://github.com/jimmy-network1/tp_restaurant/blob/main/billing/views.py): `billing/views.py`

### Kitchen and delivery

- [Kitchen tickets](https://github.com/jimmy-network1/tp_restaurant/blob/main/kitchen/models.py): `kitchen/models.py`
- [Kitchen workflow](https://github.com/jimmy-network1/tp_restaurant/blob/main/kitchen/views.py): `kitchen/views.py`
- [Delivery operations](https://github.com/jimmy-network1/tp_restaurant/blob/main/delivery/views.py): `delivery/views.py`

### Management

- [Stock and suppliers](https://github.com/jimmy-network1/tp_restaurant/blob/main/inventory/models.py): `inventory/models.py`
- [Inventory handling](https://github.com/jimmy-network1/tp_restaurant/blob/main/inventory/views.py): `inventory/views.py`
- [Reports and statistics](https://github.com/jimmy-network1/tp_restaurant/blob/main/reports/views.py): `reports/views.py`
- [Operational dashboard](https://github.com/jimmy-network1/tp_restaurant/blob/main/dashboard/views.py): `dashboard/views.py`

### Accounts and access

- [Accounts and profiles](https://github.com/jimmy-network1/tp_restaurant/blob/main/accounts/models.py): `accounts/models.py`
- [Authentication and roles](https://github.com/jimmy-network1/tp_restaurant/blob/main/accounts/views.py): `accounts/views.py`

### Other components

- **Customer**
- **Restaurant staff**

## Connections

- Customer → Public menu and ordering: browses and orders
- Customer → Reservation handling: requests reservations
- Restaurant staff → Authentication and roles: signs in
- Restaurant staff → Order handling: manages orders
- Restaurant staff → Reservation handling: manages bookings
- Restaurant staff → Inventory handling: manages stock
- Restaurant staff → Reports and statistics: reviews reports
- Public menu and ordering → Menu and dishes: reads menu (evidence: `restaurant_web/public_views.py`)
- Public menu and ordering → Orders and status: creates orders
- Reservation handling → Reservations: reads and updates (evidence: `reservations/views.py`)
- Reservation handling → Dining tables: checks availability (evidence: `reservations/views.py`)
- Order handling → Orders and status: creates and updates (evidence: `orders/views.py`)
- Order handling → Menu and dishes: reads dishes (evidence: `orders/views.py`)
- Order handling → Dining tables: checks tables (evidence: `orders/views.py`)
- Order handling → Reservations: reads reservations (evidence: `orders/views.py`)
- Order handling → Kitchen tickets: records kitchen work (evidence: `orders/views.py`)
- Kitchen workflow → Orders and status: updates order status (evidence: `kitchen/views.py`)
- Delivery operations → Orders and status: assigns and updates (evidence: `delivery/views.py`)
- Payment handling → Cash desk and payments: records payments (evidence: `billing/views.py`)
- Payment handling → Orders and status: marks paid (evidence: `billing/views.py`)
- Payment handling → Accounts and profiles: writes audit logs (evidence: `billing/views.py`)
- Inventory handling → Stock and suppliers: manages stock records (evidence: `inventory/views.py`)
- Reports and statistics → Cash desk and payments: aggregates payments (evidence: `reports/views.py`)
- Reports and statistics → Orders and status: aggregates orders (evidence: `reports/views.py`)
- Reports and statistics → Stock and suppliers: reads stock data (evidence: `reports/views.py`)
- Reports and statistics → Menu and dishes: ranks dishes (evidence: `reports/views.py`)
- Operational dashboard → Cash desk and payments: reads payments (evidence: `dashboard/views.py`)
- Operational dashboard → Orders and status: reads orders (evidence: `dashboard/views.py`)
- Operational dashboard → Reservations: reads reservations (evidence: `dashboard/views.py`)
- Operational dashboard → Stock and suppliers: reads inventory (evidence: `dashboard/views.py`)
- Authentication and roles → Accounts and profiles: manages profiles (evidence: `accounts/views.py`)
