1
0
mirror of https://github.com/netbox-community/netbox.git synced 2024-05-10 07:54:54 +00:00

Miscellaneous RestrictedQuerySet cleanup

This commit is contained in:
Jeremy Stretch
2020-07-09 15:11:18 -04:00
parent 26e81546eb
commit 4f00b5af4a
8 changed files with 21 additions and 14 deletions

View File

@ -1729,7 +1729,7 @@ class Device(ChangeLoggedModel, ConfigContextModel, CustomFieldModel):
filter = Q(device=self)
if self.virtual_chassis and self.virtual_chassis.master == self:
filter |= Q(device__virtual_chassis=self.virtual_chassis, mgmt_only=False)
return Interface.objects.filter(filter)
return Interface.objects.unrestricted().filter(filter)
def get_cables(self, pk_list=False):
"""