summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorÉtienne Loks <etienne.loks@iggdrasil.net>2024-02-15 18:48:59 +0100
committerÉtienne Loks <etienne.loks@iggdrasil.net>2024-04-16 16:41:51 +0200
commitddea255a607c2cf9824d0146525fa618e5699118 (patch)
tree905c0e1fc9d94c5b9e9ef3b8ec49126dd1eca380
parentc0ca049bdeee7d3aa2b655ee4a2f24f2aa19de5b (diff)
downloadIshtar-ddea255a607c2cf9824d0146525fa618e5699118.tar.bz2
Ishtar-ddea255a607c2cf9824d0146525fa618e5699118.zip
✨ Sheet find - museum: museum fields, specific template
-rw-r--r--archaeological_finds/forms.py4
-rw-r--r--archaeological_finds/models_finds.py22
-rw-r--r--archaeological_finds/templates/ishtar/sheet_find.html31
-rw-r--r--archaeological_finds/templates/ishtar/sheet_museum_find.html608
-rw-r--r--archaeological_finds/templates/ishtar/sheet_museum_find_pdf.html14
-rw-r--r--archaeological_finds/templates/ishtar/sheet_museum_find_window.html3
6 files changed, 679 insertions, 3 deletions
diff --git a/archaeological_finds/forms.py b/archaeological_finds/forms.py
index 72dc6bfd2..e30a7bc8d 100644
--- a/archaeological_finds/forms.py
+++ b/archaeological_finds/forms.py
@@ -344,7 +344,7 @@ class BasicFindForm(CustomForm, ManageOldType):
label=_("Free ID"), validators=[validators.MaxLengthValidator(60)]
)
museum_id_prefix = forms.CharField(label=_("Museum ID prefix"), required=False)
- museum_id = forms.CharField(label=_("Museum ID"), required=False)
+ museum_id = forms.CharField(label=_("Museum inventory number"), required=False)
museum_id_suffix = forms.CharField(label=_("Museum ID suffix"), required=False)
museum_id_comment = forms.CharField(label=_("Comment on museum ID"), widget=forms.Textarea, required=False)
HEADERS["label"] = FormHeader(_("Identification"))
@@ -1476,7 +1476,7 @@ class FindSelect(GeoItemSelect, PeriodSelect):
)
label = forms.CharField(label=_("Free ID"))
denomination = forms.CharField(label=_("Denomination"))
- museum_id = forms.CharField(label=_("Museum ID"))
+ museum_id = forms.CharField(label=_("Museum inventory number"))
cache_complete_museum_id = forms.CharField(label=_("Complete museum ID"))
previous_id = forms.CharField(label=_("Previous ID"))
base_finds__excavation_id = forms.CharField(label=_("Excavation ID"))
diff --git a/archaeological_finds/models_finds.py b/archaeological_finds/models_finds.py
index fcba41308..030328d1d 100644
--- a/archaeological_finds/models_finds.py
+++ b/archaeological_finds/models_finds.py
@@ -1829,6 +1829,7 @@ class Find(
"excavation_ids",
"weight_string",
]
+ SHEET_ALTERNATIVES = [("museum", "museum_find")]
objects = UUIDModelManager()
# fields
@@ -1847,7 +1848,7 @@ class Find(
denomination = models.TextField(_("Denomination"), blank=True, default="")
# museum module IDs
museum_id_prefix = models.TextField(_("Museum ID prefix"), blank=True, default="")
- museum_id = models.TextField(_("Museum ID"), blank=True, default="")
+ museum_id = models.TextField(_("Museum inventory number"), blank=True, default="")
museum_id_suffix = models.TextField(_("Museum ID suffix"), blank=True, default="")
museum_id_comment = models.TextField(_("Comment on museum ID"), blank=True, default="")
laboratory_id = models.TextField(_("Laboratory ID"), blank=True, default="")
@@ -2204,6 +2205,25 @@ class Find(
]
)
+ @property
+ def has_museum_section(self):
+ for field in self._meta.fields:
+ if not field.name.startswith("museum_"):
+ continue
+ if getattr(self, field.name):
+ return True
+ return False
+
+ @property
+ def museum_entry_date_label(self):
+ from django.utils.formats import date_format
+ if not self.museum_entry_date:
+ return
+ dates = [date_format(self.museum_entry_date, format='SHORT_DATE_FORMAT', use_l10n=True)]
+ if self.museum_entry_date_end:
+ dates.append(date_format(self.museum_entry_date_end, format='SHORT_DATE_FORMAT', use_l10n=True))
+ return " / ".join(dates)
+
@classmethod
def hierarchic_fields(cls):
return ["container", "container_ref"]
diff --git a/archaeological_finds/templates/ishtar/sheet_find.html b/archaeological_finds/templates/ishtar/sheet_find.html
index c163b7d57..98295dd65 100644
--- a/archaeological_finds/templates/ishtar/sheet_find.html
+++ b/archaeological_finds/templates/ishtar/sheet_find.html
@@ -211,6 +211,37 @@
</div>
{% endif %}
+ {% if item.has_museum_section %}
+ <h3>{% trans "Museum / legal status" %}</h3>
+ <div class='row'>
+ {% field_flex "Museum ID prefix" item.museum_id_prefix %}
+ {% field_flex "Museum inventory number" item.museum_id %}
+ {% field_flex "Museum ID suffix" item.museum_id_suffix %}
+ {% field_flex "Comment on museum ID" item.museum_id_comment %}
+ {% field_flex_detail "Owner institution" item.museum_owner_institution %}
+ {% field_flex_detail "Custodian institution" item.museum_custodian_institution %}
+ {% field_flex "Depositor inventory number" item.museum_depositor_inventory_number %}
+ {% field_flex "Collections entry mode" item.museum_collection_entry_mode %}
+ {% field_flex "Comment on museum entry mode" item.museum_entry_mode_comment %}
+ {% trans "Museum entry date" as museum_entry_date_label %}
+ {% field_flex museum_entry_date_label item.museum_entry_date_label %}
+ {% field_flex "Comment on museum entry date" item.museum_entry_date_comment %}
+ {% field_flex "Name of donor, testator or vendor" item.museum_donor %}
+ {% field_flex_multiple_obj "Presence of inventory marking" item "museum_inventory_marking_presence" %}
+ {% field_flex_multiple_obj "Type of marking" item "museum_marking_type" %}
+ {% field_flex "Comment on marking" item.museum_marking_comment %}
+ {% field_flex "Collection" item.museum_collection %}
+ {% field_flex_multiple_obj "Former collection" item "museum_former_collections" %}
+ {% field_flex "Inventory entry year" item.museum_inventory_entry_year %}
+ {% field_flex "Conformity with inventory" item.museum_inventory_conformity %}
+ {% field_flex "Comment of non-conformity" item.museum_non_conformity_comment %}
+ {% field_flex "Inventory transcript" item.museum_inventory_transcript %}
+ {% field_flex "Original/reproduction" item.museum_original_repro %}
+ {% field_flex "Date of museum allocation" item.museum_allocation_date|date:"SHORT_DATE_FORMAT" %}
+ {% field_flex "Purchase price" item.museum_purchase_price %}
+ </div>
+ {% endif %}
+
{% with dating_list=item|m2m_listing:"datings" %}
{% if dating_list or item.dating_comment or item.cultural_attributions_count %}
<h3>{% trans "Dating" %}</h3>
diff --git a/archaeological_finds/templates/ishtar/sheet_museum_find.html b/archaeological_finds/templates/ishtar/sheet_museum_find.html
new file mode 100644
index 000000000..e1c82d791
--- /dev/null
+++ b/archaeological_finds/templates/ishtar/sheet_museum_find.html
@@ -0,0 +1,608 @@
+{% extends "ishtar/sheet.html" %}
+{% load i18n l10n ishtar_helpers window_field from_dict link_to_window window_tables window_header humanize %}
+
+{% block head_title %}<strong>{% trans "Find" %}</strong>{% if item.denomination %} - {{item.denomination|default:""}}{% endif %} - {{item.cache_complete_museum_id|default:""}}{% endblock %}
+
+{% block toolbar %}
+{% window_find_nav item window_id 'show-find' 'find_modify' 'show-historized-find' 'revert-find' previous next 1 baskets %}
+{% endblock %}
+
+{% block content %}
+
+{% if item.downstream_treatment %}
+<div class="alert alert-warning" role="alert">
+ {% trans "This sheet has a downstream treatment: it is related to an old version of the find." %}
+</div>
+{% endif %}
+
+{# trick to set to null non existing variable #}
+{% with permission_view_document=permission_view_document %}
+{% with permission_view_own_document=permission_view_own_document %}
+{% with permission_change_own_geovectordata=permission_change_own_geovectordata %}
+{% with permission_change_geovectordata=permission_change_geovectordata %}
+
+{% with permission_change_geo=permission_change_own_geovectordata|or_:permission_change_geovectordata %}
+
+{% with non_modif_treatments_count=item.non_modif_treatments_count %}
+{% with associated_treatment_files_count=item.associated_treatment_files_count %}
+
+{% with can_view_container=permission_view_own_container|or_:permission_view_container %}
+{% with display_warehouse_treatments=item.container|or_:item.container_ref|or_:item.upstream_treatment|or_:item.downstream_treatment|or_:non_modif_treatments_count|or_:associated_treatment_files_count %}
+{% with can_view_documents=permission_view_own_document|or_:permission_view_document %}
+{% with display_documents=can_view_documents|and_:item.documents_count %}
+{% with has_image=item.images_number %}
+
+{% if output != "ODT" and output != "PDF"%}
+<ul class="nav nav-tabs" id="{{window_id}}-tabs" role="tablist">
+ <li class="nav-item">
+ <a class="nav-link active" id="{{window_id}}-identification-tab"
+ data-toggle="tab" href="#{{window_id}}-identification" role="tab"
+ aria-controls="{{window_id}}-identification" aria-selected="true">
+ {% trans "Identification / Description" %}
+ </a>
+ </li>
+ <li class="nav-item">
+ <a class="nav-link" id="{{window_id}}-basefind-tab"
+ data-toggle="tab" href="#{{window_id}}-basefind" role="tab"
+ aria-controls="{{window_id}}-basefind" aria-selected="false">
+ {% trans "Archaeological context" %}
+ </a>
+ </li>
+ {% if display_warehouse_treatments %}
+ <li class="nav-item">
+ <a class="nav-link" id="{{window_id}}-warehouse-tab"
+ data-toggle="tab" href="#{{window_id}}-warehouse" role="tab"
+ aria-controls="{{window_id}}-warehouse" aria-selected="false">
+ {% trans "Preservation / Treatments" %}
+ </a>
+ </li>
+ {% endif %}
+ {% if display_documents %}
+ <li class="nav-item">
+ <a class="nav-link" id="{{window_id}}-documents-tab"
+ data-toggle="tab" href="#{{window_id}}-documents" role="tab"
+ aria-controls="{{window_id}}-treatments" aria-selected="false">
+ {% trans "Documents" %}
+ </a>
+ </li>
+ {% endif %}
+ {% if not is_external and SHOW_GEO %}
+ <li class="nav-item">
+ <a class="nav-link" id="{{window_id}}-geodata-tab"
+ data-toggle="tab" href="#{{window_id}}-geodata" role="tab"
+ aria-controls="{{window_id}}-geodata" aria-selected="false">
+ {% trans "Geographic data" %}
+ </a>
+ </li>
+ {% endif %}
+ {% if item.data %}
+ <li class="nav-item">
+ <a class="nav-link" id="{{window_id}}-json-tab"
+ data-toggle="tab" href="#{{window_id}}-json" role="tab"
+ aria-controls="{{window_id}}-json" aria-selected="false">
+ {% trans "Custom fields" %}
+ </a>
+ </li>
+ {% endif %}
+</ul>
+{% endif %}
+
+<div class="tab-content" id="{{window_id}}-tab-content">
+
+ <div class="tab-pane fade show active" id="{{window_id}}-identification"
+ role="tabpanel" aria-labelledby="{{window_id}}-identification-tab">
+ {% if has_image %}
+ <div class="clearfix">
+ <div class="card float-left col-12 col-md-6 col-lg-4">
+ {% include "ishtar/blocks/window_image.html" %}
+ </div>
+ {% endif %}
+ <h3>{% trans "Identification" %}</h3>
+
+ <div class='text-center'>
+ {% include "ishtar/blocks/sheet_external_id.html" %}
+ {# no complete identifier #}
+ </div>
+
+ <div class='row'>
+ {% field_flex "Denomination" item.denomination %}
+ {% field_flex "Complete museum ID" item.cache_complete_museum_id %}
+ {% field_flex "Free ID" item.label %}
+ {% field_flex "Previous ID" item.previous_id %}
+ {% field_flex "Excavation ID" item.excavation_ids %}
+ {% field_flex "Laboratory ID" item.laboratory_id %}
+ {% field_flex "Seal number" item.seal_number %}
+ {# no index admin #}
+ {% field_flex_full "Mark" item.mark "<pre>" "</pre>" %}
+ </div>
+
+ <h3>{% trans "Description" %}</h3>
+ <div class='row'>
+ {% field_flex_full "Description" item.description "<pre>" "</pre>" %}
+ {% field_flex_full "Public description" item.public_description "<pre>" "</pre>" %}
+ {% field_flex "Is complete?" item.is_complete %}
+ {% with material=item.get_hierarchical_material_types %}{% if material %}
+ {% field_flex "Material types" material %}{% else %}
+ {% field_flex_multiple_obj "Material types" item 'material_types' %}
+ {% endif %}{% endwith %}
+ {% field_flex "Material type quality" item.material_type_quality %}
+ {% field_flex_multiple_obj "Technical processes" item 'technical_processes' %}
+ {% field_flex_full "Comment on the material" item.material_comment "<pre>" "</pre>" %}
+ {% field_flex_multiple_obj "Object types" item 'object_types' %}
+ {% field_flex "Object type quality" item.object_type_quality %}
+ {% field_flex_multiple_obj "Functional areas" item 'functional_areas' %}
+ {% field_flex_multiple_obj "Technical areas" item 'technical_areas' %}
+ {% field_flex "Number of remains" item.find_number %}
+ {% field_flex "Minimum number of individuals (MNI)" item.min_number_of_individuals %}
+ {% field_flex_full "Comment on quantity" item.quantity_comment "<pre>" "</pre>" %}
+ {% field_flex_full "Decoration" item.decoration "<pre>" "</pre>" %}
+ {% field_flex_full "Inscription" item.inscription "<pre>" "</pre>" %}
+ {% field_flex "Manufacturing place" item.manufacturing_place %}
+ {% field_flex_multiple_obj "Communicability" item 'communicabilities' %}
+ {% field_flex_full "Comment" item.comment "<pre>" "</pre>" %}
+ </div>
+
+ {% if item.has_museum_section %}
+ <h3>{% trans "Museum / legal status" %}</h3>
+ <div class='row'>
+ {% field_flex "Museum ID prefix" item.museum_id_prefix %}
+ {% field_flex "Museum inventory number" item.museum_id %}
+ {% field_flex "Museum ID suffix" item.museum_id_suffix %}
+ {% field_flex "Comment on museum ID" item.museum_id_comment %}
+ {% field_flex_detail "Owner institution" item.museum_owner_institution %}
+ {% field_flex_detail "Custodian institution" item.museum_custodian_institution %}
+ {% field_flex "Depositor inventory number" item.museum_depositor_inventory_number %}
+ {% field_flex "Collections entry mode" item.museum_collection_entry_mode %}
+ {% field_flex "Comment on museum entry mode" item.museum_entry_mode_comment %}
+ {% trans "Museum entry date" as museum_entry_date_label %}
+ {% field_flex museum_entry_date_label item.museum_entry_date_label %}
+ {% field_flex "Comment on museum entry date" item.museum_entry_date_comment %}
+ {% field_flex "Name of donor, testator or vendor" item.museum_donor %}
+ {% field_flex_multiple_obj "Presence of inventory marking" item "museum_inventory_marking_presence" %}
+ {% field_flex_multiple_obj "Type of marking" item "museum_marking_type" %}
+ {% field_flex "Comment on marking" item.museum_marking_comment %}
+ {% field_flex "Collection" item.museum_collection %}
+ {% field_flex_multiple_obj "Former collection" item "museum_former_collections" %}
+ {% field_flex "Inventory entry year" item.museum_inventory_entry_year %}
+ {% field_flex "Conformity with inventory" item.museum_inventory_conformity %}
+ {% field_flex "Comment of non-conformity" item.museum_non_conformity_comment %}
+ {% field_flex "Inventory transcript" item.museum_inventory_transcript %}
+ {% field_flex "Original/reproduction" item.museum_original_repro %}
+ {% field_flex "Date of museum allocation" item.museum_allocation_date|date:"SHORT_DATE_FORMAT" %}
+ {% field_flex "Purchase price" item.museum_purchase_price %}
+ </div>
+ {% endif %}
+
+ {% if item.length or item.width or item.height or item.diameter or item.thickness or item.volume or item.weight_string or item.dimensions_comment or item.clutter_long_side or item.clutter_short_side or item.clutter_height %}
+ <h3>{% trans "Dimensions" %}</h3>
+ <div class='row'>
+ {% field_flex "Length (cm)" item.length %}
+ {% field_flex "Width (cm)" item.width %}
+ {% field_flex "Height (cm)" item.height %}
+ {% field_flex "Thickness (cm)" item.thickness %}
+ {% field_flex "Diameter (cm)" item.diameter %}
+ {% field_flex "Circumference (cm)" item.circumference %}
+ {% field_flex "Volume (l)" item.volume %}
+ {% trans "Weight (g)" as weight_label %}
+ {% field_flex weight_label item.weight_string %}
+ {% field_flex "Clutter long side (cm)" item.clutter_long_side %}
+ {% field_flex "Clutter short side (cm)" item.clutter_short_side %}
+ {% field_flex "Clutter height (cm)" item.clutter_height %}
+ {% field_flex_full "Dimensions comment" item.dimensions_comment "<pre>" "</pre>" %}
+ </div>
+ {% endif %}
+
+ {% with dating_list=item|m2m_listing:"datings" %}
+ {% if dating_list or item.dating_comment or item.cultural_attributions_count %}
+ <h3>{% trans "Dating" %}</h3>
+ {% if item.cultural_attributions_count %}
+ <div class='row'>
+ {% field_flex_multiple_obj "Cultural attributions" item 'cultural_attributions' %}
+ </div>
+ {% endif %}
+ <table id='{{window_id}}-datings' class="table table-striped">
+ <tr>
+ <th>{% trans "Chronological period" %}</th>
+ <th>{% trans "Start date" %}</th>
+ <th>{% trans "End date" %}</th>
+ <th>{% trans "Dating type" %}</th>
+ <th>{% trans "Quality" %}</th>
+ <th>{% trans "Precise on dating" %}</th>
+ </tr>
+ {% for dating in dating_list %}
+ <tr>
+ <td>
+ {{dating.period}}
+ </td>
+ <td>
+ {{dating.start_date|default_if_none:"-"}}
+ </td>
+ <td>
+ {{dating.end_date|default_if_none:"-"}}
+ </td>
+ <td>
+ {{dating.dating_type|default_if_none:"-"}}
+ </td>
+ <td>
+ {{dating.quality|default_if_none:"-"}}
+ </td>
+ <td>
+ {{dating.precise_dating|default_if_none:"-"}}
+ </td>
+ </tr>
+ {% endfor %}
+ </table>
+ <div class='row'>
+ {% field_flex_full "Comment on dating" item.dating_comment "<pre>" "</pre>" %}
+ </div>
+ {% endif %}
+ {% endwith %}
+
+ <h3>{% trans "Sheet" %}</h3>
+ <div class='row'>
+ {% trans "Checked" as checked_label %}
+ {% field_flex checked_label item.checked_type %}
+ {% with item.check_date|date:"SHORT_DATE_FORMAT" as check_date %}
+ {% if check_date %}{% field_flex "Check date" check_date %}{% endif %}
+ {% endwith %}
+ {% include "ishtar/blocks/sheet_creation_section.html" %}
+ </div>
+ {% if has_image %}
+ </div>
+ {% endif %}
+ </div>
+
+ <div class="tab-pane fade" id="{{window_id}}-basefind"
+ role="tabpanel" aria-labelledby="{{window_id}}-basefind-tab">
+ <ul class="nav nav-pills" role="tablist">
+ {% if is_external %}
+ {% for base_find in item.base_finds_list %}
+ <li class="nav-item">
+ <a class="nav-link{% if forloop.first %} active{% endif %}"
+ data-toggle="tab" href="#{{window_id}}-base-find-{{forloop.counter}}"
+ role="tab">
+ {% if base_find.complete_identifier %}{{ base_find.complete_identifier }}{% else %}{{base_find.short_id}}{% endif %}
+ </a>
+ </li>
+ {% endfor %}
+ {% else %}
+ {% for base_find in item.base_finds.all %}
+ <li class="nav-item">
+ <a class="nav-link{% if forloop.first %} active{% endif %}"
+ data-toggle="tab" href="#{{window_id}}-base-find-{{forloop.counter}}"
+ role="tab">
+ {% if base_find.complete_identifier %}{{ base_find.complete_identifier }}{% else %}{{base_find.short_id}}{% endif %}
+ </a>
+ </li>
+ {% endfor %}
+ {% endif %}
+ </ul>
+
+ <div class="tab-content">
+ {% if is_external %}
+ {% for base_find in item.base_finds_list %}
+ {% with first=forloop.first %}
+ {% include "ishtar/sheet_basefind.html" %}
+ {% endwith %}
+ {% endfor %}
+ {% else %}
+ {% for base_find in item.base_finds.all %}
+ {% with first=forloop.first %}
+ {% include "ishtar/sheet_basefind.html" %}
+ {% endwith %}
+ {% endfor %}
+ {% endif %}
+ </div>
+ </div>
+
+ {% if display_warehouse_treatments %}
+ <div class="tab-pane fade" id="{{window_id}}-warehouse"
+ role="tabpanel" aria-labelledby="{{window_id}}-warehouse-tab">
+ {% comment %}
+ {% if item.collection %}
+ <div class='row'>
+ {% field_flex_detail "Collection" item.collection "large" %}
+ </div>
+ {% endif %}
+ {% endcomment %}
+ {% if item.integrities_count or item.remarkabilities_count or item.conservatory_state or item.conservatory_comment or item.alterations.count or item.alteration_causes.count or item.preservation_to_considers.count or item.appraisal_date or item.treatment_emergency or item.insurance_value or item.estimated_value %}
+ <h3>{% trans "Preservation" %}</h3>
+ <div class='row'>
+ {% field_flex_multiple_obj "Integrity / interest" item 'integrities' %}
+ {% field_flex_multiple_obj "Remarkability" item 'remarkabilities' %}
+ {% field_flex "Conservatory state" item.conservatory_state %}
+ {% field_flex_multiple_obj "Alteration" item 'alterations' %}
+ {% field_flex_multiple_obj "Alteration cause" item 'alteration_causes' %}
+ {% field_flex_multiple_obj "Recommended treatments" item 'preservation_to_considers' %}
+ {% field_flex "Treatment emergency" item.treatment_emergency %}
+ {% field_flex "Estimated value" item.estimated_value|default_if_none:''|intcomma '' ' '|add:CURRENCY %}
+ {% field_flex "Insurance value" item.insurance_value|default_if_none:''|intcomma '' ' '|add:CURRENCY %}
+ {% field_flex "Appraisal date" item.appraisal_date %}
+ {% field_flex_full "Conservatory comment" item.conservatory_comment "<pre>" "</pre>" %}
+ </div>
+ {% endif %}
+ {% if item.container or item.container_ref %}
+ {% if can_view_container %}
+ <h3>{% trans "Warehouse - container" %}</h3>
+ <div class='row'>
+ {% if item.container_ref != item.container and item.container_ref %}
+ <dl class="col-12 flex-wrap">
+ <dt>{% trans "Reference container" %}</dt>
+ <dd>
+ <nav aria-label="breadcrumb">
+ <ol class="breadcrumb">
+ {% if not is_external %}
+ {% for loca in item.container_ref.get_localisations %}
+ <li class="breadcrumb-item">
+ {{loca.short_label}}&nbsp;{{loca|simple_link_to_window}}
+ </li>
+ {% endfor %}
+ <li class="breadcrumb-item">
+ {{item.container_ref.short_label}}&nbsp;{{item.container_ref|simple_link_to_window}}
+ </li>
+ {% else %}
+ {{item.container_ref}}
+ {% endif %}
+ </ol>
+ </nav>
+ </dd>
+ </dl>
+ {% endif %}
+ {% if item.container %}
+ <dl class="col-12 flex-wrap">
+ <dt>
+ {% if item.container_ref != item.container %}
+ {% trans "Current container" %}{% else %}
+ {% trans "Reference container / current container" %}
+ {% endif %}
+ </dt>
+ <dd>
+ <nav aria-label="breadcrumb">
+ <ol class="breadcrumb">
+ {% if not is_external %}
+ {% for loca in item.container.get_localisations %}
+ <li class="breadcrumb-item">
+ {{loca.short_label}}&nbsp;{{loca|simple_link_to_window}}
+ </li>
+ {% endfor %}
+ <li class="breadcrumb-item">
+ {{item.container.short_label}}&nbsp;{{item.container|simple_link_to_window}}
+ </li>
+ {% else %}
+ {% for loca in item.container.localisation_list %}
+ <li class="breadcrumb-item">
+ {{loca}}
+ </li>
+ {% endfor %}
+ <li class="breadcrumb-item">
+ {{item.container.short_label}}
+ </li>
+ {% endif %}
+ </ol>
+ </nav>
+ </dd>
+ </dl>
+ {% if item.container.index %}
+ <div class='row'>
+ <dl class="col-12 flex-wrap">
+ <dt>{% trans "Index" %}</dt>
+ <dd>
+ {{ item.container.location }} - {{ item.container.index }}
+ </dd>
+ </dl>
+ </div>
+ {% endif %}
+ {% endif %}
+ </div>
+ {% endif %}
+
+
+ <div class="alert alert-info" role="alert">
+ <i class="fa fa-info-circle" aria-hidden="true"></i> &nbsp;
+ {% trans "Container information not available." %}
+ </div>
+
+
+ {% endif %}
+ {% if item.upstream_treatment or item.downstream_treatment or non_modif_treatments_count %}
+ {% if non_modif_treatments_count %}
+ <h3>{% trans "Simple treatments"%}</h3>
+ <table id='{{window_id}}-treatments' class="table table-striped">
+ <tr>
+ <th>&nbsp;</th>
+ <th>{% trans "Year - index" %}</th>
+ <th>{% trans "Label" %}</th>
+ <th>{% trans "Type" %}</th>
+ <th>{% trans "State" %}</th>
+ <th>{% trans "Related finds (max. 15 displayed)" %}</th>
+ <th>{% trans "Doer" %}</th>
+ <th>{% trans "Container" %}</th>
+ <th>{% trans "Start date" %}</th>
+ <th>{% trans "End date" %}</th>
+ </tr>
+ {# {% for treatment in item.treatments.all %} #}
+ {% for items, treatment in item.non_modif_treatments %}
+ <tr>
+ <td>
+ <a class="display_details" href="#"
+ onclick="load_window('{% url 'show-treatment' treatment.id %}/');">
+ <i class="fa fa-info-circle" aria-hidden="true"></i>
+ </a>
+ </td>
+ <td class='string'>{{ treatment.year }} - {{treatment.index}}</td>
+ <td class='string'>{{ treatment.label|default_if_none:"-" }}</td>
+ <td class='string'>{{ treatment.treatment_types_lbl }}</td>
+ <td class='string'>{{ treatment.treatment_state|default_if_none:"-" }}</td>
+ <td class='item-list'>{% for it in items %}<span>{{it}} {{it|link_to_window:request}}</span>{% endfor %}</td>
+ <td class='string'>{{ treatment.person|default_if_none:"-" }}</td>
+ <td class='string'>{{ treatment.container|default_if_none:"-" }}</td>
+ <td class='string'>{{ treatment.start_date|default_if_none:"-" }}</td>
+ <td class='string'>{{ treatment.end_date|default_if_none:"-" }}</td>
+ </tr>
+ {% endfor %}
+ </table>
+ {% endif %}
+
+ {% if item.upstream_treatment %}
+ <h3>{% trans "Upstream treatment" %}</h3>
+ <table id='{{window_id}}-upstream' class="table table-striped">
+ <tr>
+ <th>&nbsp;</th>
+ <th>{% trans "Year - index" %}</th>
+ <th>{% trans "Label" %}</th>
+ <th>{% trans "Type" %}</th>
+ <th>{% trans "State" %}</th>
+ <th>{% trans "Related finds (max. 15 displayed)" %}</th>
+ <th>{% trans "Doer" %}</th>
+ <th>{% trans "Container" %}</th>
+ <th>{% trans "Start date" %}</th>
+ <th>{% trans "End date" %}</th>
+ </tr>
+ {% for items, treatment in item.limited_upstream_treatments %}
+ <tr>
+ <td>
+ <a class="display_details" href="#"
+ onclick="load_window('{% url 'show-treatment' treatment.id %}/');">
+ <i class="fa fa-info-circle" aria-hidden="true"></i>
+ </a>
+ </td>
+ <td class='string'>{{ treatment.year }} - {{treatment.index}}</td>
+ <td class='string'>{{ treatment.label|default_if_none:"-" }}</td>
+ <td class='string'>{{ treatment.treatment_types_lbl }}</td>
+ <td class='string'>{{ treatment.treatment_state|default_if_none:"-" }}</td>
+ <td class='item-list'>{% for it in items %}<span>{{it}} {{it|link_to_window:request}}</span>{% endfor %}</td>
+ <td class='string'>{{ treatment.person|default_if_none:"-" }}</td>
+ <td class='string'>{{ treatment.container|default_if_none:"-" }}</td>
+ <td class='string'>{{ treatment.start_date|default_if_none:"-" }}</td>
+ <td class='string'>{{ treatment.end_date|default_if_none:"-" }}</td>
+ </tr>
+ {% endfor %}
+ </table>
+ <p class='tool'><a class='badge' href="{% url 'get-upstreamtreatment' 'csv' %}?submited=1&amp;find_id={{item.pk|unlocalize}}" target="_blank" title='{% trans "Export as CSV"%}'>{% trans "CSV" %}</a> ({{ENCODING}})</p>
+ {% endif %}
+
+ {% if item.downstream_treatment %}
+ <h3>{% trans "Downstream treatment" %}</h3>
+ <table id='{{window_id}}-downstream' class="table table-striped">
+ <tr>
+ <th>&nbsp;</th>
+ <th>{% trans "Year - index" %}</th>
+ <th>{% trans "Label" %}</th>
+ <th>{% trans "Type" %}</th>
+ <th>{% trans "State" %}</th>
+ <th>{% trans "Related finds (max. 15 displayed)" %}</th>
+ <th>{% trans "Doer" %}</th>
+ <th>{% trans "Container" %}</th>
+ <th>{% trans "Start date" %}</th>
+ <th>{% trans "End date" %}</th>
+ </tr>
+ {% for items, treatment in item.limited_downstream_treatments %}
+ <tr>
+ <td>
+ <a class="display_details" href="#"
+ onclick="load_window('{% url 'show-treatment' treatment.id %}/');">
+ <i class="fa fa-info-circle" aria-hidden="true"></i>
+ </a>
+ </td>
+ <td class='string'>{{ treatment.year }} - {{treatment.index}}</td>
+ <td class='string'>{{ treatment.label|default_if_none:"-" }}</td>
+ <td class='string'>{{ treatment.treatment_types_lbl }}</td>
+ <td class='string'>{{ treatment.treatment_state|default_if_none:"-" }}</td>
+ <td class='item-list'>{% for it in items %}<span>{{it}} {{ it|link_to_window:request}}</span>{% endfor %}</td>
+ <td class='string'>{{ treatment.person|default_if_none:"" }}</td>
+ <td class='string'>{{ treatment.container|default_if_none:"-" }}</td>
+ <td class='string'>{{ treatment.start_date|default_if_none:"" }}</td>
+ <td class='string'>{{ treatment.end_date|default_if_none:"" }}</td>
+ </tr>
+ {% endfor %}
+ </table>
+
+ <p class='tool'><a class='badge' href="{% url 'get-downstreamtreatment' 'csv' %}?submited=1&amp;find_id={{item.pk|unlocalize}}" target="_blank">{% trans "CSV" %}</a> ({{ENCODING}})</p>
+ {% endif %}
+ {% endif %}
+ {% if item.associated_treatment_files_count %}
+ <h3>{% trans "Treatment requests" %}</h3>
+ <table id='{{window_id}}-treatment-files' class="table table-striped">
+ <tr>
+ <th>&nbsp;</th>
+ <th>{% trans "Year - index" %}</th>
+ <th>{% trans "Type" %}</th>
+ <th>{% trans "Name" %}</th>
+ <th>{% trans "Person in charge" %}</th>
+ <th>{% trans "Applicant" %}</th>
+ <th>{% trans "Applicant organisation" %}</th>
+ <th>{% trans "Reception date" %}</th>
+ <th>{% trans "End date" %}</th>
+ </tr>
+ {% for treatment_file in item.associated_treatment_files %}
+ <tr>
+ <td>
+ <a class="display_details" href="#"
+ onclick="load_window('{% url 'show-treatmentfile' treatment_file.id %}/');">
+ <i class="fa fa-info-circle" aria-hidden="true"></i>
+ </a>
+ </td>
+ <td class='string'>{{ treatment_file.year }} - {{treatment_file.index}}</td>
+ <td class='string'>{{ treatment_file.type }}</td>
+ <td class='string'>{{ treatment_file.name|default_if_none:"-" }}</td>
+ <td class='string'>{{ treatment_file.in_charge|default_if_none:"" }}</td>
+ <td class='string'>{{ treatment_file.applicant|default_if_none:"" }}</td>
+ <td class='string'>{{ treatment_file.applicant_organisation|default_if_none:"" }}</td>
+ <td class='string'>{{ treatment_file.reception_date|default_if_none:"" }}</td>
+ <td class='string'>{{ treatment_file.end_date|default_if_none:"" }}</td>
+ </tr>
+ {% endfor %}
+ </table>
+ {% endif %}
+ </div>
+ {% endif %}
+ {% if display_documents %}
+ <div class="tab-pane fade" id="{{window_id}}-documents"
+ role="tabpanel" aria-labelledby="{{window_id}}-documents-tab">
+ {% trans "Associated documents" as finds_docs %}
+ {% if item.documents.count %}
+ {% dynamic_table_document finds_docs 'documents' 'finds' item.pk '' output %}
+ {% elif item.documents_list %}
+ <h3>{{finds_docs}}</h3>
+ {% include "ishtar/blocks/api_document_list.html" %}
+ {% endif %}
+ </div>
+ {% endif %}
+
+ {% if not is_external and SHOW_GEO %}
+ <div class="tab-pane fade" id="{{window_id}}-geodata"
+ role="tabpanel" aria-labelledby="{{window_id}}-geodata-tab">
+ <h3>{% trans "Geographic data" %}</h3>
+
+ {% with find_id=item.pk %}
+ {% for base_find in item.base_finds.all %}
+ {% with geo_item=base_find %}
+ <h4>{% if base_find.complete_identifier %}{{ base_find.complete_identifier }}{% else %}{{base_find.short_id}}{% endif %}</h4>
+ {% with current_geolabel=base_find %}
+ {% include "ishtar/blocks/sheet_geographic.html" %}
+ {% endwith %} {% endwith %}
+ {% endfor %}
+ {% endwith %}
+
+ </div>
+ {% endif %}
+
+ {% if item.data and item.data|length > 0 %}
+ <div class="tab-pane fade" id="{{window_id}}-json"
+ role="tabpanel" aria-labelledby="{{window_id}}-json-tab">
+ {% include "ishtar/blocks/sheet_json.html" %}
+ </div>
+ {% endif %}
+</div>
+
+{% endwith %} {% endwith %} {% endwith %} {% endwith %}{% endwith %}{% endwith %}{% endwith %}{% endwith %}{% endwith %}{% endwith %}{% endwith %}{% endwith %}
+
+<script type='text/javascript'>
+ $( "#{{window_id}}-tabs" ).on( "tabsactivate", function( event, ui ) {
+ console.log("ok");
+ update_all_map_display();
+ } );
+</script>
+
+{% endblock %}
+
diff --git a/archaeological_finds/templates/ishtar/sheet_museum_find_pdf.html b/archaeological_finds/templates/ishtar/sheet_museum_find_pdf.html
new file mode 100644
index 000000000..b7deed171
--- /dev/null
+++ b/archaeological_finds/templates/ishtar/sheet_museum_find_pdf.html
@@ -0,0 +1,14 @@
+{% extends "ishtar/sheet_museum_find.html" %}
+{% block header %}
+{% endblock %}
+{% block main_head %}
+{{ block.super }}
+<div id="pdfheader">
+Ishtar &ndash; {{APP_NAME}} &ndash; {{item}}
+</div>
+{% endblock %}
+{%block head_sheet%}{%endblock%}
+{%block main_foot%}
+</body>
+</html>
+{%endblock%}
diff --git a/archaeological_finds/templates/ishtar/sheet_museum_find_window.html b/archaeological_finds/templates/ishtar/sheet_museum_find_window.html
new file mode 100644
index 000000000..62587cefc
--- /dev/null
+++ b/archaeological_finds/templates/ishtar/sheet_museum_find_window.html
@@ -0,0 +1,3 @@
+{% extends "ishtar/sheet_museum_find.html" %}
+{% block main_head %}{%endblock%}
+{% block main_foot %}{%endblock%}