Explorar el Código

Fixes #21651: Disable ordering on MACAddress is_primary column

is_primary is a cached_property, not a database field, so attempting
to order by it raises a FieldError.
Jason Novinger hace 1 día
padre
commit
10157394ae
Se han modificado 1 ficheros con 2 adiciones y 1 borrados
  1. 2 1
      netbox/dcim/tables/devices.py

+ 2 - 1
netbox/dcim/tables/devices.py

@@ -1205,7 +1205,8 @@ class MACAddressTable(PrimaryModelTable):
         verbose_name=_('Parent')
     )
     is_primary = columns.BooleanColumn(
-        verbose_name=_('Primary')
+        verbose_name=_('Primary'),
+        orderable=False,
     )
     tags = columns.TagColumn(
         url_name='dcim:macaddress_list'