diff --git a/src/camps/models.py b/src/camps/models.py index 4772879b3..d92a2417e 100644 --- a/src/camps/models.py +++ b/src/camps/models.py @@ -240,6 +240,11 @@ def logo_large(self) -> str: def logo_large_svg(self) -> str: return f"img/{self.slug}/logo/{self.slug}-logo-large.svg" + @property + def is_in_progress(self) -> bool: + today = timezone.now().date() + return True if today in self.camp_days else False + def get_days(self, camppart): """Returns a list of DateTimeTZRanges representing the days during the specified part of the camp.""" if not hasattr(self, camppart): diff --git a/src/templates/base.html b/src/templates/base.html index 43243307c..75bb370ae 100644 --- a/src/templates/base.html +++ b/src/templates/base.html @@ -70,127 +70,142 @@ {% block body %} + {% if camp.is_in_progress %} +
+ {% else %}
- + +
{% if camp %}