Fixes #5059: Fix inclusion of checkboxes for interfaces in virtual machine view

This commit is contained in:
Jeremy Stretch 2020-08-27 09:22:53 -04:00
parent a0790e9119
commit f23900fc8c
2 changed files with 5 additions and 4 deletions

View File

@ -12,6 +12,7 @@
* [#5041](https://github.com/netbox-community/netbox/issues/5041) - Fix form tabs when assigning an IP to a VM interface
* [#5042](https://github.com/netbox-community/netbox/issues/5042) - Fix display of SLAAC label for IP addresses status
* [#5045](https://github.com/netbox-community/netbox/issues/5045) - Allow assignment of interfaces to non-master VC peer LAG during import
* [#5059](https://github.com/netbox-community/netbox/issues/5059) - Fix inclusion of checkboxes for interfaces in virtual machine view
---

View File

@ -2,7 +2,7 @@
<tr class="interface{% if not iface.enabled %} danger{% endif %}" id="interface_{{ iface.name }}">
{# Checkbox #}
{% if perms.virtualization.change_interface or perms.virtualization.delete_interface %}
{% if perms.virtualization.change_vminterface or perms.virtualization.delete_vminterface %}
<td class="pk">
<input name="pk" type="checkbox" value="{{ iface.pk }}" />
</td>
@ -48,12 +48,12 @@
<i class="glyphicon glyphicon-plus" aria-hidden="true"></i>
</a>
{% endif %}
{% if perms.virtualization.change_interface %}
{% if perms.virtualization.change_vminterface %}
<a href="{% url 'virtualization:vminterface_edit' pk=iface.pk %}?return_url={{ virtualmachine.get_absolute_url }}" class="btn btn-info btn-xs" title="Edit interface">
<i class="glyphicon glyphicon-pencil" aria-hidden="true"></i>
</a>
{% endif %}
{% if perms.virtualization.delete_interface %}
{% if perms.virtualization.delete_vminterface %}
<a href="{% url 'virtualization:vminterface_delete' pk=iface.pk %}?return_url={{ virtualmachine.get_absolute_url }}" class="btn btn-danger btn-xs" title="Delete interface">
<i class="glyphicon glyphicon-trash" aria-hidden="true"></i>
</a>
@ -65,7 +65,7 @@
{% if ipaddresses %}
<tr class="ipaddresses">
{# Placeholder #}
{% if perms.virtualization.change_interface or perms.virtualization.delete_interface %}
{% if perms.virtualization.change_vminterface or perms.virtualization.delete_vminterface %}
<td></td>
{% endif %}