|
|
|
@ -17,15 +17,14 @@
|
|
|
|
|
visiable = hidden_non_project && hidden_non_project.value == "0"%>
|
|
|
|
|
<ul class="sub_menu">
|
|
|
|
|
<% if @show_course == 1 && !visiable %>
|
|
|
|
|
<% if User.current.user_extensions && [UserExtensions::TEACHER, UserExtensions::STUDENT].include?(User.current.user_extensions.identity) -%>
|
|
|
|
|
<% hasCourse=false %>
|
|
|
|
|
<% User.current.courses.each do |course| %>
|
|
|
|
|
<% if !course_endTime_timeout?(course) %>
|
|
|
|
|
<% hasCourse=true %>
|
|
|
|
|
<% end %>
|
|
|
|
|
<% hasCourse=false %>
|
|
|
|
|
<% User.current.courses.each do |course| %>
|
|
|
|
|
<% if !course_endTime_timeout?(course) %>
|
|
|
|
|
<% hasCourse=true %>
|
|
|
|
|
<% break %>
|
|
|
|
|
<% end %>
|
|
|
|
|
<%= render :partial => 'layouts/user_courses_list', :locals => {:hasCourse => hasCourse} %>
|
|
|
|
|
<% end -%>
|
|
|
|
|
<% end %>
|
|
|
|
|
<%= render :partial => 'layouts/user_courses_list', :locals => {:hasCourse => hasCourse} %>
|
|
|
|
|
<% end %>
|
|
|
|
|
<%= render :partial => 'layouts/user_project_list', :locals => {:hasCourse => hasCourse} %>
|
|
|
|
|
<li style="white-space: nowrap;overflow: hidden;text-overflow: ellipsis;">
|
|
|
|
|