prettified a few pages
authorNishanth Amuluru <nishanth@fossee.in>
Sun, 09 Jan 2011 15:30:06 +0530
changeset 365 32457bce3437
parent 364 2763afa1c2a2
child 366 4c349f310dfc
prettified a few pages
pytask/taskapp/views.py
pytask/templates/index.html
pytask/templates/task/view.html
--- a/pytask/taskapp/views.py	Sun Jan 09 15:09:13 2011 +0530
+++ b/pytask/taskapp/views.py	Sun Jan 09 15:30:06 2011 +0530
@@ -103,6 +103,7 @@
     is_creator = True if user == task.created_by else False
     has_claimed = True if user in claimed_users else False
 
+    context['selected_users'] = selected_users
     context['is_selected'] = True if user in selected_users else False
     context['can_approve'] = True if task.status == "UP" and\
                                      profile.rights in ["MG", "DC"]\
--- a/pytask/templates/index.html	Sun Jan 09 15:09:13 2011 +0530
+++ b/pytask/templates/index.html	Sun Jan 09 15:30:06 2011 +0530
@@ -14,19 +14,9 @@
     <br />
     {% endif %}
     
-    
-    {% if unpublished_tasks %}
-    Unpublished tasks viewable by you:<ul>
-        {% for a_task in unpublished_tasks %}
-            <li><a href="/task/view/tid={{a_task.id}}">{{a_task.title}}</a></li>
-        {% endfor %}
-        </ul>
-    <br />
-    {% endif %}
-
-    {% if reviewered_tasks %}
+    {% if reviewing_tasks %}
     Tasks you are reviewering:<ul>
-        {% for a_task in reviewered_tasks %}
+        {% for a_task in reviewing_tasks %}
             <li><a href="/task/view/tid={{a_task.uniq_key}}">{{a_task.title}}</a></li>
         {% endfor %}
         </ul>
--- a/pytask/templates/task/view.html	Sun Jan 09 15:09:13 2011 +0530
+++ b/pytask/templates/task/view.html	Sun Jan 09 15:30:06 2011 +0530
@@ -21,7 +21,7 @@
         <a href="/task/delete/tid={{task.uniq_key}}">Delete task</a>
     {% endif %}
 
-    <hr />created by <a href="/user/view/uid={{ task.created_by.uniq_key }}">{{ task.created_by.username }}</a>
+    <hr />created by <a href="/user/view/uid={{ task.created_by.id }}">{{ task.created_by.username }}</a>
     on {{task.creation_datetime|date:"D d M Y"}} at {{task.creation_datetime|time:"H:i"}}<br />
     
     {% if reviewers %}
@@ -84,12 +84,9 @@
         
     {% if selected_users %}
         Users working on this task:
-        {% for user in assigned_users %}
+        {% for user in selected_users %}
             <a href="/user/view/uid={{user.id}}">{{user.username}}</a>
         {% endfor %}
-        {% if is_reviewer %}
-            <a href="/task/remuser/tid={{task.uniq_key}}">Remove an existing user</a>
-        {% endif %}
         <br />
     {% endif %}
     
@@ -101,7 +98,6 @@
         <a href="/task/assignpynts/tid={{task.uniq_key}}">Request assign pynts and mark the task as complete</a>
     {% endif %}
     
-
     {% if is_selected %}
         <a href="/task/report/tid={{task.uniq_key}}">Submit Work</a>
     {% endif %}
@@ -112,9 +108,10 @@
         {% for comment in comments %}
             <a href="/user/view/uid={{comment.commented_by.uniq_key}}">{{ comment.commented_by.username }}</a> 
             on {{ comment.comment_datetime|date:"D d M Y"}} at {{comment.comment_datetime|time:"H:i"}} wrote:<br />
-        {{ comment.data|linebreaksbr }}<br /><br />
+        {{ comment.data|linebreaksbr }}<br />
         {% endfor %}
     {% endif %}
+    <hr />
 
     {% if can_comment %}
     Add comment:<br />