From a930c0a56b2cba4799e9caf76375b23f366feaf6 Mon Sep 17 00:00:00 2001 From: Étienne Loks Date: Fri, 2 Oct 2020 11:57:31 +0200 Subject: Container: warning message about associated finds, containers on deletion --- .../ishtar/wizard/wizard_container_deletion.html | 58 ++++++++++++++++++++++ 1 file changed, 58 insertions(+) create mode 100644 archaeological_warehouse/templates/ishtar/wizard/wizard_container_deletion.html (limited to 'archaeological_warehouse/templates') diff --git a/archaeological_warehouse/templates/ishtar/wizard/wizard_container_deletion.html b/archaeological_warehouse/templates/ishtar/wizard/wizard_container_deletion.html new file mode 100644 index 000000000..ea11652af --- /dev/null +++ b/archaeological_warehouse/templates/ishtar/wizard/wizard_container_deletion.html @@ -0,0 +1,58 @@ +{% extends "ishtar/wizard/delete_wizard.html" %} +{% load i18n %} +{% block "detailed_related_info" %} + +{% if current_object.children.count %} +
+
+ {% trans "Associated containers" %} +
+
+
+
+ {% trans "Theses containers are inside this item. If you delete this item, they won't have any parent container. You probably want to fix that." %} +
+
+
    + {% for container in current_object.children.all %} +
  • {{container}}
  • {% endfor %} +
+
+
+{% endif %} +{% if current_object.finds.count or current_object.finds_ref.count %} +
+
+ {% trans "Associated finds" %} +
+
+ {% if current_object.finds.count %} +
+
+ {% trans "Theses finds are inside this item. If you delete this item, they won't be inside any container. You probably want to fix that." %} +
+
+
    + {% for find in current_object.finds.all %} +
  • {{find}}
  • {% endfor %} +
+ {% endif %} + {% if current_object.finds_ref.count %} +
+
+ {% trans "This item is the reference container for theses finds. If you delete this item, they won't have any reference container. You probably want to fix that." %} +
+
+
    + {% for find in current_object.finds_ref.all %} +
  • {{find}}
  • {% endfor %} +
+ {% endif %} +
+
+{% endif %} + +{% endblock %} -- cgit v1.2.3