-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathscoreboard.html
69 lines (63 loc) · 1.87 KB
/
scoreboard.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
{% extends "base.html" %}
{% block content %}
<div class="jumbotron">
<div class="container">
<h1>Scoreboard</h1>
</div>
</div>
<div class="container">
{% include "components/errors.html" %}
<div id="score-graph" class="row d-flex align-items-center">
<div class="col-md-12 text-center">
<i class="fas fa-circle-notch fa-spin fa-3x fa-fw spinner"></i>
</div>
</div>
{% cache 60, CacheKeys.PUBLIC_SCOREBOARD_TABLE %}
{% if standings %}
<div id="scoreboard" class="row">
<div class="col-md-12">
<table class="table table-striped">
<thead>
<tr>
<td scope="col" width="10px"><b>Place</b></td>
<td scope="col"><b>{{ get_mode_as_word(capitalize=True) }}</b></td>
<td scope="col"><b>Score</b></td>
</tr>
</thead>
<tbody>
{% for standing in standings %}
<tr>
<th scope="row" class="text-center">{{ loop.index }}</th>
<td>
<a href="{{ generate_account_url(standing.account_id) }}">
{{ standing.name | truncate(50) }}
{% if standing.oauth_id %}
{% if Configs.user_mode == 'teams' %}
<a href="https://majorleaguecyber.org/t/{{ standing.name }}">
<span class="badge badge-primary">Official</span>
</a>
{% elif Configs.user_mode == 'users' %}
<a href="https://majorleaguecyber.org/u/{{ standing.name }}">
<span class="badge badge-primary">Official</span>
</a>
{% endif %}
{% endif %}
</a>
</td>
<td>{{ standing.score }}</td>
</tr>
{% endfor %}
</tbody>
</table>
</div>
</div>
{% endif %}
{% endcache %}
</div>
{% endblock %}
{% block scripts %}
<script defer src="{{ url_for('views.themes', path='js/echarts.bundle.js') }}"></script>
{% endblock %}
{% block entrypoint %}
<script defer src="{{ url_for('views.themes', path='js/pages/scoreboard.js') }}"></script>
{% endblock %}