osem-fcy/app
Asish Kumar fae6332c36 Stop offering the schedule page when no schedule is published
The home and splash page render a link to the schedule based purely on
the `schedule_public` flag, even when an admin has not yet selected a
schedule or scheduled any events. Following that link rendered the
schedule view, which then failed inside `_carousel.html.haml` because
`@rooms` (and the selected schedule) had no data — a 500 error instead
of a graceful response.

Treat `schedule_public` as an allowance rather than an unchecked
control: introduce `Program#any_published_schedule?` (true only when
the flag is on *and* there is at least one event in a selected
schedule) and use it to decide whether to render the link from the
home and splash pages. The schedule controller now returns 404 when no
event has been scheduled, so bookmarked URLs surface as "not found"
instead of an internal server error.
2026-05-14 09:28:58 +05:30
..
assets Fix bug in initial scheduling of events 2025-01-30 14:37:55 +01:00
controllers Stop offering the schedule page when no schedule is published 2026-05-14 09:28:58 +05:30
datatables Use CSS-compatible row IDs in datatables 2022-09-13 11:06:22 -07:00
helpers Fix various typos 2025-10-15 11:15:47 +00:00
jobs Add frozen_string_literal magic comment 2018-05-09 06:54:26 -07:00
mailers Rubocop autocorrections 2018-11-16 09:06:05 -08:00
models Stop offering the schedule page when no schedule is published 2026-05-14 09:28:58 +05:30
pdfs Drop Organization Feature 2024-06-07 17:42:08 +02:00
serializers Merge pull request #3090 from AndrewKvalheim/api-time-zone 2023-04-19 13:36:12 +02:00
uploaders Rename deprecated CarrierWave methods 2021-08-18 14:10:31 +02:00
views Stop offering the schedule page when no schedule is published 2026-05-14 09:28:58 +05:30