Fixes #5639: Fix filtering connection lists by device name
This commit is contained in:
parent
a0e82e1817
commit
3c9be8cd08
|
|
@ -13,6 +13,7 @@
|
|||
* [#5574](https://github.com/netbox-community/netbox/issues/5574) - Restrict the creation of device bay templates on non-parent device types
|
||||
* [#5584](https://github.com/netbox-community/netbox/issues/5584) - Restore power utilization panel under device view
|
||||
* [#5597](https://github.com/netbox-community/netbox/issues/5597) - Fix ordering devices by primary IP address
|
||||
* [#5639](https://github.com/netbox-community/netbox/issues/5639) - Fix filtering connection lists by device name
|
||||
|
||||
---
|
||||
|
||||
|
|
|
|||
|
|
@ -1152,7 +1152,7 @@ class ConnectionFilterSet:
|
|||
def filter_device(self, queryset, name, value):
|
||||
if not value:
|
||||
return queryset
|
||||
return queryset.filter(device_id__in=value)
|
||||
return queryset.filter(**{f'{name}__in': value})
|
||||
|
||||
|
||||
class ConsoleConnectionFilterSet(ConnectionFilterSet, BaseFilterSet):
|
||||
|
|
|
|||
Loading…
Reference in New Issue