Add school to ranking
This commit is contained in:
parent
a35ea0f6d5
commit
e229b53226
7 changed files with 59 additions and 37 deletions
|
@ -56,7 +56,7 @@
|
|||
{% endif %}
|
||||
{%- endif -%}
|
||||
</a>
|
||||
<div id="time">
|
||||
<div class="time">
|
||||
{% if contest.time_limit %}
|
||||
{% trans trimmed start_time=contest.start_time|date(_("F j, Y, G:i T")), end_time=contest.end_time|date(_("F j, Y, G:i T")), time_limit=contest.time_limit|timedelta('localized-no-seconds') %}
|
||||
<b>{{ time_limit }}</b> window between <b>{{ start_time }}</b> and <b>{{ end_time }}</b>
|
||||
|
@ -67,6 +67,11 @@
|
|||
{% endtrans %}
|
||||
{% endif %}
|
||||
</div>
|
||||
{% if contest.freeze_after and contest.freeze_after + contest.start_time < now %}
|
||||
<div class="time" style="margin-top: 0.2em">
|
||||
<b>{{_("Standing was frozen")}}</b> {{_("at")}} <b>{{ (contest.freeze_after + contest.start_time) | date(_("F j, Y, G:i T")) }}</b>
|
||||
</div>
|
||||
{% endif %}
|
||||
</div>
|
||||
|
||||
<div class="content-description">
|
||||
|
|
|
@ -58,7 +58,7 @@
|
|||
|
||||
function renew_filter(need_update=true) {
|
||||
var checkboxes = [
|
||||
'#show-organizations-checkbox',
|
||||
'#show-schools-checkbox',
|
||||
'#show-fullnames-checkbox',
|
||||
'#show-total-score-checkbox',
|
||||
];
|
||||
|
@ -171,8 +171,8 @@
|
|||
window.location.href = url.replace('__username__', $(this).val());
|
||||
});
|
||||
|
||||
$('#show-organizations-checkbox').click(function () {
|
||||
$('.organization').toggle();
|
||||
$('#show-schools-checkbox').click(function () {
|
||||
$('.school').toggle();
|
||||
});
|
||||
$('#show-fullnames-checkbox').click(function () {
|
||||
$('.fullname').toggle();
|
||||
|
|
|
@ -36,7 +36,7 @@
|
|||
}
|
||||
|
||||
.frozen {
|
||||
background: #a5c5d9 !important;
|
||||
background: lightskyblue !important;
|
||||
}
|
||||
|
||||
.rank {
|
||||
|
|
|
@ -20,9 +20,9 @@
|
|||
{{ user.user.first_name if user.user.first_name else ''}}
|
||||
</div>
|
||||
{% endif %}
|
||||
{% if user.organization %}
|
||||
<div class="organization" style="display: none"><a style="color: gray; font-weight: 600" href="{{ user.organization.get_absolute_url() }}">
|
||||
{{- user.organization.short_name -}}
|
||||
{% if user.user.last_name %}
|
||||
<div class="school" style="display: none"><a style="color: gray; font-weight: 600">
|
||||
{{- user.user.last_name -}}
|
||||
</a></div>
|
||||
{% endif %}
|
||||
{% endblock %}
|
||||
|
@ -54,6 +54,7 @@
|
|||
|
||||
{% block before_point_head %}
|
||||
<th class="full-name" style="display:none;">{{ _('Fullname') }}</th>
|
||||
<th class="school" style="display:none;">{{ _('School') }}</th>
|
||||
{% for problem in problems %}
|
||||
<th class="points header problem-score-col" title="{{ problem.problem.name }}"><a href="{{ url('problem_detail', problem.problem.code) }}">
|
||||
{{- contest.get_label_for_problem(loop.index0) }}
|
||||
|
|
|
@ -103,8 +103,9 @@
|
|||
if ($col.hasClass('rating-column')) {
|
||||
return;
|
||||
} else if ($col.hasClass('user-name')) {
|
||||
row_data.push(clean_text($col.ignore('.fullname').ignore('.organization').text()));
|
||||
row_data.push(clean_text($col.ignore('.user').ignore('.organization').text()));
|
||||
row_data.push(clean_text($col.ignore('.fullname').ignore('.school').text()));
|
||||
row_data.push(clean_text($col.ignore('.user').ignore('.school').text()));
|
||||
row_data.push(clean_text($col.ignore('.user').ignore('.fullname').text()));
|
||||
} else {
|
||||
row_data.push(clean_text($col.ignore('.solving-time').text()));
|
||||
}
|
||||
|
@ -135,8 +136,8 @@
|
|||
<input id="search-contest" type="text" placeholder="{{ _('View user participation') }}">
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
<input id="show-organizations-checkbox" type="checkbox" style="vertical-align: bottom">
|
||||
<label for="show-organizations-checkbox" style="vertical-align: bottom; margin-right: 1em;">{{ _('Show organizations') }}</label>
|
||||
<input id="show-schools-checkbox" type="checkbox" style="vertical-align: bottom">
|
||||
<label for="show-schools-checkbox" style="vertical-align: bottom; margin-right: 1em;">{{ _('Show schools') }}</label>
|
||||
|
||||
<input id="show-fullnames-checkbox" type="checkbox" style="vertical-align: bottom">
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue