Merge branch 'dev_aliyun' of https://bdgit.educoder.net/Hjqreturn/educoder into dev_aliyun

dev_auth
杨树林 5 years ago
commit 65c92b753d

@ -38,7 +38,7 @@ module CompetitionsHelper
def chart_stages competition
stages = []
statistic_stages = competition.competition_stages.where("score_rate > 0")
if competition.end_time && competition.end_time < Time.now && statistic_stages.size > 1
if competition.max_stage_end_time && competition.max_stage_end_time < Time.now && statistic_stages.size > 1
stages << {id: nil, name: "总排行榜", rate: 1.0, start_time: competition.start_time, end_time: competition.end_time}
end
@ -48,7 +48,7 @@ module CompetitionsHelper
end
end
stages = stages.sort { |a, b| b[:end_time] <=> a[:end_time] } if stages.size > 0
# stages = stages.sort { |a, b| b[:end_time] <=> a[:end_time] } if stages.size > 0
return stages
end
end

@ -78,6 +78,7 @@
font-size:25px;
font-weight:400;
color:rgba(5,16,26,1);
line-height: 30px;
}
.CompetitionCommonbannerfont .competitionbannerdiv:nth-child(2){
@ -394,4 +395,8 @@
.CompetitionCommonbannerfont{
width: 350px !important;
margin-left:10px;
}
.color000{
color: #000;
}

@ -258,12 +258,12 @@ class CompetitionCommon extends Component{
<Col className={data&&data.name.length>15?"competitionbannerdiv mt30":"competitionbannerdiv mt30"}>{data&&data.name}</Col>
<Col className={"competitionbannerdiv"}>
<Col className={"Competitioncolor9b"}>竞赛时间</Col>
<Col>{data&&data.start_time}{data&&data.end_time}</Col>
<Col className={"competitionbannerdiv mt10"}>
<Col className={"Competitioncolor9b"}>竞赛时间<span className={"color000"}>{data&&data.start_time}{data&&data.end_time}</span></Col>
{/*<Col></Col>*/}
</Col>
<Col className={"competitionbannerdiv"}>
<Col className={"competitionbannerdiv mt10"}>
<Row gutter={16}>
<Col className="gutter-row" span={6}>
<div className="gutter-box CompetitionsIndexdadels Competitioncolor77">奖金</div>
@ -309,7 +309,7 @@ class CompetitionCommon extends Component{
`
}
</style>}
<Col className={"competitionbannerdiv mt10"}>
<Col className={"competitionbannerdiv mt20"}>
{data.competition_status==="ended"?
<Button type="primary" block className={"Competitionfontsize22"} disabled={true}>
已结束

Loading…
Cancel
Save