templates/task/claim.html
changeset 33 0d0ea7b188d5
parent 25 c0e4fc8b8b5b
child 70 a14ec2f09beb
--- a/templates/task/claim.html	Fri Feb 05 15:42:35 2010 +0530
+++ b/templates/task/claim.html	Fri Feb 05 16:05:54 2010 +0530
@@ -1,12 +1,16 @@
 {% extends 'base.html' %}
 {% block content %}
-    List of all the claims for the task <a href="/task/view/tid={{task.id}}">{{task.title}}</a><br />
-    {% for claim in claims %}
-        <hr />
-        <a href="/user/view/uid={{claim.user.id}}">{{claim.user.username}}</a> at {{claim.creation_datetime.ctime}} wrote:<br />
-        {{claim.message}}<br />
-    {% endfor %}
-    {% if task_claimable and is_mentor %}
+    {% if claims %}
+        List of all the claims for the task <a href="/task/view/tid={{task.id}}">{{task.title}}</a><br />
+        {% for claim in claims %}
+            <hr />
+            <a href="/user/view/uid={{claim.user.id}}">{{claim.user.username}}</a> at {{claim.creation_datetime.ctime}} wrote:<br />
+            {{claim.message}}<br />
+        {% endfor %}
+    {% else %}
+        There are no claims for task <a href="/task/view/tid={{task.id}}">{{task.title}}</a> yet.
+    {% endif %}
+    {% if task_claimed and is_mentor %}
         <a href="/task/assign/tid={{task.id}}">Assign task</a>
     {% endif %}
     {% if user_can_claim %}