mirror of
https://github.com/bitbaum/vitareba.git
synced 2026-12-05 06:48:03 +01:00
Patient bookings page, admin PatientBookingsCard, and the weekly-digest
email all rendered b.status directly — the lowercase enum value
("pending" / "confirmed" / "attended" / "cancelled") instead of a
proper UI label. Patients saw "Your next consultation is pending" in
the email and "pending" badges in the portal.
Added a label field to BOOKING_STATUS_CONFIG (alongside the existing
color/bg) so labels stay in the same SSOT and never drift from
status values. Both card components read s.label; the weekly-digest
cron now resolves the label before passing it to the template.
Extended booking-status.test.ts with a regression that asserts no
label equals the raw enum and every label starts uppercase.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>