From ab191a5873011db4b44adf6d4e532681c29b4cb3 Mon Sep 17 00:00:00 2001 From: Étienne Loks Date: Fri, 18 Dec 2015 18:46:44 +0100 Subject: Operation wizard: improve relations layout (form and summary) --- ishtar_common/templates/blocks/inline_formset.html | 2 +- .../templates/ishtar/wizard/relations_wizard.html | 32 ++++++++++++++++++++++ 2 files changed, 33 insertions(+), 1 deletion(-) create mode 100644 ishtar_common/templates/ishtar/wizard/relations_wizard.html (limited to 'ishtar_common/templates') diff --git a/ishtar_common/templates/blocks/inline_formset.html b/ishtar_common/templates/blocks/inline_formset.html index 3affb7bf3..4d4042985 100644 --- a/ishtar_common/templates/blocks/inline_formset.html +++ b/ishtar_common/templates/blocks/inline_formset.html @@ -12,7 +12,7 @@ {% if frm.errors %}{% endif %} {% endif %}{% for field in frm.visible_fields %} {% if field.errors %}
{{ field.errors.as_ul }}
{% endif %} - {{ field }} + {{ field|safe }} {# Include the hidden fields in the form #} {% if forloop.first %} {{ formset.management_form }} diff --git a/ishtar_common/templates/ishtar/wizard/relations_wizard.html b/ishtar_common/templates/ishtar/wizard/relations_wizard.html new file mode 100644 index 000000000..9ca592ca8 --- /dev/null +++ b/ishtar_common/templates/ishtar/wizard/relations_wizard.html @@ -0,0 +1,32 @@ +{% extends "ishtar/wizard/default_wizard.html" %} +{% load i18n range inline_formset %} +{% block extra_head %} +{{wizard.form.media}} +{% endblock %} +{% block wizard_form %} +
{% csrf_token %} +
+{{ wizard.form.media }} +{{ wizard.management_form }} +{{ wizard.form.management_form }} + +{% if wizard.form.non_form_errors%} + + +
{{wizard.form.non_form_errors}}
{%endif%} + + + {% for field in wizard.form.forms.0 %}{{ field.label_tag }}{% endfor %} + + {% inline_formset 'Parcels' wizard.form.forms False %} +
({% trans "all"%} )
+

+ +{{ previous_fields|safe }} +{% block "validation_bar" %} +{% include 'ishtar/wizard/validation_bar.html' %} +{% endblock %} +
+
+{% endblock %} + -- cgit v1.2.3