Skip to content

mohamedmodizo/CONTRACTOR-S-SOFTWARE

Repository files navigation

Contractor Command Center (Concept Pack → Code Skeleton)

What’s here

  • A runnable backend skeleton in backend/ (FastAPI + SQLite, zero external DB).
  • A minimal mobile-first HTML frontend in frontend/ that calls the API.

Quick start

  1. Python 3.10+
  2. Create venv, install deps, and run server:
    • python -m venv .venv
    • Windows PowerShell: . .venv/Scripts/Activate.ps1
    • pip install fastapi uvicorn pydantic-settings python-multipart
    • python -m uvicorn backend.main:app --reload --port 8000
  3. Open frontend/index.html in a browser and log in (after creating a user).

Initial bootstrap

  • POST /auth/register to create a user; roles include foreman, site_engineer, storekeeper, qs, accountant, director, safety_officer, subcontractor_coord.
  • POST /progress/sites to create a site (qs/director role).

Modules mapped

  • Daily Site Diary → /diary
  • Labor Attendance/Output → /labor/attendance, /labor/output
  • Material Requests/Issues → /materials/requests, /materials/issues, /materials/deliveries
  • Progress Tracking → /progress/records
  • Baselines & Variance → /progress/baselines, /progress/variance
  • Progress Metrics → /progress/summary/progress-percent, /progress/summary/slippage-trend, /progress/summary/heatmap, /progress/summary/forecast
  • QA (Defects/RFIs) → /qa/defects, /qa/rfis
  • Variations → /qa/variations, /qa/variations/{id}/approve
  • QA Metrics → /qa/metrics?site_id=
  • Finance (Certificates) → /finance/certificates and aging
  • Finance Enhancements → notes, payments, receivables forecast, retention ledger, site cash exposure
  • Equipment → registry, usage, breakdowns, metrics
  • Safety → checklists, inspections, incidents, corrective actions, metrics
  • Dashboard → /dashboard/site/{site_id}/summary

Notes

  • Photos are stored to storage/photos/ when uploaded.
  • M-Pesa is intentionally not core in v1; integration points can be added in finance router.

About

No description, website, or topics provided.

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages