From 0f96790ca2866d205b262c96ddb1b155abb80ef6 Mon Sep 17 00:00:00 2001 From: Étienne Loks Date: Mon, 6 Apr 2020 12:31:38 +0200 Subject: New container localisation - adapt sheets, imports --- .../templates/ishtar/sheet_container.html | 63 +++++++++++++++------- 1 file changed, 43 insertions(+), 20 deletions(-) (limited to 'archaeological_warehouse/templates') diff --git a/archaeological_warehouse/templates/ishtar/sheet_container.html b/archaeological_warehouse/templates/ishtar/sheet_container.html index ffc533513..1bb004071 100644 --- a/archaeological_warehouse/templates/ishtar/sheet_container.html +++ b/archaeological_warehouse/templates/ishtar/sheet_container.html @@ -1,7 +1,10 @@ {% extends "ishtar/sheet.html" %} -{% load i18n window_header window_field window_tables %} +{% load i18n window_header window_field window_tables link_to_window %} -{% block head_title %}{% trans "Container" %} - {{ item.reference|default:"" }} ({{ item.container_type|default:"" }}){% endblock %} +{% block head_title %}{% trans "Container" %} - +{{ item.container_type|default:"" }} {{ item.reference|default:"" }} - +{{ item.location.name|default:"" }} +{% endblock %} {% block toolbar %} {% window_nav item window_id 'show-container' 'container_modify' '' '' previous next 1 %} @@ -19,9 +22,8 @@ {% else %}
{% endif %} -

{{ item.reference|default:"" }}

-

{{ item.container_type|default:"" }}

-

{{ item.responsible.name }} - {{ item.index }}

+

{{ item.container_type|default:"" }} {{ item.reference|default:"" }}

+

{{ item.location.name }} - {{ item.index }}

{{ item.old_reference|default:"" }}

{% include "ishtar/blocks/sheet_external_id.html" %}
@@ -30,36 +32,57 @@ {% else %}
{% endif %} - {% field_flex_detail "Responsible warehouse" item.responsible %} - {% field_flex_detail "Location (warehouse)" item.location %} + {% field_flex_detail "Warehouse" item.location %} + {% if item.parent %} +
+
{% trans "Location" %}
+
+ +
+
+ {% endif %} {% include "ishtar/blocks/sheet_creation_section.html" %} - {% field_flex "Location" item.precise_location %} {% field_flex_full "Comment" item.comment "
" "
" %} {% include "ishtar/blocks/sheet_json.html" %}
+{% if item.container_content.count or item.children.count %} +

{% trans "Content" %}

+ +{% if item.children.count %} +{% trans "Containers" as container_lbl %} +{% dynamic_table_document container_lbl 'containers' 'parent' item.pk 'TABLE_COLS' output 'large' %} +{% endif %} + +{% if item.container_content.count %} +{% trans "Finds" as finds_lbl %} +{% dynamic_table_document finds_lbl 'finds_inside_container' 'container' item.pk 'TABLE_COLS' output 'large' %} +{% endif %} + +{% endif %} + +{% if PROFILE.locate_warehouses %} {% if item.point_2d or item.multi_polygon %}

{% trans "Localisation"%}

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

{% trans "Content" %}

-{% dynamic_table_document finds 'finds' 'container' item.pk 'TABLE_COLS' output 'large' %} -{% endif %} - -{% if item.finds_ref.count %} -

{% trans "Reference content" %}

-{% dynamic_table_document finds 'finds' 'container_ref' item.pk 'TABLE_COLS' output 'large' %} {% endif %} {% endblock %} -- cgit v1.2.3