feat: wire Nitro API to Go, real staffing plan and train proxy

- Replace mock Nitro routes with server-side proxies to the Go API
- /plan reads Go /api/staffing; local assumption edits are a labeled preview
- /simulate reads base and scenario staffing from Go instead of local multipliers
- Route train upload and scenario POST through Nitro with server-only credentials
- Keep NUXT_PUBLIC_USE_MOCK=1 as an explicit dev fallback only
- Match Go's global-peak flat schedule and add a captured Go parity fixture
- Run the web runtime as numeric UID/GID 10001:10001
- Add make check, Gitea CI workflow and a proxy smoke script
This commit is contained in:
Noel Sabia committed 2026-11-14 06:13:00 +01:00
1 parent e8d141ca43
commit b33e6ff001
33 files changed
+1147 -317

No files matched your search

+1
View File
@@ -0,0 +1 @@
{"sensor":"hn-stadtgalerie-01","scenario":"base","standard":"standard","assumptions":{"visitors_per_staff_hour":25,"safety_factor":1.15,"min_staff":1,"shift_length_h":4,"labor_cost_eur_h":16,"store_hours":{"open":"10:00","close":"20:00","tz":"Europe/Berlin"}},"hours":[{"t":"2026-11-16T09:00:00Z","footfall":30.2,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-16T10:00:00Z","footfall":30.4,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-16T11:00:00Z","footfall":30.6,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-16T12:00:00Z","footfall":28.4,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-16T13:00:00Z","footfall":23.1,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-16T14:00:00Z","footfall":24.2,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-16T15:00:00Z","footfall":25.7,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-16T16:00:00Z","footfall":26.3,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-16T17:00:00Z","footfall":28.3,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-16T18:00:00Z","footfall":26.4,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-17T09:00:00Z","footfall":30.5,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-17T10:00:00Z","footfall":28.7,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-17T11:00:00Z","footfall":30.4,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-17T12:00:00Z","footfall":29.3,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-17T13:00:00Z","footfall":23.1,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-17T14:00:00Z","footfall":25,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-17T15:00:00Z","footfall":23,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-17T16:00:00Z","footfall":25.7,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-17T17:00:00Z","footfall":28.5,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-17T18:00:00Z","footfall":25.7,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-18T09:00:00Z","footfall":31,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-18T10:00:00Z","footfall":28.1,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-18T11:00:00Z","footfall":30.8,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-18T12:00:00Z","footfall":30.6,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-18T13:00:00Z","footfall":22.2,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-18T14:00:00Z","footfall":24.7,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-18T15:00:00Z","footfall":25.4,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-18T16:00:00Z","footfall":26.5,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-18T17:00:00Z","footfall":29.1,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-18T18:00:00Z","footfall":29.5,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-19T09:00:00Z","footfall":29.3,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-19T10:00:00Z","footfall":31.2,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-19T11:00:00Z","footfall":27.7,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-19T12:00:00Z","footfall":28.4,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-19T13:00:00Z","footfall":24.7,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-19T14:00:00Z","footfall":22.5,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-19T15:00:00Z","footfall":22.8,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-19T16:00:00Z","footfall":25.7,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-19T17:00:00Z","footfall":29.2,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-19T18:00:00Z","footfall":26.9,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-20T09:00:00Z","footfall":28,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-20T10:00:00Z","footfall":29.7,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-20T11:00:00Z","footfall":28.2,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-20T12:00:00Z","footfall":28.7,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-20T13:00:00Z","footfall":25.5,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-20T14:00:00Z","footfall":23.4,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-20T15:00:00Z","footfall":25.4,"required_staff":2,"scheduled_staff":2,"coverage":"ok"},{"t":"2026-11-20T16:00:00Z","footfall"Line truncated