]> git.openstreetmap.org Git - osqa.git/blobdiff - forum/views/readers.py
OSQA-375
[osqa.git] / forum / views / readers.py
index 134fff24fb5e09e21991efbb95f51ddb730c641b..07f6a3f2de3f5c44940939dbe4a11af1610c3637 100644 (file)
@@ -340,11 +340,10 @@ REVISION_TEMPLATE = template.loader.get_template('node/revision.html')
 def revisions(request, id):
     post = get_object_or_404(Node, id=id).leaf
     revisions = list(post.revisions.order_by('revised_at'))
-
     rev_ctx = []
 
     for i, revision in enumerate(revisions):
-        rev_ctx.append(dict(inst=revision, html=REVISION_TEMPLATE.render(template.Context({
+        rev_ctx.append(dict(inst=revision, html=template.loader.get_template('node/revision.html').render(template.Context({
         'title': revision.title,
         'html': revision.html,
         'tags': revision.tagname_list(),
@@ -360,6 +359,8 @@ def revisions(request, id):
         else:
             rev_ctx[i]['summary'] = revision.summary
 
+    rev_ctx.reverse()
+
     return render_to_response('revisions.html', {
     'post': post,
     'revisions': rev_ctx,