From 6bdf2d19e9fec456135979b032e44b194fe1b38b Mon Sep 17 00:00:00 2001 From: Darby DeBruhl Date: Tue, 23 Apr 2024 13:49:44 -0400 Subject: [PATCH] update report_template.jinja to sort contents of Occurrence table alphabetically Unsure if sorting the Occurrence table was also implied in this issue: https://github.com/DOI-USGS/gems-tools-pro/issues/99#issue-2180305267 so I did them separately --- Scripts/report_template.jinja | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Scripts/report_template.jinja b/Scripts/report_template.jinja index 497f838..b8042c1 100644 --- a/Scripts/report_template.jinja +++ b/Scripts/report_template.jinja @@ -306,11 +306,12 @@ within the list of errors#} MapUnit {% if val["fds_units"] %} + {% set sorted_units = val["all_units"]|sort %} {% for k in val["fds_units"] %} {{k}} {% endfor %} - {% for mu in val["all_units"] %} + {% for mu in sorted_units %} {{mu}} {% for v in val["fds_units"].values() %} @@ -325,6 +326,7 @@ within the list of errors#} {% endif %} + {% endif %} {% if val["non_spatial"] %}
@@ -345,4 +347,4 @@ within the list of errors#} {% for n in val["inventory"] %} {{ n }}
{% endfor %} - \ No newline at end of file +