Closes #5411: Include cable tags in trace view

This commit is contained in:
Jeremy Stretch 2020-12-04 15:56:33 -05:00
parent f7e61cc153
commit 2c7fc5df75
2 changed files with 14 additions and 6 deletions

View File

@ -2,6 +2,10 @@
## v2.10-beta3 (FUTURE)
### Enhancements
* [#5411](https://github.com/netbox-community/netbox/issues/5411) - Include cable tags in trace view
### Bug Fixes
* [#5417](https://github.com/netbox-community/netbox/issues/5417) - Fix exception when viewing a device installed within a device bay

View File

@ -1,3 +1,5 @@
{% load helpers %}
<div class="cable" style="border-left-color: #{{ cable.color|default:'606060' }}; {% if cable.status != 'connected' %} border-left-style: dashed{% endif %}">
<strong>
<a href="{% url 'dcim:cable' pk=cable.pk %}">
@ -5,11 +7,13 @@
</a>
</strong><br />
{% if cable.type %}
{{ cable.get_type_display|default:"" }}
{% if cable.length %}
({{ cable.length }} {{ cable.get_length_unit_display }})
{% endif %}
<br />
{{ cable.get_type_display|default:"" }}<br />
{% endif %}
<span class="label label-{{ cable.get_status_class }}">{{ cable.get_status_display }}</span>
{% if cable.length %}
({{ cable.length }} {{ cable.get_length_unit_display }})<br />
{% endif %}
<span class="label label-{{ cable.get_status_class }}">{{ cable.get_status_display }}</span><br />
{% for tag in cable.tags.all %}
{% tag tag 'dcim:cable_list' %}
{% endfor %}
</div>