{% extends 'generic/object_edit.html' %}
{% load form_helpers %}

{% block form %}
  <div class="field-group my-5">
    <div class="row mb-2">
      <h5 class="offset-sm-3">FHRP Group</h5>
    </div>
    {% render_field form.protocol %}
    {% render_field form.group_id %}
    {% render_field form.description %}
    {% render_field form.tags %}
  </div>

  <div class="field-group my-5">
    <div class="row mb-2">
      <h5 class="offset-sm-3">Authentication</h5>
    </div>
    {% render_field form.auth_type %}
    {% render_field form.auth_key %}
  </div>

  {% if not form.instance.pk %}
    <div class="field-group my-5">
      <div class="row mb-2">
        <h5 class="offset-sm-3">Virtual IP Address</h5>
      </div>
      {% render_field form.ip_vrf %}
      {% render_field form.ip_address %}
      {% render_field form.ip_status %}
    </div>
  {% endif %}

  {% if form.custom_fields %}
    <div class="row mb-2">
      <h5 class="offset-sm-3">Custom Fields</h5>
    </div>
    {% render_custom_fields form %}
  {% endif %}
{% endblock %}
