From 4dbc694df0b457dbb124d27c1570c15203ea11ce Mon Sep 17 00:00:00 2001 From: Étienne Loks Date: Tue, 9 May 2023 16:48:43 +0200 Subject: Main sheets add link to town sheet --- .../templates/ishtar/sheet_contextrecord.html | 3 +-- archaeological_files/templates/ishtar/sheet_file.html | 2 +- archaeological_finds/templates/ishtar/sheet_basefind.html | 2 +- archaeological_operations/templates/ishtar/sheet_operation.html | 2 +- archaeological_operations/templates/ishtar/sheet_site.html | 2 +- .../templates/ishtar/blocks/window_field_flex_detail_multiple.html | 2 +- 6 files changed, 6 insertions(+), 7 deletions(-) diff --git a/archaeological_context_records/templates/ishtar/sheet_contextrecord.html b/archaeological_context_records/templates/ishtar/sheet_contextrecord.html index 79f58b94d..7fc1a03e7 100644 --- a/archaeological_context_records/templates/ishtar/sheet_contextrecord.html +++ b/archaeological_context_records/templates/ishtar/sheet_contextrecord.html @@ -139,7 +139,6 @@
{% field_flex_multiple_obj "Excavation techniques" item 'excavation_technics' has_image %} {% field_flex_multiple_obj "Periods" item 'datings' has_image %} - {% field_flex "Town" item.town.label_with_areas '' '' has_image %} {% field_flex_multiple_obj "Documentation" item 'documentations' has_image %} {% field_flex "Opening date" item.opening_date '' '' has_image %} {% field_flex "Closing date" item.closing_date '' '' has_image %} @@ -170,7 +169,7 @@ {% endwith %}
- {% field_flex_multiple_full "Towns" item.operation.towns %} + {% field_flex_detail "Town" item.town has_image %}
{% endif %} diff --git a/archaeological_files/templates/ishtar/sheet_file.html b/archaeological_files/templates/ishtar/sheet_file.html index 7b6de41a1..6f4afbc78 100644 --- a/archaeological_files/templates/ishtar/sheet_file.html +++ b/archaeological_files/templates/ishtar/sheet_file.html @@ -91,7 +91,7 @@

{% trans "Geographic localisation" %}

- {% field_flex_multiple_obj "Towns" item 'towns' %} + {% field_flex_detail_multiple_full "Towns" item.towns %} {% field_flex_multiple_obj "Departments" item 'departments' %} {% field_flex "Main address" item.address %} {% field_flex "Complement" item.address_complement %} diff --git a/archaeological_finds/templates/ishtar/sheet_basefind.html b/archaeological_finds/templates/ishtar/sheet_basefind.html index 2de9f5afe..1923bf662 100644 --- a/archaeological_finds/templates/ishtar/sheet_basefind.html +++ b/archaeological_finds/templates/ishtar/sheet_basefind.html @@ -17,7 +17,7 @@ {% field_flex_detail "Operation" base_find.context_record.operation first %} {% field_flex_detail "Archaeological site" base_find.context_record.archaeological_site first %} {% field_flex_detail "Context record" base_find.context_record first %} - {% field_flex "Town" base_find.context_record.town_label_with_areas '' '' first %} + {% field_flex_detail "Town" base_find.context_record.town first %} {% field_flex "Parcel" base_find.context_record.parcel '' '' first %} {# START discovery dates #} diff --git a/archaeological_operations/templates/ishtar/sheet_operation.html b/archaeological_operations/templates/ishtar/sheet_operation.html index 43148d7e4..7fbff7202 100644 --- a/archaeological_operations/templates/ishtar/sheet_operation.html +++ b/archaeological_operations/templates/ishtar/sheet_operation.html @@ -300,7 +300,7 @@ {% if next %} {% field_flex "Towns" item|m2m_listing:'towns'|join:" ; " %} {% else %} - {% field_flex "Towns" item.cached_towns_label %} + {% field_flex_detail_multiple "Towns" item.towns %} {% endif %} {% field_flex "Address" item.address %} {% if not item.address %} diff --git a/archaeological_operations/templates/ishtar/sheet_site.html b/archaeological_operations/templates/ishtar/sheet_site.html index d8d5549b6..11717314b 100644 --- a/archaeological_operations/templates/ishtar/sheet_site.html +++ b/archaeological_operations/templates/ishtar/sheet_site.html @@ -74,7 +74,7 @@ {% if next %} {% field_flex_full "Towns" item|m2m_listing:'towns'|join:" ; " %} {% else %} - {% field_flex_full "Towns" item.towns_codes|join:" ; " %} + {% field_flex_detail_multiple_full "Towns" item.towns %} {% endif %} {% field_flex_full "National Geographic Institute locality" item.locality_ngi "
" "
" %} {% field_flex_full "Cadastral locality" item.locality_cadastral "
" "
" %} diff --git a/ishtar_common/templates/ishtar/blocks/window_field_flex_detail_multiple.html b/ishtar_common/templates/ishtar/blocks/window_field_flex_detail_multiple.html index b6faa0cc1..bc9583031 100644 --- a/ishtar_common/templates/ishtar/blocks/window_field_flex_detail_multiple.html +++ b/ishtar_common/templates/ishtar/blocks/window_field_flex_detail_multiple.html @@ -2,7 +2,7 @@
{% trans caption %}
{% for d in data %} - {% if forloop.counter0 %} ; {% endif %}{{d.link}} {{ d.item }} + {% if forloop.counter0 %} ; {% endif %}{{ d.item }}{{d.link}} {% endfor %}
{% endif %} -- cgit v1.2.3