- 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
40 lines
1.3 KiB
TypeScript
40 lines
1.3 KiB
TypeScript
import type { ScenarioPreset } from './types'
|
|
|
|
/**
|
|
* Demo scenario metadata shown in the UI. The scenario enum and the forecast
|
|
* perturbation itself live in the Go/ML services; this list only supplies the
|
|
* labels and the narrative used on /plan and /simulate.
|
|
*/
|
|
export const SCENARIO_PRESETS: ScenarioPreset[] = [
|
|
{
|
|
id: 'base',
|
|
label: 'Base week',
|
|
short: 'Base',
|
|
description: 'Normal week, latest forecast weather.',
|
|
weather: { temp_delta_c: 0, precip_mm: 0 },
|
|
},
|
|
{
|
|
id: 'sunny-saturday-market',
|
|
label: 'Sunny Saturday + market',
|
|
short: 'Sun + market',
|
|
description: 'Dry, mild Saturday with a market event; the API applies the forecast uplift.',
|
|
weather: { temp_delta_c: 4, precip_mm: 0 },
|
|
event: { type: 'market', uplift: 0.2 },
|
|
},
|
|
{
|
|
id: 'rainy-saturday',
|
|
label: 'Rainy Saturday',
|
|
short: 'Rainy Sat',
|
|
description: 'Steady rain on Saturday; the API applies the forecast reduction.',
|
|
weather: { temp_delta_c: -2, precip_mm: 3.2 },
|
|
},
|
|
{
|
|
id: 'weekday-event',
|
|
label: 'Wednesday evening event',
|
|
short: 'Wed event',
|
|
description: 'Evening event nearby; the API applies the weekday event uplift.',
|
|
weather: { temp_delta_c: 0, precip_mm: 0 },
|
|
event: { type: 'concert', uplift: 0.25 },
|
|
},
|
|
]
|