summaryrefslogtreecommitdiff
path: root/ishtar_common/templates/ishtar/wizard/confirm_wizard.html
blob: 1f0d0e4d92adb8603d2b939f762b706b90402a12 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
{% extends "base.html" %}
{% load ishtar_helpers i18n l10n range %}
{% block content %}
<h2>{{wizard_label}}</h2>

{% include "ishtar/blocks/wizard_breadcrumb.html" %}

<form  class='wizard-form' action="." method="post">{% csrf_token %}
<div class='form container'>
  {% block "warning_informations" %}{% endblock %}
  {% block "warning_message" %}
  <div class="alert alert-info">
    {% if confirm_msg %}{{confirm_msg|safe}}{%else%}{% trans "You have entered the following informations:" %}{%endif%}
  </div>
  {% endblock %}
  {% block "detailed_informations" %}
  {% 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 form-row">
      <table class='table'>
        {% for data in form_data %}
        <tr{% if data.2 %} class='{{data.2}}'{%endif%}><th>{{data.0}}</th><td>{% if data.1|is_numeric %}{{data.1|unlocalize}}{% else %}{{data.1}}{% endif %}</td></tr>
        {% endfor %}
      </table>

    </div>
  </div>

  {% endfor %}
  {% endblock "cards" %}
  {{wizard.management_form}}
  {% if not wizard.form.is_hidden %}
  <table>
    {{ wizard.form.as_table }}
   </table>
  {%endif%}
  <input type="hidden" name="{{ step_field }}" value="{{ step0 }}" />
  {{ previous_fields|safe }}
  {% if extra_form %}
  <table>
  {{ extra_form }}
  </table>
  {% endif %}
  {% endblock %}
  {% block "extra_informations" %}{% endblock %}

  {% block "footer" %}
  <div id="footer">
    {% block "validation_bar" %}
    <p class="confirm-message">{%if confirm_end_msg %}{{confirm_end_msg|safe}}{%else%}{% trans "Would you like to save them?" %}{%endif%}</p>
    {% include 'ishtar/wizard/validation_bar.html' %}
    {% endblock %}
    {% include 'ishtar/blocks/footer.html' %}
  </div>
  {% endblock %}

</div>
</form>
<script type="text/javascript">{% localize off %}
$(document).ready(function(){
    $(document).keydown(function(e){
      if (e.ctrlKey && e.keyCode == 13) {
        $("#submit_form").click();
      }
    });
});
{% endlocalize %}</script>
{% endblock %}