Add ordering to users list to prevent a warning from Django.

This commit is contained in:
Christopher Charbonneau Wells 2017-12-11 17:27:29 -05:00
parent 53a35f3f89
commit b34cc6aee8
1 changed files with 1 additions and 0 deletions

View File

@ -43,6 +43,7 @@ class RootRouter(LoginRequiredMixin, RedirectView):
class UserList(PermissionRequiredMixin, FilterView): class UserList(PermissionRequiredMixin, FilterView):
model = User model = User
template_name = 'babybuddy/user_list.html' template_name = 'babybuddy/user_list.html'
ordering = 'username'
permission_required = ('admin.add_user',) permission_required = ('admin.add_user',)
paginate_by = 10 paginate_by = 10
filter_fields = ('username', 'first_name', 'last_name', 'email') filter_fields = ('username', 'first_name', 'last_name', 'email')