Handle login and billing address forms together in PaymentOrderView

This commit is contained in:
M.Ravi 2017-10-08 13:50:43 +02:00
commit 564f47cf8a
2 changed files with 56 additions and 26 deletions

View file

@ -30,7 +30,7 @@
{% csrf_token %}
{% bootstrap_field field show_label=False type='fields'%}
{% endfor %}
<p class="red">{{login_form.non_field_errors|striptags}}</p>
<p class="text-danger">{{login_form.non_field_errors|striptags}}</p>
<input type='hidden' name='next' value='{{request.path}}'/>
<div class="form-group text-right">
<button type="submit" class="btn btn-wide btn-vm-contact" name="login_form">{% trans "LOGIN" %}</button>
@ -59,7 +59,7 @@
{% endfor %}
<form role="form" id="billing-form" method="post" action="" novalidate>
{% csrf_token %}
{% for field in form %}
{% for field in billing_address_form %}
{% bootstrap_field field show_label=False type='fields'%}
{% endfor %}
</form>
@ -164,12 +164,13 @@
</p>
{% endif %}
{% endfor %}
{% comment %}
{% for error in form.non_field_errors %}
<p class="card-warning-content card-warning-error">
{{ error|escape }}
</p>
{% endfor %}
{% endcomment %}
</div>
<div class="text-right">
<button class="btn btn-vm-contact btn-wide" type="submit">{%trans "SUBMIT" %}</button>