We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 4c3619f commit bd7c7f7Copy full SHA for bd7c7f7
project-templates/teams/team_detail.html
@@ -46,9 +46,13 @@ <h2>No image yet</h2>
46
</tr>
47
<tr>
48
<td class="">Captains</td>
49
- {% for captain in captains %}
50
- <td><a href="{% url 'profiles:profile' urlusername=captain.user %}">{{ captain.name }}</a></td>
51
- {% endfor %}
+ {% if team.captain.count == 0 %}
+ <td>There are no captains on this team!</td>
+ {% else %}
52
+ {% for captain in team.captain.all %}
53
+ <td><a href="{% url 'profiles:profile' urlusername=captain.user %}">{{ captain }}</a></td>
54
+ {% endfor %}
55
+ {% endif %}
56
57
58
<td>Created</td>
0 commit comments