修复正在进行图标不显示的问题,修改view里contest_problem状态的变量名,使更确切,添加dealing-falg的css
This commit is contained in:
@@ -328,9 +328,12 @@ def contest_problems_list_page(request, contest_id):
|
|||||||
state[item.problem_id] = item.ac
|
state[item.problem_id] = item.ac
|
||||||
for item in contest_problems:
|
for item in contest_problems:
|
||||||
if item.id in state:
|
if item.id in state:
|
||||||
item.ac = state[item.id]
|
if state[item.id]:
|
||||||
|
item.state = 1
|
||||||
|
else:
|
||||||
|
item.state = 2
|
||||||
else:
|
else:
|
||||||
item.ac = 0
|
item.state = 0
|
||||||
|
|
||||||
# 右侧的公告列表
|
# 右侧的公告列表
|
||||||
announcements = Announcement.objects.filter(is_global=True, visible=True).order_by("-create_time")
|
announcements = Announcement.objects.filter(is_global=True, visible=True).order_by("-create_time")
|
||||||
|
|||||||
@@ -73,6 +73,10 @@ li.list-group-item {
|
|||||||
color: green;
|
color: green;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.dealing-flag {
|
||||||
|
color: yellow;
|
||||||
|
}
|
||||||
|
|
||||||
.CodeMirror{
|
.CodeMirror{
|
||||||
min-height: 250px;
|
min-height: 250px;
|
||||||
_height:250px;
|
_height:250px;
|
||||||
|
|||||||
@@ -43,11 +43,11 @@
|
|||||||
<th>
|
<th>
|
||||||
|
|
||||||
<span class="glyphicon
|
<span class="glyphicon
|
||||||
{% if item.ac %}
|
{% if item.state %}
|
||||||
{% ifequal item.ac 1%}
|
{% ifequal item.state 1%}
|
||||||
glyphicon-ok ac-flag
|
glyphicon-ok ac-flag
|
||||||
{% else %}
|
{% else %}
|
||||||
glyphicon-arrow-right ac-flag
|
glyphicon-arrow-right dealing-flag
|
||||||
{% endifequal %}
|
{% endifequal %}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user