upload form now displays error messages once
This commit is contained in:
parent
80083caf99
commit
90f057288d
|
@ -15,15 +15,15 @@
|
||||||
<div class="alert alert-danger alert-icon alert-icon-border alert-dismissible" role="alert">
|
<div class="alert alert-danger alert-icon alert-icon-border alert-dismissible" role="alert">
|
||||||
<div class="icon"><span class="mdi mdi-close-circle-o"></span></div>
|
<div class="icon"><span class="mdi mdi-close-circle-o"></span></div>
|
||||||
<div class="message">
|
<div class="message">
|
||||||
{% for field, error in form.errors.items %}
|
{% for error in form.non_field_errors %}
|
||||||
{{ error }}<br />
|
{{ error }}<br />
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
<button class="btn-close" type="button" data-dismiss="alert" aria-label="Close"></button>
|
<button class="btn-close" type="button" data-dismiss="alert" aria-label="Close"></button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% bootstrap_form form %}
|
{% bootstrap_form form alert_error_type="fields" %}
|
||||||
<div class="form-actions-no-box">
|
<div class="form-actions-no-box">
|
||||||
<a class="btn btn-grey" href="{% url 'dashboard:unassigned_devices' %}">{% translate "Cancel" %}</a>
|
<a class="btn btn-grey" href="{% url 'dashboard:unassigned_devices' %}">{% translate "Cancel" %}</a>
|
||||||
<input class="btn btn-green-admin" type="submit" name="submit" value="{% translate 'Save' %}" />
|
<input class="btn btn-green-admin" type="submit" name="submit" value="{% translate 'Save' %}" />
|
||||||
</div>
|
</div>
|
||||||
|
|
Loading…
Reference in New Issue