{% if form.non_field_errors %}
    <div class="alert alert-error">
        <ul>
            {% for non_field_error in form.non_field_errors %}
            <li>{{ non_field_error }}</li>
            {% endfor %}
        </ul>
    </div>
{% endif %}

{% for field in form.hidden_fields %}
    {{ field }}
{% endfor %}

{% for field in form.visible_fields %}
    {% include field_template %}
{% endfor %}
