summaryrefslogtreecommitdiffstats
path: root/todolists/views.py
diff options
context:
space:
mode:
authorDan McGee <dan@archlinux.org>2013-01-22 23:47:43 +0100
committerDan McGee <dan@archlinux.org>2013-01-22 23:47:43 +0100
commite9e1c071654edd7b95e20c8105abbc23f426cecc (patch)
tree3becfd32ef3535d15504d98fff68969787634a0e /todolists/views.py
parent53484c45ea82a5afa8bf167f978f657b866d4c93 (diff)
downloadarchweb-e9e1c071654edd7b95e20c8105abbc23f426cecc.tar.gz
archweb-e9e1c071654edd7b95e20c8105abbc23f426cecc.tar.xz
Show staging version on todolist view page
If one exists, it is easy enough to show it here so in-progress todolists can easily be cross-checked with the current state of the repository. Signed-off-by: Dan McGee <dan@archlinux.org>
Diffstat (limited to 'todolists/views.py')
-rw-r--r--todolists/views.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/todolists/views.py b/todolists/views.py
index fcf62e2..f333728 100644
--- a/todolists/views.py
+++ b/todolists/views.py
@@ -16,7 +16,7 @@ from main.models import Package, Repo
from main.utils import find_unique_slug
from packages.utils import attach_maintainers
from .models import Todolist, TodolistPackage
-from .utils import get_annotated_todolists
+from .utils import get_annotated_todolists, attach_staging
class TodoListForm(forms.ModelForm):
@@ -69,6 +69,7 @@ def view(request, slug):
# we don't hold onto the result, but the objects are the same here,
# so accessing maintainers in the template is now cheap
attach_maintainers(todolist.packages())
+ attach_staging(todolist.packages(), todolist.pk)
arches = {tp.arch for tp in todolist.packages()}
repos = {tp.repo for tp in todolist.packages()}
return render(request, 'todolists/view.html', {