aboutsummaryrefslogblamecommitdiffstats
path: root/templates/_formhelpers.html
blob: 3a89e096aa610a72c2424c7b7128893277937e33 (plain) (tree)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18

















                                       
{% macro render_field(field) %}
    <div class="row g-2">
      <div class="col-sm-3">
        {{ field.label }}
      </div>
      <div class="col-sm">
        {{ field(**kwargs)|safe }}
      </div>
    </div>
    
    {% if field.errors %}
        <ul class="errors">
        {% for error in field.errors %}
            <li>{{ error }}</li>
        {% endfor %}
        </ul>
    {% endif %}
{% endmacro %}