feat(statistics-deck): choose which complete day, week or month the deck shows #81

Closed
opened 2026-09-24 23:23:37 +00:00 by gabogg · 2 comments
Owner

Problem

The statistics deck (#80) shows one closed period per view: Complete Day, Complete Week, Complete Month. As drafted it always shows the latest one. Presenters need to pick an earlier day, week or month from a selector in each view (the mockup places a period button next to the range label in the top bar; the picker itself is a WIP placeholder).

How "complete weeks" and "complete months" are defined and selected is not settled. This issue collects the decisions; the route issues opened alongside depend on it.

Decisions needed

  1. Week definition. Monday to Sunday business days (Mon daily_reset_time → next Mon daily_reset_time)? ISO 8601 week numbers as labels? Configurable week start per facility?
  2. Month definition. Calendar month of business days (1st at reset → 1st of next month at reset), so the early hours of the 1st belong to the last day of the previous month?
  3. Weeks that span two months. A week belongs to the month of its Monday, of its Thursday (ISO), or to neither (weeks and months are independent)?
  4. What is selectable. Only closed periods. What is the earliest: the first period fully covered by data, or any period with some data, marked as partial?
  5. Periods with bad data. Periods with ingestion-gap estimates, low Data Trust or excluded cycles: selectable with a marker, or hidden?
  6. Picker interaction. Calendar grid, list of periods, previous/next arrows in the top bar, or a combination? Keyboard shortcuts for presenters (for example ← / →)?
  7. Default and persistence. Latest complete period by default? Does a selection persist across tab switches (a chosen week implies which day and month?) and across reloads, and does it belong in the deep link?
  8. Comparisons follow the selection. "vs previous period", "vs usual weekday" and "vs same period last year" are computed relative to the selected period. What is shown when the comparison period has no data (before history starts)?
  9. Schedule changes inside a period. Holidays and schedule edits change opening hours within a week or month; any effect on how a period is labelled?

Out of scope: a Year period.

## Problem The statistics deck (#80) shows one closed period per view: Complete Day, Complete Week, Complete Month. As drafted it always shows the latest one. Presenters need to pick an earlier day, week or month from a selector in each view (the mockup places a period button next to the range label in the top bar; the picker itself is a WIP placeholder). How "complete weeks" and "complete months" are defined and selected is not settled. This issue collects the decisions; the route issues opened alongside depend on it. ## Decisions needed 1. **Week definition.** Monday to Sunday business days (Mon `daily_reset_time` → next Mon `daily_reset_time`)? ISO 8601 week numbers as labels? Configurable week start per facility? 2. **Month definition.** Calendar month of business days (1st at reset → 1st of next month at reset), so the early hours of the 1st belong to the last day of the previous month? 3. **Weeks that span two months.** A week belongs to the month of its Monday, of its Thursday (ISO), or to neither (weeks and months are independent)? 4. **What is selectable.** Only closed periods. What is the earliest: the first period fully covered by data, or any period with some data, marked as partial? 5. **Periods with bad data.** Periods with ingestion-gap estimates, low Data Trust or excluded cycles: selectable with a marker, or hidden? 6. **Picker interaction.** Calendar grid, list of periods, previous/next arrows in the top bar, or a combination? Keyboard shortcuts for presenters (for example ← / →)? 7. **Default and persistence.** Latest complete period by default? Does a selection persist across tab switches (a chosen week implies which day and month?) and across reloads, and does it belong in the deep link? 8. **Comparisons follow the selection.** "vs previous period", "vs usual weekday" and "vs same period last year" are computed relative to the selected period. What is shown when the comparison period has no data (before history starts)? 9. **Schedule changes inside a period.** Holidays and schedule edits change opening hours within a week or month; any effect on how a period is labelled? Out of scope: a Year period.
Author
Owner

Routes that depend on these decisions: #82 (selectable periods), #83 (period summary KPIs), #84 (daily totals), #85 (monthly totals with last year), #86 (per-entrance breakdown), #87 (week day-by-hour matrix), #88 (usual-weekday baselines on existing intraday routes).

Routes that depend on these decisions: #82 (selectable periods), #83 (period summary KPIs), #84 (daily totals), #85 (monthly totals with last year), #86 (per-entrance breakdown), #87 (week day-by-hour matrix), #88 (usual-weekday baselines on existing intraday routes).
Author
Owner

Triage decisions (2026-09-24), recorded in the RFC on #80 and in CONTEXT.md (Complete Period, Partial Period):

  1. Week: Monday to Sunday business days (Mon reset → next Mon reset), fixed start day. Label is the date range; the ISO week number is shown small beside it.
  2. Month: calendar month counted in business days (1st at reset → 1st of next month at reset); the hours before the reset on the 1st belong to the previous month.
  3. Weeks across two months: weeks and months are independent; the Week and Month tabs choose separately.
  4. Earliest selectable: any closed period with some data, marked partial ("4 of 7 days"); figures cover only days with data.
  5. Bad-data periods: selectable, with a visible marker; never hidden.
  6. Picker: numpad − / + step previous / next; the picker window shows a calendar for Day and a list for Week and Month, with partial and bad-data markers.
  7. Default and persistence: each tab keeps its own choice and opens on the latest complete period; a reload returns to the latest; the deep link carries the chosen period.
  8. No comparison data: last year only appears when it has data; for previous period and usual weekday, show "—" with a reason, never 0%.
  9. Holidays and schedule changes: a marker on per-day graphs only; period labels unchanged.

Implementation of the picker belongs to the deck itself (RFC in #80); the routes are #82, #83, #84, #86, #88. Closing as decided.

**Triage decisions (2026-09-24)**, recorded in the RFC on #80 and in `CONTEXT.md` (Complete Period, Partial Period): 1. **Week:** Monday to Sunday business days (Mon reset → next Mon reset), fixed start day. Label is the date range; the ISO week number is shown small beside it. 2. **Month:** calendar month counted in business days (1st at reset → 1st of next month at reset); the hours before the reset on the 1st belong to the previous month. 3. **Weeks across two months:** weeks and months are independent; the Week and Month tabs choose separately. 4. **Earliest selectable:** any closed period with some data, marked partial ("4 of 7 days"); figures cover only days with data. 5. **Bad-data periods:** selectable, with a visible marker; never hidden. 6. **Picker:** numpad − / + step previous / next; the picker window shows a calendar for Day and a list for Week and Month, with partial and bad-data markers. 7. **Default and persistence:** each tab keeps its own choice and opens on the latest complete period; a reload returns to the latest; the deep link carries the chosen period. 8. **No comparison data:** last year only appears when it has data; for previous period and usual weekday, show "—" with a reason, never 0%. 9. **Holidays and schedule changes:** a marker on per-day graphs only; period labels unchanged. Implementation of the picker belongs to the deck itself (RFC in #80); the routes are #82, #83, #84, #86, #88. Closing as decided.
gabogg 2026-09-25 00:43:48 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
gabogg/hikcentral#81
No description provided.