{# macro file for printing forms #} {% macro quick_form(form, dest, autofocus=True) %}
{% for item in form if not item.label.text == "CSRF Token" %} {{ item.label }} {% if loop.first and autofocus %} {{ item(autofocus=True) }} {% else %} {{ item }} {% endif %} {% endfor %} {{ form.csrf_token }}
{% for field in form.errors %} {% for error in form.errors[field] %}

Error in the field {{ form[field].label.text }}! {{error}}

{% endfor %} {% endfor %} {% endmacro %}