mirror of
https://github.com/netbox-community/netbox.git
synced 2025-12-09 09:59:37 -06:00
fix(users): Disable sorting on Permission flag columns
Mark `can_view`, `can_add`, `can_change`, and `can_delete` columns in the Permissions list as `orderable=False`. Sorting by these computed flags persisted an invalid sort key which triggers a `FieldError` when loading `/users/permissions/`. Fixes #20655
This commit is contained in:
parent
aa4571b61f
commit
77307b3c91
@ -84,15 +84,19 @@ class ObjectPermissionTable(NetBoxTable):
|
||||
)
|
||||
can_view = columns.BooleanColumn(
|
||||
verbose_name=_('Can View'),
|
||||
orderable=False,
|
||||
)
|
||||
can_add = columns.BooleanColumn(
|
||||
verbose_name=_('Can Add'),
|
||||
orderable=False,
|
||||
)
|
||||
can_change = columns.BooleanColumn(
|
||||
verbose_name=_('Can Change'),
|
||||
orderable=False,
|
||||
)
|
||||
can_delete = columns.BooleanColumn(
|
||||
verbose_name=_('Can Delete'),
|
||||
orderable=False,
|
||||
)
|
||||
custom_actions = columns.ArrayColumn(
|
||||
verbose_name=_('Custom Actions'),
|
||||
|
||||
Loading…
Reference in New Issue
Block a user