Merge branch 'master' of github.com:Gluejar/regluit into tastypie1
commit
5deea69e6d
|
@ -2,9 +2,9 @@
|
||||||
|
|
||||||
{% block content %}
|
{% block content %}
|
||||||
|
|
||||||
<h1>Wishlist for {{ user.username }}</h1>
|
<h1>Wishlist for {{ supporter.username }}</h1>
|
||||||
|
|
||||||
{% for work in user.wishlist.works.all %}
|
{% for work in supporter.wishlist.works.all %}
|
||||||
{% include "book_panel.html" %}
|
{% include "book_panel.html" %}
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
|
|
|
@ -3,5 +3,5 @@ from django.conf.urls.defaults import *
|
||||||
urlpatterns = patterns(
|
urlpatterns = patterns(
|
||||||
"regluit.frontend.views",
|
"regluit.frontend.views",
|
||||||
url(r"^$", "home", name="home"),
|
url(r"^$", "home", name="home"),
|
||||||
url(r"^user/(?P<username>.+)/$", "user", name="user"),
|
url(r"^supporter/(?P<supporter_username>.+)/$", "supporter", name="supporter"),
|
||||||
)
|
)
|
||||||
|
|
|
@ -10,9 +10,9 @@ def home(request):
|
||||||
context_instance=RequestContext(request)
|
context_instance=RequestContext(request)
|
||||||
)
|
)
|
||||||
|
|
||||||
def user(request, username):
|
def supporter(request, supporter_username):
|
||||||
u = get_object_or_404(User, username=username)
|
supporter = get_object_or_404(User, username=supporter_username)
|
||||||
return render_to_response('user.html',
|
return render_to_response('supporter.html',
|
||||||
{"user": u, "wishlist": u.wishlist},
|
{"supporter": supporter},
|
||||||
context_instance=RequestContext(request)
|
context_instance=RequestContext(request)
|
||||||
)
|
)
|
||||||
|
|
Loading…
Reference in New Issue