summaryrefslogtreecommitdiff
path: root/ishtar_common/templates
diff options
context:
space:
mode:
authorÉtienne Loks <etienne.loks@iggdrasil.net>2019-09-13 18:37:06 +0200
committerÉtienne Loks <etienne.loks@iggdrasil.net>2019-09-13 18:37:29 +0200
commita2d4d2cf2561c4dfe926ab03f4dbcfb3409310c7 (patch)
tree81714ce5e159dcdd06faed1b44b2fa4ccdf22e1a /ishtar_common/templates
parentbbde20e66cf624a7919050548cbfa8248173c49f (diff)
downloadIshtar-a2d4d2cf2561c4dfe926ab03f4dbcfb3409310c7.tar.bz2
Ishtar-a2d4d2cf2561c4dfe926ab03f4dbcfb3409310c7.zip
Muliple person deletion wizard
Diffstat (limited to 'ishtar_common/templates')
-rw-r--r--ishtar_common/templates/ishtar/wizard/confirm_wizard.html3
-rw-r--r--ishtar_common/templates/ishtar/wizard/delete_wizard.html42
-rw-r--r--ishtar_common/templates/ishtar/wizard/wizard_person_deletion.html4
3 files changed, 46 insertions, 3 deletions
diff --git a/ishtar_common/templates/ishtar/wizard/confirm_wizard.html b/ishtar_common/templates/ishtar/wizard/confirm_wizard.html
index e78a2f4a6..56887d28b 100644
--- a/ishtar_common/templates/ishtar/wizard/confirm_wizard.html
+++ b/ishtar_common/templates/ishtar/wizard/confirm_wizard.html
@@ -15,6 +15,7 @@
</div>
{% endblock %}
{% block "detailed_informations" %}
+ {% block "cards" %}
{% for form_label, form_data in datas %}
<div class="card">
@@ -32,8 +33,8 @@
</div>
</div>
-
{% endfor %}
+ {% endblock "cards" %}
{{wizard.management_form}}
{% if not wizard.form.is_hidden %}
<table>
diff --git a/ishtar_common/templates/ishtar/wizard/delete_wizard.html b/ishtar_common/templates/ishtar/wizard/delete_wizard.html
new file mode 100644
index 000000000..82e074eae
--- /dev/null
+++ b/ishtar_common/templates/ishtar/wizard/delete_wizard.html
@@ -0,0 +1,42 @@
+{% extends "ishtar/wizard/confirm_wizard.html" %}
+{% load i18n %}
+{% load range %}
+{% block "warning_message" %}
+<div class="alert alert-danger">
+ <p><i class="fa fa-exclamation-triangle" aria-hidden="true"></i>
+ {% if current_objs and current_objs.1 %}
+ {% trans "Are you sure to want to delete theses items?" %}
+ <ul>{% for obj in current_objs %}
+ <li>{{obj}}</li>
+ {% endfor %}</ul>
+ {% else %}
+ {% trans "Are you sure to want to delete this item?" %}{% endif %}
+ </p>
+ <p>{% trans "No rollback is possible. Be careful to scroll to the end of page to check every piece of information." %}</p>
+</div>
+{% endblock %}
+
+{% block "cards" %}
+{% for form_label, form_data in datas %}
+
+<div class="card">
+ {% if form_label %}
+ <div class="card-header">
+ {{form_label}}
+ </div>{% endif %}
+ <div class="card-body">
+ {% if current_objs and current_objs.1 %}{% for current_object in current_objs %}{% if forloop.counter == forloop.parentloop.counter %}
+ {% block "detailled_extra_info" %}
+ {% endblock %}
+ {% endif %}{% endfor %}{% endif %}
+ <table class='table'>
+ {% for data in form_data %}
+ <tr{% if data.2 %} class='{{data.2}}'{%endif%}><th>{{data.0}}</th><td>{{data.1}}</td></tr>
+ {% endfor %}
+ </table>
+
+ </div>
+</div>
+
+{% endfor %}
+{% endblock "cards" %}
diff --git a/ishtar_common/templates/ishtar/wizard/wizard_person_deletion.html b/ishtar_common/templates/ishtar/wizard/wizard_person_deletion.html
index 6d1f06bd1..27595286b 100644
--- a/ishtar_common/templates/ishtar/wizard/wizard_person_deletion.html
+++ b/ishtar_common/templates/ishtar/wizard/wizard_person_deletion.html
@@ -1,6 +1,6 @@
-{% extends "ishtar/wizard/confirm_wizard.html" %}
+{% extends "ishtar/wizard/delete_wizard.html" %}
{% load i18n %}
-{% block "extra_informations" %}
+{% block "detailled_extra_info" %}
{% if current_object.file_responsability.count %}
<h3>{% trans "In charge of archaeological files" %}</h3>