{% extends "base.html" %} {% from "_macros.html" import cell, metric_card %} {% block content %}

{{ site.title }}

{{ site.index_subtitle }}

{% if metrics %}
{{ t("dashboard.cpu") }} {{ metrics.cpu_percent }}%
{{ t("dashboard.memory") }} {{ metrics.mem_percent }}% {{ t("dashboard.memory_usage", used=metrics.mem_used_gb, total=metrics.mem_total_gb) }}
{% if metrics.disk_percent is not none %}
{{ t("dashboard.disk") }} {{ metrics.disk_percent }}%
{% endif %}
{% endif %} {% if cards %}
{% for card in cards %} {{ metric_card(card) }} {% endfor %}
{% endif %} {% if activity_enabled %}

{{ t("dashboard.activity") }}

{% if activity %}
    {% for entry in activity %}
  1. {% if entry.action == "create" %}{{ t("detail.history.create") }}{% elif entry.action == "update" %}{{ t("detail.history.update") }}{% elif entry.action == "delete" %}{{ t("detail.history.delete") }}{% else %}{{ entry.action }}{% endif %} {{ entry.model }}{% if entry.url %} · {{ entry.label }}{% else %} · {{ t("dashboard.activity_gone") }}{% endif %} {{ cell(entry.at) }}{% if entry.actor %} · {{ entry.actor }}{% endif %}
  2. {% endfor %}
{% else %}

{{ t("dashboard.activity_empty") }}

{% endif %}
{% endif %} {% if models_view %}
{% for entry in models_view %}

{{ entry.admin.get_verbose_name_plural() }}

{% if entry.count is not none %}{% if entry.count_estimated %}{{ t("dashboard.count_estimated", count=entry.count | number) }}{% else %}{{ entry.count | number }}{% endif %}{% endif %}
{{ t("dashboard.browse") }} {% if entry.new_url %}{{ t("dashboard.new") }}{% endif %}
{% endfor %}
{% else %}

{{ t("dashboard.empty.lead") }} AdminModel {{ t("dashboard.empty.middle") }} AdminSite {{ t("dashboard.empty.tail") }}

{% endif %}
{% endblock %}