{{/* /fleet/economics (Task 13): the operator unit-economics dashboard.
Everything on this page renders server-side from EconomicsView, which
is already priced under the active scenario (economicsview.go) — the
ONE inline
{{template "bottom" .}}{{end}}
{{/* econ_knob_drawer: the "Pricing knobs" — every rate-card,
allocation, mode/margin, rate-sheet and free-tier input, plus the
save-as-scenario form. Shared verbatim between /fleet/economics (Task
13) and /fleet/economics/accounts (Task 14): both pages price the
SAME EconomicsView.Scenario, so one set of knob markup and one
save-scenario door (POST /fleet/economics/scenarios, which always
redirects to /fleet/economics regardless of which page submitted it —
see handleEconomicsScenarioSave) serves both. Takes the whole page `.`
— reads .Economics.Scenario and .CSRF, exactly as when this was inline
in "economics". */}}
{{define "econ_knob_drawer"}}
Pricing knobs
{{/* economics-v2 (Task 6): fleet box + mem-overage rate-sheet knobs — the
same three RateSheet fields compute.go's PriceAccount reads under
fleetRevenue and the rate-sheet mem-overage term, both modes. */}}
Fleet volume break
Fleet pool
Free tier
Save as scenario
With JavaScript on, this saves the knobs above exactly as tweaked. With it off, this round-trips the currently active scenario unchanged, under a new name and/or activated. Saving from either page lands back on the dashboard (/fleet/economics) — the one save door both pages share.
{{end}}
{{/* econ_maths_js: every pure (no page-specific DOM target) function the
knob-recompute scripts need — economics.AllocateBox/PriceAccount
transliterated, plus the small DOM/formatting helpers and
readScenarioFromDOM, which reads the econ_knob_drawer inputs back into
a live-edited Scenario. Emits BARE JavaScript, no