From ff2b6f4c65a93d565a2927c00b66c5a8e4d2f693 Mon Sep 17 00:00:00 2001 From: Ross Date: Mon, 2 Feb 2026 10:52:43 +0000 Subject: [PATCH] Refactor case search results template for improved readability and structure --- .../atlas/partials/_case_search_results.html | 58 +++++++++---------- 1 file changed, 29 insertions(+), 29 deletions(-) diff --git a/atlas/templates/atlas/partials/_case_search_results.html b/atlas/templates/atlas/partials/_case_search_results.html index d03f7238..4faf5886 100644 --- a/atlas/templates/atlas/partials/_case_search_results.html +++ b/atlas/templates/atlas/partials/_case_search_results.html @@ -1,35 +1,35 @@ {# partial: list of cases for HTMX search results #}
-{% if cases %} - {% for case in cases %} - -
-
{{ case.title }}
- {{ case.created_date|date:"Y-m-d" }} -
-
- {% if case.author.all %}By {{ case.author.all|join:", " }}{% endif %} - {% if case.condition %}{{ case.condition.name }}{% endif %} - {% if case.presentation %}{{ case.presentation.name }}{% endif %} - {% if case.subspecialty %}{{ case.subspecialty.name }}{% endif %} -
+ {% if cases %} + {% for case in cases %} +
+
+
{{ case.title }}
+ {{ case.created_date|date:"Y-m-d" }} +
+
+ {% if case.author.all %}By {{ case.author.all|join:", " }}{% endif %} + {% if case.condition %}{{ case.condition.name }}{% endif %} + {% if case.presentation %}{{ case.presentation.name }}{% endif %} + {% if case.subspecialty %}{{ case.subspecialty.name }}{% endif %} +
-
+
{# show up to three series modalities/examinations if present #} - {% for s in case.series.all|slice:":3" %} - - {% if s.modality %}{{ s.modality.modality }}{% endif %} - {% if s.examination %} / {{ s.examination.examination }}{% endif %} - - {% empty %} - No series - {% endfor %} -
+ {% for s in case.series.all|slice:":3" %} + + {% if s.modality %}{{ s.modality.modality }}{% endif %} + {% if s.examination %} / {{ s.examination.examination }}{% endif %} + + {% empty %} + No series + {% endfor %} +
-

{{ case.description }}

-
- {% endfor %} -{% else %} -
No cases found
-{% endif %} +

{{ case.description }}

+ + {% endfor %} + {% else %} +
No cases found
+ {% endif %}