fix user view

This commit is contained in:
Laura Klünder 2017-07-04 22:53:10 +02:00
parent 0a6e2797c4
commit f53f20ef9a

View file

@ -1,5 +1,4 @@
from django.contrib.auth.models import User
from django.db.models import Max
from django.shortcuts import get_object_or_404, render
from c3nav.editor.models import ChangeSet
@ -13,7 +12,6 @@ def user_detail(request, pk):
user = get_object_or_404(User, pk=pk)
qs = ChangeSet.objects.filter(author=user)
qs = qs.annotate(last_change_cache=Max('changed_objects_set__last_update')).order_by('-last_change_cache')
ctx = {
'user': user,