<div class="{{ form_class }}">
    <div class="card">
        <div class="card-header">
            <h3 class="card-title">{{ form_title }}</h3>
        </div>
        <div class="card-body">
            <form class="row" method="POST">
                {% csrf_token %}
                {% for field in form %}
                <div class="col-12{% if field.errors %} has-error{% endif %}">
                    {{ field.label_tag }} 
                    {{ field }}
                    {% if field.help_text %}
                    <span class="badge bg-secondary mb-2">{{ field.help_text|safe }}</span>
                    {% endif %}
                    {{ field.errors }}
                </div>
                {% endfor %}
                <div class="col-12">
                    <input name="op" type="submit" value="{{ form_submit }}" class="btn btn-primary"/>
                </div>
            </form>
        </div>
    </div>
</div>