{% extends "apis_core/apis_entities/abstractentity.html" %}
{% load django_tables2 %}
{% load history %}
{% load generic %}

{% block navigation %}
  {% load core %}
  {% include "apis_entities/partials/entity_base_nav.html" with object=object.instance %}
{% endblock navigation %}

{% block col-zero %}
  <div class="card">
    {% template_list object "_card_table.html" as template_list %}
    <div class="card-body">{% include template_list %}</div>
  </div>
{% endblock col-zero %}

{% block col-one %}
  <div class="card">
    <div class="card-body">
      {% object_relations_history as object_relations %}
      {% for rel in object_relations %}
        {% if rel.1.data|length > 0 %}
          <h5>{{ rel.0|title }}</h5>
          <div id="tab_{{ rel.2 }}">{% render_table rel.1 %}</div>
        {% endif %}
      {% endfor %}
    </div>
  </div>
{% endblock col-one %}
