Add support for custom user filtering.

This commit is contained in:
Tom Hacohen
2020-07-13 14:30:18 +03:00
parent 3680bd53b1
commit f9add36f18
4 changed files with 38 additions and 8 deletions

View File

@@ -46,6 +46,13 @@ class AppSettings:
ret.append(self.import_from_str(perm))
return ret
@property
def GET_USER_QUERYSET(self): # pylint: disable=invalid-name
get_user_queryset = self._setting("GET_USER_QUERYSET", None)
if get_user_queryset is not None:
return self.import_from_str(get_user_queryset)
return None
@property
def CHALLENGE_VALID_SECONDS(self): # pylint: disable=invalid-name
return self._setting("CHALLENGE_VALID_SECONDS", 60)