Skip to content

Commit

Permalink
Backport fix issue #701
Browse files Browse the repository at this point in the history
  • Loading branch information
wlorenzetti committed Jan 3, 2024
1 parent 2dbbf1a commit 7853c95
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions g3w-admin/usersmanage/forms.py
Original file line number Diff line number Diff line change
Expand Up @@ -489,6 +489,11 @@ def __authrole_fields(self):
return fields

def filterFieldsByRoles(self, **kwargs):

# When a module that provides a new user backend (i.e. authldap module) is added to G3W-SUITE
# is necessary declare again the choices of 'backend' field
self.fields['backend'].choices = USER_BACKEND_TYPES

if self.request.user.is_superuser:
if not self.request.user.is_staff:
self.fields.pop('is_staff')
Expand Down

0 comments on commit 7853c95

Please sign in to comment.