NDOJ/templates/contest/ranking-table.html

80 lines
3.1 KiB
HTML
Raw Normal View History

2020-01-21 06:35:58 +00:00
{% extends "user/base-users-table.html" %}
2020-06-24 01:46:33 +00:00
{% set friends = request.profile.get_friends() if request.user.is_authenticated else {} %}
2020-01-21 06:35:58 +00:00
{% block after_rank_head %}
{% if has_rating %}
2022-10-08 10:43:55 +00:00
<th class="rating-column">{{ _('Rating') }}</th>
2020-01-21 06:35:58 +00:00
{% endif %}
{% endblock %}
{% block after_rank %}
{% if has_rating %}
2022-10-08 23:34:19 +00:00
<td class="rating-column">{% if user.participation_rating %}{{ rating_number(user.participation_rating) }}{% endif %}</td>
2020-01-21 06:35:58 +00:00
{% endif %}
2022-06-19 09:15:58 +00:00
{% endblock %}
2022-06-19 09:15:58 +00:00
{% block user_footer %}
{% if user.user.first_name %}
<div style="color: gray; font-weight: 600; display: none" class="fullname">
{{ user.user.first_name if user.user.first_name else ''}}
</div>
{% endif %}
2022-11-18 23:59:12 +00:00
{% if user.user.last_name %}
<div class="school" style="display: none"><a style="color: gray; font-weight: 600">
{{- user.user.last_name -}}
2022-06-19 09:15:58 +00:00
</a></div>
{% endif %}
2020-01-21 06:35:58 +00:00
{% endblock %}
{% block user_data %}
2021-10-24 22:57:06 +00:00
{% if user.participation.virtual %}
2022-06-19 09:15:58 +00:00
<sub style="color:grey">[{{user.participation.virtual}}]</sub>
2021-10-24 22:57:06 +00:00
{% endif %}
2021-05-24 20:00:36 +00:00
{% if can_edit %}
2020-01-21 06:35:58 +00:00
<span class="contest-participation-operation">
<form action="{{ url('contest_participation_disqualify', contest.key) }}" method="post">
{% csrf_token %}
<input type="hidden" name="participation" value="{{ user.participation.id }}">
{% if user.participation.is_disqualified %}
<a href="#" title="{{ _('Un-Disqualify') }}"
class="un-disqualify-participation"><i class="fa fa-undo fa-fw"></i></a>
{% else %}
<a href="#" title="{{ _('Disqualify') }}"
class="disqualify-participation"><i class="fa fa-trash fa-fw"></i></a>
{% endif %}
</form>
{% if perms.judge.change_contestparticipation %}
<a href="{{ url('admin:judge_contestparticipation_change', user.participation.id) }}"
title="{{ _('Admin') }}" class="edit-participation"><i class="fa fa-cog fa-fw"></i></a>
{% endif %}
</span>
{% endif %}
{% endblock %}
{% block before_point_head %}
2022-10-10 10:59:05 +00:00
<th class="full-name" style="display:none;">{{ _('Fullname') }}</th>
2022-11-18 23:59:12 +00:00
<th class="school" style="display:none;">{{ _('School') }}</th>
2020-01-21 06:35:58 +00:00
{% for problem in problems %}
2022-06-01 05:28:56 +00:00
<th class="points header problem-score-col" title="{{ problem.problem.name }}"><a href="{{ url('problem_detail', problem.problem.code) }}">
2021-05-24 20:00:36 +00:00
{{- contest.get_label_for_problem(loop.index0) }}
2020-01-21 06:35:58 +00:00
<div class="point-denominator">{{ problem.points }}</div>
2022-10-08 23:34:19 +00:00
<div class="problem-code" style="display: none;">{{ problem.problem.code }}</div>
2020-01-21 06:35:58 +00:00
</a></th>
{% endfor %}
{% endblock %}
{% block row_extra %}
2021-11-07 23:59:12 +00:00
class="{{ 'disqualified' if user.participation.is_disqualified }} {{'highlight' if user.username == request.user.username}}"
2020-01-21 06:35:58 +00:00
{% endblock %}
{% block before_point %}
{% for cell in user.problem_cells %}
{{ cell }}
{% endfor %}
{% endblock %}
{% block point %}
{{ user.result_cell }}
{% endblock %}