解决个人主页课程为空实训需要点击才出现的问题
This commit is contained in:
parent
5746c26e8e
commit
8d77484ea0
|
|
@ -1,20 +1,24 @@
|
|||
<% @courses.each do |course| %>
|
||||
<p class="clearfix pl10">
|
||||
<a href="<%= course_path(course) %>" target="_blank" class="font-16 first link-color-grey03"><i class="fa fa-circle-o color-orange02 font-12 ml5 mr5" aria-hidden="true"></i><%= course.name %></a>
|
||||
<span class="font-14 hasmargin"><a href="<%= syllabus_path(course.syllabus) %>" target="_blank" class="link-color-grey03"><%= course.syllabus.title %></a></span>
|
||||
<span class="font-14 mr25 color-grey fr"><%= format_time course.updatetime %></span>
|
||||
<span class="font-14 last cl" style="display: none;">分享 <i class="fa fa-weixin font-14 blue" aria-hidden="true"></i></span>
|
||||
</p>
|
||||
<% end %>
|
||||
<% if @course.blank? %>
|
||||
<%= render :partial => "welcome/no_data" %>
|
||||
<% else %>
|
||||
<% @courses.each do |course| %>
|
||||
<p class="clearfix pl10">
|
||||
<a href="<%= course_path(course) %>" target="_blank" class="font-16 first link-color-grey03"><i class="fa fa-circle-o color-orange02 font-12 ml5 mr5" aria-hidden="true"></i><%= course.name %></a>
|
||||
<span class="font-14 hasmargin"><a href="<%= syllabus_path(course.syllabus) %>" target="_blank" class="link-color-grey03"><%= course.syllabus.title %></a></span>
|
||||
<span class="font-14 mr25 color-grey fr"><%= format_time course.updatetime %></span>
|
||||
<span class="font-14 last cl" style="display: none;">分享 <i class="fa fa-weixin font-14 blue" aria-hidden="true"></i></span>
|
||||
</p>
|
||||
<% end %>
|
||||
<%# if @courses_count > 8 %>
|
||||
<!--<a href="<%#= courses_path %>" target="_blank" class="font-16 new_expand">点击查看全部</a>-->
|
||||
<!--<a href="<%#= courses_path %>" target="_blank" class="font-16 new_expand">点击查看全部</a>-->
|
||||
<%# end %>
|
||||
<div class="cl"></div>
|
||||
<div style="text-align:center;" class="new_expand">
|
||||
<div class="pages_right_min" style="width:auto; display:inline-block;margin: 18px 0;">
|
||||
<ul id="homework_pository_ref_pages">
|
||||
<%= pagination_links_full @courses_pages, @courses_count, :per_page_links => false, :remote => @is_remote, :flag => true, :is_new => true %>
|
||||
</ul>
|
||||
<div class="cl"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div style="text-align:center;" class="new_expand">
|
||||
<div class="pages_right_min" style="width:auto; display:inline-block;margin: 18px 0;">
|
||||
<ul id="homework_pository_ref_pages">
|
||||
<%= pagination_links_full @courses_pages, @courses_count, :per_page_links => false, :remote => @is_remote, :flag => true, :is_new => true %>
|
||||
</ul>
|
||||
<div class="cl"></div>
|
||||
</div>
|
||||
</div>
|
||||
<% end %>
|
||||
|
|
|
|||
|
|
@ -1,18 +1,22 @@
|
|||
<% @shixuns.each do |shixun| %>
|
||||
<p class="clearfix pl10">
|
||||
<a href="<%= shixun_path(shixun) %>" target="_blank" class="font-16 first"><i class="fa fa-circle-o color-orange02 font-12 ml5 mr5" aria-hidden="true"></i><%= shixun.name %></a>
|
||||
<span class="font-14 hasmargin"><a href="javascript:void(0);" target="_blank">已解锁第<i><%= had_passed_changllenge_count(shixun) %></i>关/共<i><%= shixun.challenges.count %></i>关</a></span>
|
||||
<span class="font-14 fr mr25 color-grey"><%= format_time shixun.created_at %></span>
|
||||
<span class="font-14 last cl" style="display: none;">分享 <i class="fa fa-weixin font-14 blue" aria-hidden="true"></i></span>
|
||||
</p>
|
||||
<% end %>
|
||||
<% if @shixuns.blank? %>
|
||||
<%= render :partial => "welcome/no_data" %>
|
||||
<% else %>
|
||||
<% @shixuns.each do |shixun| %>
|
||||
<p class="clearfix pl10">
|
||||
<a href="<%= shixun_path(shixun) %>" target="_blank" class="font-16 first"><i class="fa fa-circle-o color-orange02 font-12 ml5 mr5" aria-hidden="true"></i><%= shixun.name %></a>
|
||||
<span class="font-14 hasmargin"><a href="javascript:void(0);" target="_blank">已解锁第<i><%= had_passed_changllenge_count(shixun) %></i>关/共<i><%= shixun.challenges.count %></i>关</a></span>
|
||||
<span class="font-14 fr mr25 color-grey"><%= format_time shixun.created_at %></span>
|
||||
<span class="font-14 last cl" style="display: none;">分享 <i class="fa fa-weixin font-14 blue" aria-hidden="true"></i></span>
|
||||
</p>
|
||||
<% end %>
|
||||
|
||||
<div class="cl"></div>
|
||||
<div style="text-align:center;" class="new_expand">
|
||||
<div class="pages_right_min" style="width:auto; display:inline-block;margin: 18px 0;">
|
||||
<ul id="homework_pository_ref_pages">
|
||||
<%= pagination_links_full @shixuns_pages, @shixuns_count, :per_page_links => false, :remote => @is_remote, :flag => true, :is_new => true %>
|
||||
</ul>
|
||||
<div class="cl"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div style="text-align:center;" class="new_expand">
|
||||
<div class="pages_right_min" style="width:auto; display:inline-block;margin: 18px 0;">
|
||||
<ul id="homework_pository_ref_pages">
|
||||
<%= pagination_links_full @shixuns_pages, @shixuns_count, :per_page_links => false, :remote => @is_remote, :flag => true, :is_new => true %>
|
||||
</ul>
|
||||
<div class="cl"></div>
|
||||
</div>
|
||||
</div>
|
||||
<% end %>
|
||||
|
|
|
|||
|
|
@ -193,22 +193,12 @@
|
|||
<div class="hascon">
|
||||
<% str = current_user ? '' : 'TA的' %>
|
||||
<ul id="edu-tab-nav">
|
||||
<% if @courses_count == 0 %>
|
||||
<li id="my_shixuns_span" class="font-16 edu-new-tab-hover new-tab-nav">
|
||||
<a href="javascript:void(0);" class="tab_type">实训 <em id="follow"><%= @shixuns_count %></em></a>
|
||||
</li>
|
||||
<% elsif @shixuns_count == 0 %>
|
||||
<li id="my_courses_span" class="font-16 edu-new-tab-hover new-tab-nav">
|
||||
<a href="javascript:void(0);" class="tab_type">课堂 <em id="follow"><%= @courses_count %></em></a>
|
||||
</li>
|
||||
<% else %>
|
||||
<li id="my_courses_span" class="font-16 edu-new-tab-hover new-tab-nav">
|
||||
<a href="javascript:void(0);" class="tab_type">课堂 <em id="follow"><%= @courses_count %></em></a>
|
||||
</li>
|
||||
<li id="my_shixuns_span" class="font-16 new-tab-nav bold">
|
||||
<a href="javascript:void(0);" class="tab_type">实训 <em id="follow"><%= @shixuns_count %></em></a>
|
||||
</li>
|
||||
<% end %>
|
||||
<li id="my_courses_span" class="font-16 edu-new-tab-hover new-tab-nav">
|
||||
<a href="javascript:void(0);" class="tab_type">课堂 <em id="follow"><%= @courses_count %></em></a>
|
||||
</li>
|
||||
<li id="my_shixuns_span" class="font-16 new-tab-nav bold">
|
||||
<a href="javascript:void(0);" class="tab_type">实训 <em id="follow"><%= @shixuns_count %></em></a>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<div class="lesson clearfix" id="my_courses_list">
|
||||
|
|
|
|||
Loading…
Reference in New Issue