confirmation step fixed

This commit is contained in:
Benni Bärmann 2021-02-04 12:59:23 +01:00
parent ab80f8c352
commit 82b137da5a
2 changed files with 8 additions and 9 deletions

View File

@ -32,7 +32,7 @@
</h1> </h1>
<h2> <h2>
<p>Schritt {{ wizard.steps.step1 }} von {{ wizard.steps.count }}</p> <p>Schritt {{ wizard.steps.step1 }} von {{ wizard.steps.count }}</p>
Choice: {{choice}} Choice: {{choice}} Datatable: {{datatable}}
<p>{% if wizard.steps.step1 == 1 %} <p>{% if wizard.steps.step1 == 1 %}
Angaben zur Person {% endif %} Angaben zur Person {% endif %}
{% if choice == 'IN' %} {% if choice == 'IN' %}
@ -42,20 +42,18 @@
IT-relevante Angaben IT-relevante Angaben
{% elif wizard.steps.step1 == 4 %} {% elif wizard.steps.step1 == 4 %}
Office-relevante Angaben Office-relevante Angaben
{% elif wizards.steps.step1 == 5 %}
Bestätigungsschritt
{% endif %} {% endif %}
{% else %} {% else %}
{% if wizard.steps.step1 == 2 %} {% if wizard.steps.step1 == 2 %}
Veränderungsrelevante Angaben Veränderungsrelevante Angaben
{% elif wizards.steps.step1 == 3 %}
Bestätigungsschritt
{% endif %} {% endif %}
{% endif %}
{% if datatable == True %}
Bestätigungsschritt
{% endif %} {% endif %}
</p> </p>
</h2> </h2>
{% if wizard.steps.step1 == 3 and choice == 'CHANGE' or wizards.steps.step1 == 6 %} {% if datatable == True %}
{% for key, value in data.items %} {% for key, value in data.items %}
{{ key }}: {{ value }}<p> {{ key }}: {{ value }}<p>
{% endfor %} {% endfor %}

View File

@ -66,8 +66,9 @@ class EvaFormView(CookieWizardView):
#print('GETCONTEXT') #print('GETCONTEXT')
context = super().get_context_data(form=form, **kwargs) context = super().get_context_data(form=form, **kwargs)
context.update({'choice': self.choice}) context.update({'choice': self.choice})
if (self.steps.current == 5 or (self.choice == 'CHANGE' and self.steps.current ==3)): if (self.steps.step1 == 5 or (self.choice != 'IN' and self.steps.step1 == 3)):
context.update({'data': self.beautify_data(self.get_all_cleaned_data())}) context.update({'data': self.beautify_data(self.get_all_cleaned_data()),
'datatable': True,})
return context return context
def get_form_instance(self,step): def get_form_instance(self,step):