Merge branches 'educoder' and 'project_pack' of https://bdgit.educoder.net/Hjqreturn/pgfqe6ch8 into project_pack

project_pack
杨树明 5 years ago
commit 0ef90fd228

@ -21,10 +21,44 @@
<a href="<%= is_start ? first_section.competition_entries[1].url : 'javascript:void(0)'%>" <a href="<%= is_start ? first_section.competition_entries[1].url : 'javascript:void(0)'%>"
class="<%= is_start ? 'active' : '' %>" target="_blank"><%= first_section.competition_entries[1].name %></a> class="<%= is_start ? 'active' : '' %>" target="_blank"><%= first_section.competition_entries[1].name %></a>
</div> </div>
<!--<a href="<%#= is_start ? first_section.competition_entries[2].url : 'javascript:void(0)'%>"--> <li class="inline">
<!--class="ex_submit"><%#= first_section.competition_entries[2].name %></a>--> <a href="<%= is_start ? first_section.competition_entries[2].url : 'javascript:void(0)'%>"
class="ex_submit"><%= first_section.competition_entries[2].name %></a>
<a href="javascript:void(0)" class="ex_submit team-btn"><%= first_section.competition_entries[3].name %></a>
</li>
</div> </div>
</div> </div>
<% index += 1 %> <% index += 1 %>
<p class="second_course_6" style="background: url('<%= named_attachment_path(@images[index], @images[index].try(:filename)) %>') no-repeat top center;"></p> <p class="second_course_6" style="background: url('<%= named_attachment_path(@images[index], @images[index].try(:filename)) %>') no-repeat top center;"></p>
<script>
$(function(){
var userLogged = <%= @user.present? && @user.logged? %>;
var userEnrolled = <%= @enrolled %>;
$(".team-btn").on("click", function(){
if (!userLogged) {
location.href = "<%= signin_url(back_url: competition_path(id: params[:id])) %>";
return;
}
if (!userEnrolled) {
toEnrollDetail();
return;
}
var teamId = "<%= @competition.team_members.find_by_user_id(@user.id).try(:competition_team_id) %>";
location.href = "<%= competition_teams_path %>/" + teamId;
})
})
function toEnrollDetail(){
var htmlvalue = '<div class="task-popup" style="width:500px;"><div class="task-popup-title clearfix">提示</div>'+
'<div class="task-popup-content"><p class="task-popup-text-center font-16">完成报名后即可查看</p></div>' +
'<div class="task-popup-submit clearfix"><a href="javascript:void(0);" onclick="hideModal();" class="task-btn fl">取消</a>'+
'<a href="<%= enroll_competition_path(id: params[:id]) %>" class="task-btn task-btn-orange fr">立即报名</a></div></div>';
pop_box_new(htmlvalue, 500, 205);
}
</script>

@ -75,7 +75,7 @@
<a href="<%= url %>" class="competition-Img"> <a href="<%= url %>" class="competition-Img">
<%= image_tag(url_to_avatar(competition), :width => "100%", :height => "100%") %> <%= image_tag(url_to_avatar(competition), :width => "100%", :height => "100%") %>
</a> </a>
<div class="pt30 pb30 pl20 mb10 clearfix"> <div class="pt30 pb30 pl20 mt2 clearfix">
<a href="<%= url %>" style="max-width: 400px;" class="font-16 task-hide fl"><%= [competition.name, competition.sub_title.presence].compact.join('——') %></a> <a href="<%= url %>" style="max-width: 400px;" class="font-16 task-hide fl"><%= [competition.name, competition.sub_title.presence].compact.join('——') %></a>
<div class="fr status-orange"> <div class="fr status-orange">
<img src="/images/educoder/competition/home/orange.png" class="fl"> <img src="/images/educoder/competition/home/orange.png" class="fl">

@ -2,7 +2,7 @@
"http://www.w3.org/TR/html4/loose.dtd"> "http://www.w3.org/TR/html4/loose.dtd">
<html> <html>
<head> <head>
<title>Trustie 500 error</title> <title>EduCoder 500 error</title>
<link type="text/css" rel="stylesheet" href="/stylesheets/educoder/edu-main.css" /> <link type="text/css" rel="stylesheet" href="/stylesheets/educoder/edu-main.css" />
<link href="//at.alicdn.com/t/font_653600_rr8l5v2aaym.css" rel="stylesheet" type="text/css"/> <link href="//at.alicdn.com/t/font_653600_rr8l5v2aaym.css" rel="stylesheet" type="text/css"/>
<script src="/javascripts/jquery-1.8.3-ui-1.9.2-ujs-2.0.3.js"></script> <script src="/javascripts/jquery-1.8.3-ui-1.9.2-ujs-2.0.3.js"></script>

@ -650,7 +650,7 @@ a.enterLink{cursor: pointer;color: #418CCD!important;background: none!important;
.second_4{min-height: 610px;padding-top: 190px;box-sizing: border-box;position: relative} .second_4{min-height: 610px;padding-top: 190px;box-sizing: border-box;position: relative}
.second_5{min-height: 617px;padding-top: 190px;box-sizing: border-box;position: relative} .second_5{min-height: 617px;padding-top: 190px;box-sizing: border-box;position: relative}
.second_6{min-height: 1053px;} .second_6{min-height: 1053px;}
.second_7{min-height: 1096px;} .second_7{min-height: 1078px;}
.second_8{min-height: 727px;} .second_8{min-height: 727px;}
/*代码标注*/ /*代码标注*/
@ -723,11 +723,11 @@ li.challenge_box:last-child{
.second_course_2{min-height: 823px;} .second_course_2{min-height: 823px;}
.second_course_3{min-height: 690px;} .second_course_3{min-height: 690px;}
.second_course_4{min-height: 514px;} .second_course_4{min-height: 514px;}
.second_course_5{min-height: 627px;padding-top: 190px;box-sizing: border-box;position: relative} .second_course_5{min-height: 657px;padding-top: 190px;box-sizing: border-box;position: relative}
.second_course_6{min-height: 1225px;} .second_course_6{min-height: 1199px;}
.course_competition_panel{ .course_competition_panel{
margin:30px 40px 40px;border:1px solid #ABDCF1;background: #F1F8FD;justify-content: center;align-items: center;display: -webkit-flex; margin:30px 40px 40px;border:1px solid #ABDCF1;background: #F1F8FD;justify-content: center;align-items: center;display: -webkit-flex;
height: 282px;text-align: center; height: 220px;text-align: center;
} }
.course_competition_panel a{ .course_competition_panel a{
width: 320px;height: 60px;line-height: 60px;float: left;margin:0px 100px;background: #ccc;color: #fff!important; width: 320px;height: 60px;line-height: 60px;float: left;margin:0px 100px;background: #ccc;color: #fff!important;
@ -737,8 +737,8 @@ li.challenge_box:last-child{
background: #47B6FC; background: #47B6FC;
} }
.ex_submit{ .ex_submit{
width: 360px;height: 70px;background: #2CDAD4;color: #fff!important;font-size: 30px;line-height: 70px;text-align: center; width: 250px;height: 60px;background: #2CDAD4;color: #fff!important;font-size: 22px;line-height: 60px;text-align: center;
margin:0px auto;display: block; margin:0px auto;display: block;float: left;margin:0px 35px;
} }
table.tBodyScroll tbody tr td{ table.tBodyScroll tbody tr td{
padding:6px 5px;box-sizing: border-box;font-size: 16px;color: #05101A;font-weight: normal; padding:6px 5px;box-sizing: border-box;font-size: 16px;color: #05101A;font-weight: normal;

Loading…
Cancel
Save