From cdf47689969483a43437a08361bb19300fd8436d Mon Sep 17 00:00:00 2001 From: Luong Doan Date: Sun, 18 Oct 2020 18:08:48 +0000 Subject: [PATCH] Show full name in the contest's scoreboard --- templates/contest/ranking-table.html | 9 +++++++++ templates/contest/ranking.html | 16 ++++++++++++++++ 2 files changed, 25 insertions(+) diff --git a/templates/contest/ranking-table.html b/templates/contest/ranking-table.html index fd539dd..d138a70 100644 --- a/templates/contest/ranking-table.html +++ b/templates/contest/ranking-table.html @@ -7,6 +7,7 @@ {{ _('Rating') }} {% endif %} {{ _('Organization') }} + Tên thật {% endblock %} {% block after_rank %} @@ -20,6 +21,14 @@ {% endif %} + + + {% if user.user.first_name %} + + {{ user.user.first_name }} + + {% endif %} + {% endblock %} {% block user_data %} diff --git a/templates/contest/ranking.html b/templates/contest/ranking.html index 7a61cb2..90638d0 100644 --- a/templates/contest/ranking.html +++ b/templates/contest/ranking.html @@ -120,6 +120,16 @@ color: gray !important; font-weight: 600; } + + .fullname-column { + text-align: right !important; + border-right: none !important; + } + + .fullname-column span { + color: gray !important; + font-weight: 600; + } {% if has_rating %} @@ -299,6 +309,9 @@ $('#show-organizations-checkbox').click(function () { $('.organization-column').toggle(); }); + $('#show-fullnames-checkbox').click(function () { + $('.fullname-column').toggle(); + }); {% if request.user.is_authenticated %} $('#show-friends-checkbox').click(function() { let checked = $('#show-friends-checkbox').is(':checked'); @@ -332,6 +345,9 @@ + + + {% if request.user.is_authenticated %}