Monthly view: rota boundary, EOM PY card, % Budget headline; backfill 25 months
Rota forecasting: only trust Workforce rota for the current Mon–Sun week — beyond that use prior-week actuals to avoid incomplete next-week rotas deflating the EOM forecast. % vs Budget cards (Weekly + Monthly): show as coloured headline number (green/amber/red) instead of small pct-badge chip, matching other cards. Forecast EOM: PY sub-label shows full prior-year month total + % delta, replacing the static "rota + prior-week actual" note once PY data exists. Achieves this by fetching the full PY month rather than MTD-capped range, then deriving both MTD (for Actual MTD card) and full-month (for EOM card). Backfill depth: 13 → 25 months so past months in Rolling 12 have PY wage data available (viewing Dec 2024 needs Dec 2023 = 19 months ago). Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
a75aceb6e7
commit
d04cd1e82c
4 changed files with 43 additions and 27 deletions
|
|
@ -197,10 +197,8 @@ export default function Weekly() {
|
|||
</div>
|
||||
<div className="summary-card">
|
||||
<div className="label">% vs Budget</div>
|
||||
<div className="value">
|
||||
{pctBudget != null
|
||||
? <span className={`pct-badge ${pctClass(pctBudget)}`}>{fmtDelta(pctBudget)}</span>
|
||||
: '—'}
|
||||
<div className="value" style={pctBudget != null ? { color: pctBudget <= 100 ? 'var(--app-primary)' : pctBudget <= 110 ? '#b45309' : '#dc2626' } : {}}>
|
||||
{pctBudget != null ? fmtDelta(pctBudget) : '—'}
|
||||
</div>
|
||||
</div>
|
||||
<div className="summary-card">
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue