add links to devices

This commit is contained in:
Cayo Puigdefabregas 2022-01-25 10:54:33 +01:00
parent 55ce612b2a
commit 01b355d955
2 changed files with 8 additions and 2 deletions

View file

@ -156,7 +156,7 @@
<li class="nav-heading">Utils</li> <li class="nav-heading">Utils</li>
<li class="nav-item"> <li class="nav-item">
<a class="nav-link " href="#TODO"> <a class="nav-link collapsed" href="{{ url_for('inventory.devices.taglist')}}">
<i class="bi bi-tags"></i> <i class="bi bi-tags"></i>
<span>Labels</span> <span>Labels</span>
</a> </a>

View file

@ -57,7 +57,13 @@
<td>{{ tag.id }}</td> <td>{{ tag.id }}</td>
<td>{% if tag.provider %}Unnamed tag {% else %}Named tag{% endif %}</td> <td>{% if tag.provider %}Unnamed tag {% else %}Named tag{% endif %}</td>
<td>{{ tag.get_provider }}</td> <td>{{ tag.get_provider }}</td>
<td>{% if tag.device %}{{ tag.device.type }} {{ tag.device.manufacturer }} {{ tag.device.model }}{% endif %}</td> <td>
{% if tag.device %}
<a href={{ url_for('inventory.devices.device_details', id=tag.device.devicehub_id)}}>
{{ tag.device.type }} {{ tag.device.manufacturer }} {{ tag.device.model }}
</a>
{% endif %}
</td>
</tr> </tr>
{% endfor %} {% endfor %}
</tbody> </tbody>