2020-07-13 11:30:18 +00:00
|
|
|
from django.contrib.auth import get_user_model
|
|
|
|
from . import app_settings
|
|
|
|
|
|
|
|
|
|
|
|
User = get_user_model()
|
|
|
|
|
|
|
|
|
|
|
|
def get_user_queryset(queryset, view):
|
2020-07-13 13:08:46 +00:00
|
|
|
custom_func = app_settings.GET_USER_QUERYSET_FUNC
|
2020-07-13 11:30:18 +00:00
|
|
|
if custom_func is not None:
|
|
|
|
return custom_func(queryset, view)
|
|
|
|
return queryset
|