{% extends "base.html" %} {% block content %} {% set attribute_name = "bans" %} {% set reasons = ["all"] %} {% set terms = ["all"] %} {% for ban in bans %} {% if ban["reason"] not in reasons %} {% if reasons.append(ban["reason"]) %}{% endif %} {% endif %} {% if ban["term"] not in terms %} {% if terms.append(ban["term"]) %}{% endif %} {% endif %} {% endfor %}
No bans found
{% set infos = [ {"name" : "BANS TOTAL", "data" : bans|length|string}, {"name" : "TOP REASON", "data" : top_reason|string}, ] %} {% set is_info_hidden = True if bans|length == 0 else False %} {% include "card_info.html" %} {% set filters = [ { "type": "input", "name": "Search", "label": "search", "id": "keyword", "placeholder": "ip, ban start, ban end", "pattern": "(.*?)" }, { "type": "select", "name": "Reason", "id": "reason", "value": "all", "values": reasons }, { "type": "select", "name": "Range", "id": "term", "value": "all", "values": terms } ] %} {% set is_filter_hidden = True if bans|length == 0 else False %} {% include "card_filter.html" %} {% include "filter_nomatch.html" %}
BANS LIST
{% set bans_headers = [ { "name": "Select", "position": "col-span-1" }, { "name": "IP", "position": "col-span-2" }, { "name": "Reason", "position": "col-span-2" }, { "name": "Ban start", "position": "col-span-2" }, { "name": "Ban end", "position": "col-span-2" }, { "name": "Remain", "position": "col-span-3" }, { "name": "Term", "position": "hidden" } ] %}
{% for header in bans_headers %}

{{ header['name'] }}

{% endfor %}
    {% for ban in bans %}
  • {{ ban['ip'] }}

    {{ ban['reason'] }}

    {{ ban['ban_start'] }}

    {{ ban['ban_end'] }}

    {{ ban['remain'] }}

  • {% endfor %}
{% include "bans_modal.html" %} {% endblock content %}