mirror of
https://github.com/jazzband/django-avatar.git
synced 2026-03-16 22:20:30 +00:00
fix admin detail too slow when there is large number of users (#219)
This commit is contained in:
parent
8034665e6b
commit
dfb2cb67e7
1 changed files with 1 additions and 0 deletions
|
|
@ -10,6 +10,7 @@ from avatar.utils import get_user_model
|
|||
class AvatarAdmin(admin.ModelAdmin):
|
||||
list_display = ("get_avatar", "user", "primary", "date_uploaded")
|
||||
list_filter = ("primary",)
|
||||
autocomplete_fields = ("user",)
|
||||
search_fields = (
|
||||
"user__%s" % getattr(get_user_model(), "USERNAME_FIELD", "username"),
|
||||
)
|
||||
|
|
|
|||
Loading…
Reference in a new issue