Skip to content
Snippets Groups Projects

Tabulka Moje soutěže

Closed Jan Prachař requested to merge honza/mr7 into devel
1 unresolved thread

Files

+ 52
0
@@ -2,6 +2,58 @@
@@ -2,6 +2,58 @@
{% block title %}Organizátorské rozhraní{% endblock %}
{% block title %}Organizátorské rozhraní{% endblock %}
{% block body %}
{% block body %}
 
{% if contests %}
 
<h3>Moje soutěže</h3>
 
 
<table class="table table-bordered">
 
<thead><tr>
 
<th>Kategorie
 
<th>Kolo
 
<th>Stav
 
<th>Zadání
 
<th>Moje role
 
<th>Odkazy
 
</thead>
 
{% for c,role,r in contests %}
 
{% set rr = gatekeeper.rights_for_contest(c) %}
 
{% if c.state == RoundState.preparing %}
 
<tr class="warning">
 
{% elif c.state == RoundState.running %}
 
<tr class="success">
 
{% elif c.state == RoundState.grading %}
 
<tr class="info">
 
{% else %}
 
<tr>
 
{% endif %}
 
<td class="text-center" style="font-size: 1.2em"><b>{{ r.category }}</b>
 
<td>{{ r.name }} {{ c.place.name_locativ() if c.place.level > 0 else '' }}
 
<td>{{ c.state.friendly_name() }}
 
<td>
 
{% if rr.can_view_statement() %}
 
<a href='{{ url_for('org_task_statement', id=r.round_id) }}'>stáhnout</a>
 
{% else %}
 
{{ rr.cannot_view_statement_reason() }}
 
{% endif %}
 
<td>{{ role_names[role] }}
 
<td>
 
<a class="btn btn-xs btn-primary" href='{{ url_for('org_contest', id=c.contest_id) }}'>Detail</a>
 
<a class="btn btn-xs btn-default" href='{{ url_for('org_contest_list', id=c.contest_id) }}'>Účastníci</a>
 
{% if rr.can_view_submits() and c.state != RoundState.preparing %}
 
<a class="btn btn-xs btn-success" href='{{ url_for('org_contest_solutions', id=c.contest_id) }}'>Odevzdaná řešení</a>
 
{% endif %}
 
{% if (c.state == RoundState.grading and rr.can_view_submits()) or c.state == RoundState.closed %}
 
<a class="btn btn-xs btn-warning" href='{{ url_for('org_score', contest_id=c.contest_id) }}'>Výsledky</a>
 
{% endif %}
 
{% if rr.have_right(Right.manage_contest) and c.state != RoundState.closed %}
 
<a class="btn btn-xs btn-primary" href='{{ url_for('org_contest_add_user', id=c.contest_id) }}'>+ Přidat účastníka</a>
 
<a class="btn btn-xs btn-default" href='{{ url_for('org_contest_import', id=c.contest_id) }}'>Import</a>
 
{% endif %}
 
</td>
 
</tr>
 
{% endfor %}
 
</table>
 
{% endif %}
 
<h3>Různé</h3>
<h3>Různé</h3>
<ul>
<ul>
Loading