mirror of
https://github.com/MBombeck/HealthLog.git
synced 2026-11-09 21:10:59 +00:00
Dashboard tile feeding the iOS Compliance ring + Erfassen-sheet preview pulls from /api/dashboard/summary, not /api/medications/intake. Without the same projection-then-backfill the intake route received in PR #191, the dashboard endpoint returned [] for daily meds (daysOfWeek = null), keeping the iOS Dashboard tile in its "Heute nichts geplant" empty state even after the intake route fix shipped. Re-uses expandTodayIntakes(schedules, now, tz) + an idempotent createMany with skipDuplicates: true so a concurrent intake-route hit can't race a duplicate row in before the existence probe converges. Two tests added: backfill-mints-once + idempotent-on-second-pass.