limits vlans on interface tables

This commit is contained in:
Thor Dreier-Hansen 2024-10-02 11:19:22 +02:00
parent 23f94839ad
commit 9495964987
3 changed files with 6 additions and 2 deletions

View File

@ -56,9 +56,13 @@ INTERFACE_FHRPGROUPS = """
INTERFACE_TAGGED_VLANS = """
{% if record.mode == 'tagged' %}
{% if value.count > 3 %}
<a href="{{ record.get_absolute_url }}#vlans">{{ value.count }}</a>
{% else %}
{% for vlan in value.all %}
<a href="{{ vlan.get_absolute_url }}">{{ vlan }}</a><br />
{% endfor %}
{% endif %}
{% elif record.mode == 'tagged-all' %}
All
{% endif %}

View File

@ -351,7 +351,7 @@
</div>
</div>
<div class="row mb-3">
<div class="col col-md-12">
<div class="col col-md-12" id="vlans">
{% include 'inc/panel_table.html' with table=vlan_table heading="VLANs" %}
</div>
</div>

View File

@ -96,7 +96,7 @@
</div>
</div>
<div class="row mb-3">
<div class="col col-md-12">
<div class="col col-md-12" id="vlans">
{% include 'inc/panel_table.html' with table=vlan_table heading="VLANs" %}
</div>
</div>