forked from sio2project/oioioi
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
SIO-2137 Add button 'rejudge not needed' to problem actions
Change-Id: Ib298a8100de2d8b19be057806c76cffc49488ae8
- Loading branch information
Showing
9 changed files
with
136 additions
and
86 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
32 changes: 32 additions & 0 deletions
32
oioioi/contests/templates/contests/base_confirmation_screen.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
{% extends "base-with-menu.html" %} | ||
{% load i18n %} | ||
|
||
{% block title %}Put the title here.{% endblock %} | ||
|
||
{% block main-content %} | ||
<h1>{% block confirmation_header %}Put the header here.{% endblock %}</h1> | ||
|
||
{% block confirmation_form_explanation %} | ||
Put some explanation about what is going to happen here. | ||
{% endblock %} | ||
|
||
|
||
{% block confirmation_form %} | ||
<p>{% trans "Are you sure?" %}</p> | ||
|
||
<div> | ||
<form method="post"> | ||
{% csrf_token %} | ||
<input type="hidden" name="post" value="yes"/> | ||
<div class="form-group"> | ||
<button type="submit" class="btn btn-danger"> | ||
{% trans "Yes, I am sure." %} | ||
</button> | ||
<button type="button" class="btn btn-default" onclick="history.back()"> | ||
{% trans "No, go back" %} | ||
</button> | ||
</div> | ||
</form> | ||
</div> | ||
{% endblock %} | ||
{% endblock %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,33 +1,14 @@ | ||
{% extends "base-with-menu.html" %} | ||
{% extends "contests/base_confirmation_screen.html" %} | ||
{% load i18n %} | ||
|
||
{% block title %}{% trans "Confirm rejudge" %}{% endblock %} | ||
|
||
{% block main-content %} | ||
|
||
<h1>{% trans "Confirm rejudge" %}</h1> | ||
|
||
<p> | ||
{% trans "Tests for this problem have changed, you should rejudge existing submissions." %} | ||
</p> | ||
<p> | ||
{% blocktrans %}You are going to rejudge {{ count }} submissions. It may take some time.{% endblocktrans %} | ||
</p> | ||
|
||
<p>{% trans "Are you sure?" %}</p> | ||
|
||
<div> | ||
<form method="post"> | ||
{% csrf_token %} | ||
<input type="hidden" name="post" value="yes" /> | ||
<div class="form-group"> | ||
<button type="submit" class="btn btn-danger"> | ||
{% trans "Yes, I am sure." %} | ||
</button> | ||
<button type="button" class="btn btn-default" onclick="history.back()"> | ||
{% trans "No, go back" %} | ||
</button> | ||
</div> | ||
</form> | ||
</div> | ||
{% block confirmation_header %}{% trans "Confirm rejudge" %}{% endblock %} | ||
{% block confirmation_form_explanation %} | ||
<p> | ||
{% trans "Something about this problem has changed. If the change was trivial (like a typo) then rejudge is not needed." %} | ||
{% trans "If the tests for the problem have changed then you should proceed with a rejudge." %} | ||
</p> | ||
<p> | ||
{% blocktrans %}You are going to rejudge {{ count }} submissions. It may take some time.{% endblocktrans %} | ||
</p> | ||
{% endblock %} |
15 changes: 15 additions & 0 deletions
15
oioioi/contests/templates/contests/confirm_rejudge_not_needed.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
{% extends "contests/base_confirmation_screen.html" %} | ||
{% load i18n %} | ||
|
||
{% block title %}{% trans "Confirm rejudge is not needed" %}{% endblock %} | ||
|
||
{% block confirmation_header %}{% trans "Confirm rejudge is not needed" %}{% endblock %} | ||
{% block confirmation_form_explanation %} | ||
<p> | ||
{% trans "Something about this problem has changed. If the change was trivial (like a typo) then rejudge is not needed." %} | ||
{% trans "If the tests for the problem have changed then you should proceed with a rejudge." %} | ||
</p> | ||
<p> | ||
{% blocktrans %}You are going to mark the submissions to this problem as not needing a rejudge.{% endblocktrans %} | ||
</p> | ||
{% endblock %} |
46 changes: 15 additions & 31 deletions
46
oioioi/contests/templates/contests/confirm_resetting_limits.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,37 +1,21 @@ | ||
{% extends "base-with-menu.html" %} | ||
{% extends "contests/base_confirmation_screen.html" %} | ||
{% load i18n %} | ||
|
||
{% block title %}{% trans "Confirm resetting limits" %}{% endblock %} | ||
|
||
{% block main-content %} | ||
{% block confirmation_header %}{% trans "Confirm resetting limits" %}{% endblock %} | ||
|
||
<h1>{% trans "Confirm resetting limits" %}</h1> | ||
|
||
<p> | ||
{% url 'problem_site' probleminstance.problem.problemsite.url_key as url %} | ||
{% blocktrans %} | ||
You are going to reset time and memory limits and point | ||
scores of all tests for problem {{ probleminstance }}. | ||
<br> | ||
Limits and scores for this problem will be replaced by limits setted on | ||
<a href="{{ url }}"> | ||
{{ problem site }} | ||
</a>. | ||
{% endblocktrans %} | ||
</p> | ||
|
||
<p>{% trans "Are you sure?" %}</p> | ||
|
||
<form method="post"> | ||
{% csrf_token %} | ||
<input type="hidden" name="post" value="yes" /> | ||
<div class="form-group"> | ||
<button type="submit" class="btn btn-danger"> | ||
{% trans "Yes, I am sure." %} | ||
</button> | ||
<button type="button" class="btn btn-default" onclick="history.back()"> | ||
{% trans "No, go back" %} | ||
</button> | ||
</div> | ||
</form> | ||
{% block confirmation_form_explanation %} | ||
<p> | ||
{% url 'problem_site' probleminstance.problem.problemsite.url_key as url %} | ||
{% blocktrans %} | ||
You are going to reset time and memory limits and point | ||
scores of all tests for problem {{ probleminstance }}. | ||
<br> | ||
Limits and scores for this problem will be replaced by limits set on the | ||
<a href="{{ url }}"> | ||
problem site | ||
</a>. | ||
{% endblocktrans %} | ||
</p> | ||
{% endblock %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters