52 lines
2 KiB
Django/Jinja
52 lines
2 KiB
Django/Jinja
{% extends "base.html.j2" %}
|
|
{% from "tables.html.j2" import alarms_table, automations_table, bridgeconfs_table, bridges_table, cloud_accounts_table,
|
|
countries_table,
|
|
eotk_table, groups_table, instances_table, mirrorlists_table, origins_table, origin_onion_table, onions_table,
|
|
pools_table, proxies_table, static_table, webhook_table %}
|
|
|
|
{% block content %}
|
|
<h1 class="h2 mt-3">{{ title }}</h1>
|
|
{% if new_link %}
|
|
<a href="{{ new_link }}" class="btn btn-success">Create new {{ item }}</a>
|
|
{% for extra_button in extra_buttons %}
|
|
<a href="{{ extra_button.link }}" class="btn btn-{{ extra_button.style }}">{{ extra_button.text }}</a>
|
|
{% endfor %}
|
|
{% endif %}
|
|
{% if section == "alarm" %}
|
|
{{ alarms_table(items) }}
|
|
{% elif item == "automation" %}
|
|
{{ automations_table(items, states) }}
|
|
{% elif item == "bridge configuration" %}
|
|
{{ bridgeconfs_table(items) }}
|
|
{% elif item == "bridge" %}
|
|
{{ bridges_table(items) }}
|
|
{% elif item == "cloud account" %}
|
|
{{ cloud_accounts_table(items) }}
|
|
{% elif item == "country" %}
|
|
{{ countries_table(items) }}
|
|
{% elif item == "eotk" %}
|
|
{{ eotk_table(items) }}
|
|
{% elif item == "group" %}
|
|
{{ groups_table(items) }}
|
|
{% elif item == "distribution list" %}
|
|
{{ mirrorlists_table(items) }}
|
|
{% elif item == "onion service" %}
|
|
{% if section == "onion" %}
|
|
{{ onions_table(items) }}
|
|
{% elif section == "origin" %}
|
|
{{ origin_onion_table(items) }}
|
|
{% endif %}
|
|
{% elif item == "origin" %}
|
|
{{ origins_table(items) }}
|
|
{% elif item == "static" %}
|
|
{{ static_table(items) }}
|
|
{% elif item == "pool" %}
|
|
{{ pools_table(items) }}
|
|
{% elif item == "proxy" %}
|
|
{{ proxies_table(items) }}
|
|
{% elif item == "smart proxy" %}
|
|
{{ instances_table("smart_proxy", items) }}
|
|
{% elif item == "webhook" %}
|
|
{{ webhook_table(items) }}
|
|
{% endif %}
|
|
{% endblock %}
|