{% extends 'virtualization/cluster/base.html' %}
{% load helpers %}
{% load plugins %}

{% block content %}
<div class="row">
  <div class="col col-md-6">
    <div class="card">
        <h5 class="card-header">
            Cluster
        </h5>
        <div class="card-body">
            <table class="table table-hover attr-table">
                <tr>
                    <th scope="row">Name</th>
                    <td>{{ object.name }}</td>
                </tr>
                <tr>
                    <th scope="row">Type</th>
                    <td>{{ object.type|linkify }}</td>
                </tr>
                <tr>
                    <th scope="row">Group</th>
                    <td>{{ object.group|linkify }}</td>
                </tr>
                <tr>
                    <th scope="row">Tenant</th>
                    <td>
                        {% if object.tenant.group %}
                            {{ object.tenant.group|linkify }} /
                        {% endif %}
                        {{ object.tenant|linkify|placeholder }}
                    </td>
                </tr>
                <tr>
                    <th scope="row">Site</th>
                    <td>{{ object.site|linkify }}</td>
                </tr>
                <tr>
                    <th scope="row">Virtual Machines</th>
                    <td><a href="{% url 'virtualization:virtualmachine_list' %}?cluster_id={{ object.pk }}">{{ object.virtual_machines.count }}</a></td>
                </tr>
            </table>
        </div>
    </div>
    {% include 'inc/panels/comments.html' %}
    {% plugin_left_page object %}
  </div>
  <div class="col col-md-6">
    {% include 'inc/panels/custom_fields.html' %}
    {% include 'inc/panels/tags.html' %}
    {% include 'inc/panels/contacts.html' %}
    {% plugin_right_page object %}
  </div>
</div>
<div class="row">
  <div class="col col-md-12">
    {% plugin_full_width_page object %}
  </div>
</div>
{% endblock %}
