From 4f63ed814f96bbc68c22c98b799c3911d62aa737 Mon Sep 17 00:00:00 2001 From: Étienne Loks Date: Tue, 19 Feb 2019 17:36:25 +0100 Subject: Geo: manage container and warehouse - manage geo save dependencies --- .../templates/ishtar/sheet_container.html | 12 ++++++++++++ .../templates/ishtar/sheet_warehouse.html | 15 ++++++++++++++- 2 files changed, 26 insertions(+), 1 deletion(-) (limited to 'archaeological_warehouse/templates') diff --git a/archaeological_warehouse/templates/ishtar/sheet_container.html b/archaeological_warehouse/templates/ishtar/sheet_container.html index 27cbf9bee..f40020a92 100644 --- a/archaeological_warehouse/templates/ishtar/sheet_container.html +++ b/archaeological_warehouse/templates/ishtar/sheet_container.html @@ -39,6 +39,18 @@ +{% if item.point_2d or item.multi_polygon %} +

{% trans "Localisation"%}

+
+ {% with geo_item=item %} + {% include "ishtar/blocks/sheet_simple_map.html"%} +
+ {% include "ishtar/blocks/sheet_coordinates.html"%} +
+ {% endwith %} +
+{% endif %} + {% if item.finds.count %}

{% trans "Content" %}

diff --git a/archaeological_warehouse/templates/ishtar/sheet_warehouse.html b/archaeological_warehouse/templates/ishtar/sheet_warehouse.html index eed484d5a..6be884e8e 100644 --- a/archaeological_warehouse/templates/ishtar/sheet_warehouse.html +++ b/archaeological_warehouse/templates/ishtar/sheet_warehouse.html @@ -31,13 +31,26 @@
{% field_flex "Person in charge" item.person_in_charge %} {% include "ishtar/blocks/sheet_creation_section.html" %} - {% include "ishtar/blocks/sheet_address_section.html" %} {% field_flex "Divisions" item.location_types|join:", " %} {% field_flex_full "Comment" item.comment "
" "
" %} {% include "ishtar/blocks/sheet_json.html" %}
+{% if item.point_2d or item.multi_polygon or item.address or item.address_complement or item.postal_code or item.town %} +

{% trans "Localisation"%}

+
+ {% with geo_item=item %} + {% include "ishtar/blocks/sheet_simple_map.html"%} +
+ {% include "ishtar/blocks/sheet_coordinates.html"%} + {% with full=True %}{% include "ishtar/blocks/sheet_address_section.html" %}{% endwith %} +
+ {% endwith %} +
+{% endif %} + + {% if item.containers.count %}

{% trans "Containers" %}

{% dynamic_table_document '' 'containers' 'location_id' item.pk 'TABLE_COLS' output %} -- cgit v1.2.3