summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMadhusudan.C.S2011-02-09 01:48:54 +0530
committerMadhusudan.C.S2011-02-09 01:48:54 +0530
commit6c632964b3979edd5badbf094434f7c2fb0b4cba (patch)
tree37456f73ae8bec7e98d7b7ed4e808090e754c012
parent173cebd126ffaa2f93698f2cc6897986eab79c31 (diff)
downloadpytask-6c632964b3979edd5badbf094434f7c2fb0b4cba.tar.gz
pytask-6c632964b3979edd5badbf094434f7c2fb0b4cba.tar.bz2
pytask-6c632964b3979edd5badbf094434f7c2fb0b4cba.zip
Use profile_user for context variable since it conflicts with one provided by RequestContextProcessor.
-rwxr-xr-xpytask/profile/views.py2
-rw-r--r--pytask/templates/profile/view_user.html17
2 files changed, 10 insertions, 9 deletions
diff --git a/pytask/profile/views.py b/pytask/profile/views.py
index 525ff3b..c247d78 100755
--- a/pytask/profile/views.py
+++ b/pytask/profile/views.py
@@ -40,7 +40,7 @@ def view_user_profile(request, user_id, template_name='profile/view_user.html'):
profile = user.get_profile()
context = {
- 'user': user,
+ 'profile_user': user,
'profile': profile,
}
diff --git a/pytask/templates/profile/view_user.html b/pytask/templates/profile/view_user.html
index 98c3204..f25c0f1 100644
--- a/pytask/templates/profile/view_user.html
+++ b/pytask/templates/profile/view_user.html
@@ -8,41 +8,42 @@ Gender: {{ profile.gender }} <br />
<hr />
About: {{ profile.aboutme|linebreaksbr }} <br />
-{% if user.claimed_tasks.all %}
+{{ profile_user.getprofile.full_name }}
+{% if profile_user.claimed_tasks.all %}
<hr />
<h3>List of Tasks requested for claim but awaiting approval:</h3>
<ul>
- {% for task in user.claimed_tasks.all %}
+ {% for task in profile_user.claimed_tasks.all %}
<li><a href="{% url view_task task.id %}">{{ task.title }}</a></li>
{% endfor %}
</ul>
{% endif %}
-{% if user.selected_tasks.all %}
+{% if profile_user.selected_tasks.all %}
<hr />
<h3>List of Tasks currently working on:</h3>
<ul>
- {% for task in user.selected_tasks.all %}
+ {% for task in profile_user.selected_tasks.all %}
<li><a href="{% url view_task task.id %}">{{ task.title }}</a></li>
{% endfor %}
</ul>
{% endif %}
-{% if user.comp_tasks.all %}
+{% if profile_user.comp_tasks.all %}
<hr />
<h3>List of Tasks completed:</h3>
<ul>
- {% for task in user.comp_tasks.all %}
+ {% for task in profile_user.comp_tasks.all %}
<li><a href="{% url view_task task.id %}">{{ task.title }}</a></li>
{% endfor %}
</ul>
{% endif %}
-{% if user.reviewing_tasks.all %}
+{% if profile_user.reviewing_tasks.all %}
<hr />
<h3>List of Tasks reviewed:</h3>
<ul>
- {% for task in user.reviewing_tasks.all %}
+ {% for task in profile_user.reviewing_tasks.all %}
<li><a href="{% url view_task task.id %}">{{ task.title }}</a></li>
{% endfor %}
</ul>