{% extends "app_home/base.html" %}
{% load static %}
{% load i18n %}

{% block navbar_app %}
{% include 'app_home/_sidebar.html' %}
{% endblock %}

{% block title %}
<H2><i class="fa fa-archive"></i> {% translate 'ARCHIVE' %}</H2>
<hr>
{% endblock %}



{% block content %}

<table  id="table_managed_rev"  class="table table-striped table-hover small">
    <thead class="thead-dark">
        <tr>
            <th>{% translate 'Date' %}</th>
            <th class="text-center">{% translate 'Severity' %}</th>
            <th class="text-center">{% translate 'Category' %}</th>
            <th>{% translate 'Title' %}</th>
            <th class="text-center">{% translate 'Public Page' %}</th>
            <th class="text-center">{% translate 'Restricted' %}</th>
        </tr>
    </thead>

{% for page in pages %}
    <tr>
        <td class="py-1 px-1 mx-0">
        <a class="text-decoration-none" href="{% url 'app_sirene:detail' page.id %}">
        {{ page.created_at }}
        </a>
        </td>    

        <td class="py-1 text-center h6">
        <span class="badge text-bg-{{ page.bgcolor }} w-100">
            {{ page.severity }}</span>
        </td>

        <td class="py-1 px-1">{{ page.category }}</td>

        <td class="py-1 px-1">{{ page.displayname }}</td>

        <td class="py-1">{{ page.publicpage|default:'' }}</td>

        <td class="py-1">{{ page.is_restricted|yesno:"X,," }}</td>

    </tr>{% endfor %}
</table>

{% endblock %}


