85 lines
3.3 KiB
HTML
85 lines
3.3 KiB
HTML
|
{% extends 'team_base.html' %}
|
||
|
{% load commonmark %}
|
||
|
{% load bootstrap3 %}
|
||
|
{% load teams_tags %}
|
||
|
|
||
|
|
||
|
{% block team_content %}
|
||
|
|
||
|
<div class="panel panel-default">
|
||
|
<div class="panel-heading">
|
||
|
<h4>Members</h4>
|
||
|
</div>
|
||
|
<div class="panel-body">
|
||
|
<p>The following <b>{{ team.approved_members.count }}</b> people {% if team.unapproved_members.count %}(and {{ team.unapproved_members.count }} pending){% endif %} are members of the <b>{{ team.name }} Team</b>:</p>
|
||
|
<table class="table table-hover">
|
||
|
<thead>
|
||
|
<tr>
|
||
|
<th>
|
||
|
Name
|
||
|
</th>
|
||
|
<th>
|
||
|
Status
|
||
|
</th>
|
||
|
{% if request.user in team.responsible_members.all %}
|
||
|
<th>
|
||
|
Action
|
||
|
</th>
|
||
|
{% endif %}
|
||
|
</tr>
|
||
|
</thead>
|
||
|
<tbody>
|
||
|
{% for teammember in team.memberships.all %}
|
||
|
<tr>
|
||
|
<td>
|
||
|
{{ teammember.user.profile.get_public_credit_name }} {% if teammember.user == request.user %}(this is you!){% endif %}
|
||
|
</td>
|
||
|
<td>
|
||
|
Team {% if teammember.responsible %}Responsible{% else %}Member{% endif %}
|
||
|
{% if not teammember.approved %}(pending approval){% endif %}
|
||
|
</td>
|
||
|
{% if request.user in team.responsible_members.all %}
|
||
|
<td>
|
||
|
<div class="btn-group-vertical">
|
||
|
<a class="btn btn-danger"
|
||
|
href="{% url 'teams:teammember_remove' camp_slug=camp.slug team_slug=team.slug pk=teammember.id %}">
|
||
|
<i class="fas fa-trash-o"></i> Remove Member
|
||
|
</a>
|
||
|
{% if not teammember.approved %}
|
||
|
<a class="btn btn-success"
|
||
|
href="{% url 'teams:teammember_approve' camp_slug=camp.slug team_slug=team.slug pk=teammember.id %}">
|
||
|
<i class="fas fa-check"></i> Approve Member
|
||
|
</a>
|
||
|
{% endif %}
|
||
|
</div>
|
||
|
</td>
|
||
|
{% endif %}
|
||
|
</tr>
|
||
|
{% empty %}
|
||
|
<p>No members found!</p>
|
||
|
{% endfor %}
|
||
|
</tbody>
|
||
|
</table>
|
||
|
|
||
|
{% if request.user.authorized %}
|
||
|
|
||
|
<p>Your membership status: <b>{% membershipstatus user team %}</b></p>
|
||
|
|
||
|
{% if request.user in team.members.all %}
|
||
|
{% if team.irc_channel and team.irc_channel_managed and request.user.profile.nickserv_username %}
|
||
|
<a href="{% url 'teams:fix_irc_acl' camp_slug=camp.slug team_slug=team.slug %}" class="btn btn-primary"><i class="fas fa-wrench"></i> Fix IRC ACL</a>
|
||
|
{% endif %}
|
||
|
<a href="{% url 'teams:leave' camp_slug=camp.slug team_slug=team.slug %}" class="btn btn-danger"><i class="fas fa-times"></i> Leave Team</a>
|
||
|
{% else %}
|
||
|
{% if team.needs_members %}
|
||
|
<b>This team is looking for members!</b> <a href="{% url 'teams:join' camp_slug=camp.slug team_slug=team.slug %}" class="btn btn-xs btn-success"><i class="fas fa-plus"></i> Join Team</a>
|
||
|
{% endif %}
|
||
|
{% endif %}
|
||
|
{% endif %}
|
||
|
|
||
|
<hr>
|
||
|
</div>
|
||
|
</div>
|
||
|
|
||
|
{% endblock %}
|