You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
pgfqe6ch8/app/views/contests/show.html.erb

57 lines
3.5 KiB

<div class="homepageRight mt0 ml10" onmouseover="$('#edit_link').show(); " onmouseout="$('#edit_link').hide();">
<div style="background-color: #fff;">
<div class="contestRightBanner border-bottom">
<div class="NewsBannerName">
竞赛介绍
</div>
<% if User.current.admin_of_contest?(@contest) %>
<%= link_to "编辑", {:controller => 'contests', :action => 'settings', :id => @contest}, :class => "link-blue fr mt5 none", :id => "edit_link" %>
<% end %>
</div>
<div class="cl"></div>
<div>
<% if (@contest.description.nil? || (@contest.description == "" && @contest.attachments.blank?)) && User.current.admin_of_contest?(@contest) %>
<div class="icons_tishi"><img src="../images/sy/icons_tan.png" width="110" height="110" alt="" ></div>
<p class="sy_tab_con_p" style="margin-bottom: 0px; padding-bottom: 100px;">请尽快补充竞赛说明,赢得更多参赛者的青睐吧~</p>
<% elsif (@contest.description.nil? || (@contest.description == "" && @contest.attachments.blank?)) %>
<div class="icons_tishi"><img src="../images/sy/icons_tan.png" width="110" height="110" alt="" ></div>
<p class="sy_tab_con_p" style="margin-bottom: 0px; padding-bottom: 100px;">尚未发布竞赛说明,敬请期待~</p>
<% else %>
<div class="description_div">
<div class="syllabuscon upload_img ke-block break_word" id="syllabus_description_<%= @contest.id %>">
<%= @contest.description.html_safe %>
</div>
<div class="mt10" style="font-weight:normal; font-size: 12px;">
<%= render :partial=>"attachments/activity_attach", :locals=>{:activity => @contest} %>
</div>
</div>
<% end %>
</div>
</div>
<div class="mt10">
<div class="homepageRightBanner">
<div class="NewsBannerName">
<%= get_acts_list_type @type %></div>
<ul class="resourcesSelect">
<li class="resourcesSelected"><a href="javascript:void(0);" class="resourcesIcon"></a>
<ul class="homepagePostType" style="width:90px; left:-80px;">
<li>
<ul class="homepagePostTypeHomework fl">
<li><%= link_to "全部动态", contest_path(@contest), :class =>"homepagePostTypeAll postTypeGrey"%></li>
<li><%= link_to "作品动态", contest_path(@contest, :type => 'work'), :class => "homepagePostTypeAssignment postTypeGrey"%></li>
<li><%= link_to "通知动态", contest_path(@contest, :type => 'news'), :class => "homepagePostTypeNotice postTypeGrey"%></li>
<!--<li><%#= link_to "资源库动态", {:controller => "courses", :action => "show", :type => "attachment"}, :class => "homepagePostTypeResource resourcesGrey"%></li>-->
<li><%= link_to "论坛动态", contest_path(@contest, :type => 'message'), :class => "homepagePostTypeForum postTypeGrey"%></li>
<li><%= link_to "留言动态", contest_path(@contest, :type => 'journalsForMessage'), :class => "homepagePostTypeMessage postTypeGrey"%></li>
<!--<li><%#= link_to "问卷动态", {:controller => "courses", :action => "show", :type => "poll"}, :class => "homepagePostTypeQuiz postTypeGrey"%></li>-->
</ul>
</li>
</ul>
</li>
</ul>
</div>
<%= render :partial => 'contests/contest_activity', :locals => {:contest_activities => @contest_activities,:page => 0,:type => @type} %>
</div>
</div>