mirror of
https://github.com/netbox-community/netbox.git
synced 2026-04-27 19:27:33 +02:00
Use badge template tag for numeric values
This commit is contained in:
@@ -18,7 +18,7 @@
|
||||
{% if perms.ipam.view_ipaddress %}
|
||||
<li role="presentation" class="nav-item">
|
||||
<a class="nav-link{% if active_tab == 'ip-addresses' %} active{% endif %}" href="{% url 'ipam:iprange_ipaddresses' pk=object.pk %}">
|
||||
IP Addresses <span class="badge bg-primary">{{ object.get_child_ips.count }}</span>
|
||||
IP Addresses {% badge object.get_child_ips.count %}
|
||||
</a>
|
||||
</li>
|
||||
{% endif %}
|
||||
|
||||
@@ -20,10 +20,10 @@
|
||||
<a class="nav-link{% if not active_tab %} active{% endif %}" href="{% url 'ipam:vlan' pk=object.pk %}">VLAN</a>
|
||||
</li>
|
||||
<li class="nav-item" role="presentation">
|
||||
<a class="nav-link{% if active_tab == 'interfaces' %} active{% endif %}" href="{% url 'ipam:vlan_interfaces' pk=object.pk %}">Device Interfaces <span class="badge bg-primary">{{ object.get_interfaces.count }}</span></a>
|
||||
<a class="nav-link{% if active_tab == 'interfaces' %} active{% endif %}" href="{% url 'ipam:vlan_interfaces' pk=object.pk %}">Device Interfaces {% badge object.get_interfaces.count %}</a>
|
||||
</li>
|
||||
<li class="nav-item" role="presentation">
|
||||
<a class="nav-link{% if active_tab == 'vminterfaces' %} active{% endif %}" href="{% url 'ipam:vlan_vminterfaces' pk=object.pk %}">VM Interfaces <span class="badge bg-primary">{{ object.get_vminterfaces.count }}</span></a>
|
||||
<a class="nav-link{% if active_tab == 'vminterfaces' %} active{% endif %}" href="{% url 'ipam:vlan_vminterfaces' pk=object.pk %}">VM Interfaces {% badge object.get_vminterfaces.count %}</a>
|
||||
</li>
|
||||
{% if perms.extras.view_journalentry %}
|
||||
<li class="nav-item" role="presentation">
|
||||
|
||||
Reference in New Issue
Block a user