# anoxelazy/tpl architecture

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

- Interactive diagram: https://gitdiagram.com/anoxelazy/tpl
- Repository: https://github.com/anoxelazy/tpl

## Overview

This is a cross-platform Flutter app whose source tree covers staff operations: claims, repairs, IT cases, preventive maintenance, stock, metering, parcel tracking, plans, profile, and support/chat. The likely user journey is sign-in, dashboard navigation, completing an operational task, and viewing its status or result. The README is only Flutter boilerplate and no Dart implementation was excerpted, so feature ownership is represented by its exact source paths; internal calls and service integrations cannot be verified and are not asserted.

Main entry points: [`lib/page/dashboard/dashboard_page.dart`](https://github.com/anoxelazy/tpl/blob/main/lib/page/dashboard/dashboard_page.dart) (Dashboard), [`lib/utils/dio_service.dart`](https://github.com/anoxelazy/tpl/blob/main/lib/utils/dio_service.dart) (HTTP service), [`lib/page/claim/claim.dart`](https://github.com/anoxelazy/tpl/blob/main/lib/page/claim/claim.dart) (Claims), [`lib/main.dart`](https://github.com/anoxelazy/tpl/blob/main/lib/main.dart) (Flutter app)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_entry["App entry"]
  node_app["Flutter app<br/>[main.dart]"]
  node_auth["Sign in / register<br/>[login.dart]"]
  node_home["Home navigation<br/>[home.dart]"]
  node_dashboard["Dashboard"]
end

subgraph group_work["Operations"]
  node_claims["Claims<br/>[claim.dart]"]
  node_repairs["Repairs<br/>[repair_page.dart]"]
  node_itcase["IT cases"]
  node_maintenance["Preventive maintenance<br/>[pm_page.dart]"]
  node_meter["Meter readings"]
  node_scan["Scanning<br/>[scan_page.dart]"]
  node_stock["Stock operations"]
end

subgraph group_logistics["Parcel services"]
  node_tracking["Parcel tracking"]
  node_plans["Plans and bills<br/>[plan_page.dart]"]
  node_qrpay["QR payment<br/>[qr_pay.dart]"]
end

subgraph group_engagement["Account and support"]
  node_profile["Profile and rank<br/>[profile.dart]"]
  node_chat["Chat support<br/>[chat_page.dart]"]
  node_menu["Menu and links<br/>[menu.dart]"]
end

subgraph group_shared["Shared services"]
  node_api["HTTP service<br/>[dio_service.dart]"]
  node_mobileapi["Mobile API<br/>[mobile_api.dart]"]
  node_supabase["Supabase configuration"]
  node_localstate["Claim state<br/>[claim_store.dart]"]
end

node_user(("Staff user"))
node_external[("Backend services")]

node_user -.->|"uses"| node_app
node_app -.->|"starts session"| node_auth
node_auth -.->|"enters app"| node_home
node_home -.->|"opens"| node_dashboard
node_dashboard -.->|"opens"| node_claims
node_dashboard -.->|"opens"| node_repairs
node_dashboard -.->|"opens"| node_itcase
node_dashboard -.->|"opens"| node_maintenance
node_dashboard -.->|"opens"| node_meter
node_dashboard -.->|"opens"| node_scan
node_dashboard -.->|"opens"| node_stock
node_dashboard -.->|"opens"| node_tracking
node_dashboard -.->|"opens"| node_plans
node_dashboard -.->|"opens"| node_qrpay
node_dashboard -.->|"opens"| node_profile
node_dashboard -.->|"opens"| node_chat
node_dashboard -.->|"opens"| node_menu
node_claims -.->|"may persist"| node_localstate
node_claims -.->|"may request"| node_api
node_repairs -.->|"may request"| node_api
node_itcase -.->|"may request"| node_api
node_maintenance -.->|"may request"| node_api
node_meter -.->|"may request"| node_api
node_stock -.->|"may request"| node_api
node_tracking -.->|"may request"| node_api
node_plans -.->|"may request"| node_api
node_chat -.->|"may contact"| node_external

click node_app "https://github.com/anoxelazy/tpl/blob/main/lib/main.dart"
click node_auth "https://github.com/anoxelazy/tpl/blob/main/lib/screen/login.dart"
click node_home "https://github.com/anoxelazy/tpl/blob/main/lib/page/home.dart"
click node_dashboard "https://github.com/anoxelazy/tpl/blob/main/lib/page/dashboard/dashboard_page.dart"
click node_claims "https://github.com/anoxelazy/tpl/blob/main/lib/page/claim/claim.dart"
click node_repairs "https://github.com/anoxelazy/tpl/blob/main/lib/page/repair/repair_page.dart"
click node_itcase "https://github.com/anoxelazy/tpl/blob/main/lib/page/itcase/itcase_status_page.dart"
click node_maintenance "https://github.com/anoxelazy/tpl/blob/main/lib/page/pm/pm_page.dart"
click node_meter "https://github.com/anoxelazy/tpl/blob/main/lib/page/meter/meter_form_page.dart"
click node_scan "https://github.com/anoxelazy/tpl/blob/main/lib/page/scan/scan_page.dart"
click node_stock "https://github.com/anoxelazy/tpl/blob/main/lib/page/stock/stock_status_page.dart"
click node_tracking "https://github.com/anoxelazy/tpl/blob/main/lib/page/tracking/tracking_screen.dart"
click node_plans "https://github.com/anoxelazy/tpl/blob/main/lib/page/plan/plan_page.dart"
click node_qrpay "https://github.com/anoxelazy/tpl/tree/main/lib/page/qr_pay.dart"
click node_profile "https://github.com/anoxelazy/tpl/blob/main/lib/page/profile/profile.dart"
click node_chat "https://github.com/anoxelazy/tpl/blob/main/lib/page/chat/chat_page.dart"
click node_menu "https://github.com/anoxelazy/tpl/blob/main/lib/page/menu/menu.dart"
click node_api "https://github.com/anoxelazy/tpl/blob/main/lib/utils/dio_service.dart"
click node_mobileapi "https://github.com/anoxelazy/tpl/blob/main/lib/utils/mobile_api.dart"
click node_supabase "https://github.com/anoxelazy/tpl/blob/main/lib/utils/supabase_config.dart"
click node_localstate "https://github.com/anoxelazy/tpl/blob/main/lib/utils/claim_store.dart"

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_auth,node_home,node_dashboard,node_user toneBlue
class node_claims,node_repairs,node_itcase,node_maintenance,node_meter,node_scan,node_stock,node_external toneAmber
class node_tracking,node_plans,node_qrpay toneMint
class node_profile,node_chat,node_menu toneRose
class node_api,node_mobileapi,node_supabase,node_localstate toneIndigo
```

## Components

### App entry

- [Flutter app](https://github.com/anoxelazy/tpl/blob/main/lib/main.dart): `lib/main.dart`
- [Sign in / register](https://github.com/anoxelazy/tpl/blob/main/lib/screen/login.dart): `lib/screen/login.dart`
- [Home navigation](https://github.com/anoxelazy/tpl/blob/main/lib/page/home.dart): `lib/page/home.dart`
- [Dashboard](https://github.com/anoxelazy/tpl/blob/main/lib/page/dashboard/dashboard_page.dart): `lib/page/dashboard/dashboard_page.dart`

### Operations

- [Claims](https://github.com/anoxelazy/tpl/blob/main/lib/page/claim/claim.dart): `lib/page/claim/claim.dart`
- [Repairs](https://github.com/anoxelazy/tpl/blob/main/lib/page/repair/repair_page.dart): `lib/page/repair/repair_page.dart`
- [IT cases](https://github.com/anoxelazy/tpl/blob/main/lib/page/itcase/itcase_status_page.dart): `lib/page/itcase/itcase_status_page.dart`
- [Preventive maintenance](https://github.com/anoxelazy/tpl/blob/main/lib/page/pm/pm_page.dart): `lib/page/pm/pm_page.dart`
- [Meter readings](https://github.com/anoxelazy/tpl/blob/main/lib/page/meter/meter_form_page.dart): `lib/page/meter/meter_form_page.dart`
- [Scanning](https://github.com/anoxelazy/tpl/blob/main/lib/page/scan/scan_page.dart): `lib/page/scan/scan_page.dart`
- [Stock operations](https://github.com/anoxelazy/tpl/blob/main/lib/page/stock/stock_status_page.dart): `lib/page/stock/stock_status_page.dart`

### Parcel services

- [Parcel tracking](https://github.com/anoxelazy/tpl/blob/main/lib/page/tracking/tracking_screen.dart): `lib/page/tracking/tracking_screen.dart`
- [Plans and bills](https://github.com/anoxelazy/tpl/blob/main/lib/page/plan/plan_page.dart): `lib/page/plan/plan_page.dart`
- [QR payment](https://github.com/anoxelazy/tpl/tree/main/lib/page/qr_pay.dart): `lib/page/qr_pay.dart`

### Account and support

- [Profile and rank](https://github.com/anoxelazy/tpl/blob/main/lib/page/profile/profile.dart): `lib/page/profile/profile.dart`
- [Chat support](https://github.com/anoxelazy/tpl/blob/main/lib/page/chat/chat_page.dart): `lib/page/chat/chat_page.dart`
- [Menu and links](https://github.com/anoxelazy/tpl/blob/main/lib/page/menu/menu.dart): `lib/page/menu/menu.dart`

### Shared services

- [HTTP service](https://github.com/anoxelazy/tpl/blob/main/lib/utils/dio_service.dart): `lib/utils/dio_service.dart`
- [Mobile API](https://github.com/anoxelazy/tpl/blob/main/lib/utils/mobile_api.dart): `lib/utils/mobile_api.dart`
- [Supabase configuration](https://github.com/anoxelazy/tpl/blob/main/lib/utils/supabase_config.dart): `lib/utils/supabase_config.dart`
- [Claim state](https://github.com/anoxelazy/tpl/blob/main/lib/utils/claim_store.dart): `lib/utils/claim_store.dart`

### Other components

- **Staff user**
- **Backend services**

## Connections

- Staff user → Flutter app: uses
- Flutter app → Sign in / register: starts session
- Sign in / register → Home navigation: enters app
- Home navigation → Dashboard: opens
- Dashboard → Claims: opens
- Dashboard → Repairs: opens
- Dashboard → IT cases: opens
- Dashboard → Preventive maintenance: opens
- Dashboard → Meter readings: opens
- Dashboard → Scanning: opens
- Dashboard → Stock operations: opens
- Dashboard → Parcel tracking: opens
- Dashboard → Plans and bills: opens
- Dashboard → QR payment: opens
- Dashboard → Profile and rank: opens
- Dashboard → Chat support: opens
- Dashboard → Menu and links: opens
- Claims → Claim state: may persist
- Claims → HTTP service: may request
- Repairs → HTTP service: may request
- IT cases → HTTP service: may request
- Preventive maintenance → HTTP service: may request
- Meter readings → HTTP service: may request
- Stock operations → HTTP service: may request
- Parcel tracking → HTTP service: may request
- Plans and bills → HTTP service: may request
- Chat support → Backend services: may contact
