From 60cf509da831a2e81e2631ffc1150f81ed96fe4c Mon Sep 17 00:00:00 2001 From: qw3rty Date: Thu, 1 Jul 2010 15:09:23 +0000 Subject: [PATCH] reversed the search order of the revisions drop down menu. git-svn-id: http://svn.osqa.net/svnroot/osqa/trunk@481 0cfe37f9-358a-4d5e-be75-b63607b5c754 --- forum/forms/qanda.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/forum/forms/qanda.py b/forum/forms/qanda.py index d54eabb..39f9ca7 100644 --- a/forum/forms/qanda.py +++ b/forum/forms/qanda.py @@ -182,8 +182,8 @@ class RevisionForm(forms.Form): def __init__(self, post, *args, **kwargs): super(RevisionForm, self).__init__(*args, **kwargs) - revisions = post.revisions.all().values_list( - 'revision', 'author__username', 'revised_at', 'summary') + revisions = post.revisions.all().values_list('revision', 'author__username', 'revised_at', 'summary').order_by('-revised_at') + date_format = '%c' self.fields['revision'].choices = [ (r[0], u'%s - %s (%s) %s' % (r[0], r[1], r[2].strftime(date_format), r[3])) -- 2.39.5