From 3fb78e714d8be7c41028ed77e8cc5862de9bbd61 Mon Sep 17 00:00:00 2001 From: cuom1999 Date: Wed, 1 Jun 2022 00:47:22 -0500 Subject: [PATCH] Fix small bugs --- judge/views/submission.py | 4 +++- resources/submission.scss | 1 + templates/contest/ranking.html | 8 ++++++++ templates/submission/user-ajax.html | 2 +- 4 files changed, 13 insertions(+), 2 deletions(-) diff --git a/judge/views/submission.py b/judge/views/submission.py index 3e284b3..c196445 100644 --- a/judge/views/submission.py +++ b/judge/views/submission.py @@ -790,7 +790,9 @@ class UserContestSubmissionsAjax(UserContestSubmissions): def contest_time(self, s): if s.contest.participation.live: - return s.date - s.contest.participation.real_start + if self.contest.time_limit: + return s.date - s.contest.participation.real_start + return s.date - self.contest.start_time return None def get_context_data(self, **kwargs): diff --git a/resources/submission.scss b/resources/submission.scss index afb1f2e..2846273 100644 --- a/resources/submission.scss +++ b/resources/submission.scss @@ -366,5 +366,6 @@ label[for="language"], label[for="status"] { .lightbox-submissions { td { padding-right: 0.2em; + font-size: 1.2em; } } \ No newline at end of file diff --git a/templates/contest/ranking.html b/templates/contest/ranking.html index b9788fa..4820192 100644 --- a/templates/contest/ranking.html +++ b/templates/contest/ranking.html @@ -137,6 +137,11 @@ border-radius: 10px; height: 80%; width: 60%; + overflow: auto; + } + + .featherlight { + /*position: re;*/ } @@ -183,6 +188,9 @@ width: 200px; height: 2.3em; } + html.with-featherlight { + overflow: unset; + } {% endblock %} diff --git a/templates/submission/user-ajax.html b/templates/submission/user-ajax.html index 1b825e0..de5e1a7 100644 --- a/templates/submission/user-ajax.html +++ b/templates/submission/user-ajax.html @@ -10,7 +10,7 @@ {% if submission.contest_time %} {{submission.contest_time}} {% else %} - {% trans time=submission.date|date(_("N j, Y, g:i a")) %} + {% trans time=submission.date|date(_("g:i a d/m/Y")) %} {{ time }} {% endtrans %} {% endif %}