diff --git a/app/models/events.py b/app/models/events.py index 82f0a3f4..8f546aac 100644 --- a/app/models/events.py +++ b/app/models/events.py @@ -158,10 +158,6 @@ def daily_recipes_split_by_shopping(self) -> list: return split_recipes - @property - def zero_amount_ingredient_recipes(self) -> list: - return [r for r in self.active_recipes if r.has_zero_amount_ingredient] - @property def no_measurement_ingredient_recipes(self) -> list: return [r for r in self.active_recipes if r.has_no_measurement_ingredient] diff --git a/app/templates/events/_warnings.html.j2 b/app/templates/events/_warnings.html.j2 index cb3db017..ec5ff5d4 100644 --- a/app/templates/events/_warnings.html.j2 +++ b/app/templates/events/_warnings.html.j2 @@ -1,6 +1,5 @@ - {% if event.zero_amount_ingredient_recipes - or event.empty_recipes + {% if event.empty_recipes or event.no_measurement_ingredient_recipes or event.no_category_ingredient_recipes or event.recipes_without_category %} @@ -8,12 +7,6 @@

Upozornění

- {% if event.zero_amount_ingredient_recipes %} - {% for recipe in event.zero_amount_ingredient_recipes %} -
  • {{ link_to(recipe, turbo=False) }} má surovinu s nulovou hodnotou
  • - {% endfor %} - {% endif %} - {% if event.empty_recipes %} {% for recipe in event.empty_recipes %}
  • {{ link_to(recipe, turbo=False) }} nemá suroviny