{% extends 'generic/object.html' %}
{% load render_table from django_tables2 %}

{% block content %}
  <div class="row mb-3">
    <div class="col col-md-6">
      <div class="card">
        <h5 class="card-header">RPKI Customer Certificate</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">Issuer</th>
              <td>{{ object.issuer }}</td>
            </tr>
            <tr>
              <th scope="row">Subject</th>
              <td>{{ object.subject }}</td>
            </tr>
            <tr>
              <th scope="row">Serial</th>
              <td>{{ object.serial }}</td>
            </tr>
            <tr>
              <th scope="row">Valid From</th>
              <td>{{ object.valid_from }}</td>
            </tr>
            <tr>
              <th scope="row">Valid To</th>
              <td>{{ object.valid_to }}</td>
            </tr>
            <tr>
              <th scope="row">Auto-renews?</th>
              <td>{{ object.auto_renews }}</td>
            </tr>
            <tr>
              <th scope="row">Public Key</th>
              <td>{{ object.public_key }}</td>
            </tr>
            <tr>
              <th scope="row">Private Key</th>
              <td>{{ object.private_key }}</td>
            </tr>
            <tr>
              <th scope="row">Publication URL</th>
              <td>{{ object.publication_url }}</td>
            </tr>
            <tr>
              <th scope="row">CA Repository</th>
              <td>{{ object.ca_repository }}</td>
            </tr>
            <tr>
              <th scope="row">Self Hosted</th>
              <td>{{ object.self_hosted }}</td>
            </tr>
            <tr>
              <th scope="row">Parent RPKI customer/org</th>
              <td><a href="{{ object.rpki_org.get_absolute_url }}">{{ object.rpki_org }}</a></td>
            </tr>            
          </table>
        </div>
      </div>
      {% include 'inc/panels/custom_fields.html' %}
    </div>
    <div class="col col-md-6">
      {% include 'inc/panels/tags.html' %}
      {% include 'inc/panels/comments.html' %}
    </div>
  </div>

  <div class="row">
    <div class="col col-md-12">
      <div class="card">
        <h5 class="card-header">ROAs</h5>
        <div class="card-body table-responsive">
          {% render_table signed_roas_table %}
        </div>
      </div>
    </div>
  </div>


{% endblock content %}
