2022-11-27 19:59:53 +00:00
|
|
|
{%- extends 'default.html' -%}
|
2022-11-27 20:04:51 +00:00
|
|
|
{% block pagetitle %}World Cup 2022 Betting Leaderboard{% endblock %}
|
2022-11-27 19:59:53 +00:00
|
|
|
{% block content %}
|
|
|
|
<h1>World Cup 2022 Betting Leaderboard</h1>
|
|
|
|
<div class="overflow-x-auto">
|
|
|
|
<table class="table table-striped mb-5">
|
|
|
|
<thead class="bg-primary text-white">
|
|
|
|
<tr>
|
2022-12-10 10:40:34 +00:00
|
|
|
<th>#</th>
|
|
|
|
<th>Name</th>
|
|
|
|
<th>Wins</th>
|
|
|
|
<th>Bets</th>
|
|
|
|
<th>Win rate</th>
|
|
|
|
<th>Winnings</th>
|
2022-11-27 19:59:53 +00:00
|
|
|
</tr>
|
|
|
|
</thead>
|
|
|
|
<tbody>
|
|
|
|
{% for r in result %}
|
2022-11-27 20:07:50 +00:00
|
|
|
<tr>
|
2022-11-27 19:59:53 +00:00
|
|
|
{% set user = users.get(r[0]) %}
|
|
|
|
<td>{{loop.index}}</td>
|
|
|
|
<td data-sort-key="{{user.username.lower() if user else ''}}">{%- include 'user_in_table.html' -%}</td>
|
|
|
|
<td>{{r[1]}}</td>
|
2022-11-27 23:04:14 +00:00
|
|
|
<td>{{r[2]}}</td>
|
2022-11-29 00:31:55 +00:00
|
|
|
{% set ratio = r[1]/r[2] %}
|
|
|
|
{% set percent = (ratio*100)|string %}
|
2022-11-29 00:33:23 +00:00
|
|
|
<td data-sort-key="{{ratio}}">{{percent[:3].replace('0.0', '0').rstrip('.')}}%</td>
|
2022-11-27 23:04:14 +00:00
|
|
|
<td>{{r[3]}}</td>
|
2022-11-27 20:07:50 +00:00
|
|
|
</tr>
|
2022-11-27 19:59:53 +00:00
|
|
|
{% endfor %}
|
|
|
|
</tbody>
|
|
|
|
</table>
|
|
|
|
</div>
|
2022-12-10 10:40:34 +00:00
|
|
|
|
2022-11-27 19:59:53 +00:00
|
|
|
{% endblock %}
|