fix downloading and displaying patches for seeds/rooms with teams

This commit is contained in:
Fabian Dill
2021-01-03 18:28:07 +01:00
parent 07954fc230
commit eb58ee2422
6 changed files with 44 additions and 34 deletions

View File

@@ -33,26 +33,27 @@
</tr>
{% endif %}
{% if seed.multidata %}
<tr>
<td>Players:&nbsp;</td>
<td>
<ul>
{% for team in seed.multidata["names"] %}
<li>Team #{{ loop.index }} - {{ team | length }}
<ul>
{% for player in team %}
<li>
<a href="{{ url_for("download_raw_patch", seed_id=seed.id, player_id=loop.index) }}">{{ player }}</a>
</li>
{% endfor %}
</ul>
</li>
{% endfor %}
</ul>
</td>
</tr>
<tr>
<td>Rooms:&nbsp;</td>
<tr>
<td>Players:&nbsp;</td>
<td>
<ul>
{% for team in seed.multidata["names"] %}
{% set outer_loop = loop %}
<li>Team #{{ loop.index }} - {{ team | length }}
<ul>
{% for player in team %}
<li>
<a href="{{ url_for("download_raw_patch", seed_id=seed.id, player_id=loop.index, team_id=outer_loop.index0) }}">{{ player }}</a>
</li>
{% endfor %}
</ul>
</li>
{% endfor %}
</ul>
</td>
</tr>
<tr>
<td>Rooms:&nbsp;</td>
<td>
{% call macros.list_rooms(rooms) %}
<li>