{% load form_helpers %}

{% for group, fields in form.custom_field_groups.items %}
  {% if group %}
  <div class="row">
    <h3 class="col-9 offset-3 mb-3 h4">{{ group }}</h3>
  </div>
  {% endif %}
  {% for name in fields %}
    {% if name in form.nullable_fields %}
      {% render_field form|getfield:name bulk_nullable=True %}
    {% else %}
      {% render_field form|getfield:name %}
    {% endif %}
  {% endfor %}
{% endfor %}
