-
Notifications
You must be signed in to change notification settings - Fork 0
/
team.html
82 lines (81 loc) · 2.57 KB
/
team.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
{% extends "base.html" %}
{% block app_content %}
<h1>Profile of team {{ team.team_name }}</h1>
<h3>Members: {% if member1 %} <a href="{{ url_for('user', username=member1.username) }}"> {{ member1.username }}</a>
{% else %} <a href="{{ url_for('join_team', team_name=team.team_name) }}"> [Join {{ team.team_name }}]</a>
{% endif %} and {% if member2 %} <a href="{{ url_for('user', username=member2.username) }}">
{{ member2.username }}</a>
{% else %} <a href="{{ url_for('join_team', team_name=team.team_name) }}"> [Join {{ team.team_name }}]</a>
{% endif %}</3>
<h4>Team id: {{ team.id }}</h4>
<hr>
{% if matches %}
<h2>Matches assigned to {{ team.team_name }}</h2>
<table class="table table-hover">
<tr>
<th>Attacker Team</th>
<th>Defender Team</th>
<th>Round</th>
<th>Match State</th>
</tr>
{% for match in matches %}
{% include '_match.html' %}
{% endfor %}
</table>
<nav aria-label="...">
<ul class="pager">
<li class="previous{% if not match_prev_url %} disabled{% endif %}">
<a href="{{ match_prev_url or '#' }}">
<span aria-hidden="true">←</span> Newer matches
</a>
</li>
<li class="next{% if not match_next_url %} disabled{% endif %}">
<a href="{{ match_next_url or '#' }}">
Older matches <span aria-hidden="true">→</span>
</a>
</li>
</ul>
</nav>
{% endif %}
{% if defence %}
<h2>{{ team.team_name }}'s defence</h2>
<table class="table table-hover">
<tr>
<th>Team's defence</th>
<th>Utility</th>
<th>Timestamp</th>
<th>Round</th>
</tr>
{% include '_defence.html' %}
</table>
{% endif %}
{% if attacks %}
<h2>{{ team.team_name }}'s attacks</h2>
<table class="table table-hover">
<tr>
<th>Attacker Team</th>
<th>Defender Team</th>
<th>Results</th>
<th>Timestamp</th>
<th>Round</th>
</tr>
{% for attack in attacks %}
{% include '_attack.html' %}
{% endfor %}
</table>
<nav aria-label="...">
<ul class="pager">
<li class="previous{% if not attack_prev_url %} disabled{% endif %}">
<a href="{{ attack_prev_url or '#' }}">
<span aria-hidden="true">←</span> Newer attacks
</a>
</li>
<li class="next{% if not attack_next_url %} disabled{% endif %}">
<a href="{{ attack_next_url or '#' }}">
Older attacks <span aria-hidden="true">→</span>
</a>
</li>
</ul>
</nav>
{% endif %}
{% endblock %}