need to distinguish between the user being viewed (subscriber for now) and the logged in user

pull/1/head
Ed Summers 2011-09-12 15:13:21 +00:00
parent accffc3b8e
commit d8f1d64085
2 changed files with 3 additions and 3 deletions

View File

@ -2,9 +2,9 @@
{% block content %} {% block content %}
<h1>Wishlist for {{ user.username }}</h1> <h1>Wishlist for {{ subscriber.username }}</h1>
{% for work in user.wishlist.works.all %} {% for work in subscriber.wishlist.works.all %}
{% include "book_panel.html" %} {% include "book_panel.html" %}
{% endfor %} {% endfor %}

View File

@ -13,6 +13,6 @@ def home(request):
def user(request, username): def user(request, username):
u = get_object_or_404(User, username=username) u = get_object_or_404(User, username=username)
return render_to_response('user.html', return render_to_response('user.html',
{"user": u, "wishlist": u.wishlist}, {"subscriber": u},
context_instance=RequestContext(request) context_instance=RequestContext(request)
) )