在没有“我的课程”菜单项时"我的项目”显示子页显示位置错误的Bug
This commit is contained in:
parent
bbb38d381d
commit
fa90219a52
|
@ -42,15 +42,14 @@
|
|||
<ul class="sub_menu">
|
||||
<% if @show_course == 1 %>
|
||||
<% if User.current.user_extensions && [UserExtensions::TEACHER, UserExtensions::STUDENT].include?(User.current.user_extensions.identity) -%>
|
||||
<% hasCourse=true%>
|
||||
|
||||
<% _bool=false %>
|
||||
<% hasCourse=false %>
|
||||
<% User.current.courses.each do |course| %>
|
||||
<% if !course_endTime_timeout?(course) %>
|
||||
<% _bool=true %>
|
||||
<% hasCourse=true %>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<% if _bool %>
|
||||
<% if hasCourse %>
|
||||
<li id="course_loggedas_li" style="white-space: nowrap;overflow: hidden;text-overflow: ellipsis;"><%=link_to l(:label_my_course), {:controller => 'users', :action => 'user_courses', id: User.current.id} %>
|
||||
<ul class="course_sub_menu">
|
||||
<% User.current.courses.each do |course| %>
|
||||
|
@ -71,7 +70,7 @@
|
|||
<% if hasCourse %>
|
||||
<ul class="project_sub_menu" style="top: 35px">
|
||||
<% else %>
|
||||
<ul class="project_sub_menu">
|
||||
<ul class="project_sub_menu" style="top: 0px">
|
||||
<% end %>
|
||||
<% User.current.projects.each do |project| %>
|
||||
<li><%= link_to project.name.truncate(10, omission: '...'), {:controller => 'projects', :action => 'show',id: project.id, host: Setting.project_domain } %></li>
|
||||
|
|
Loading…
Reference in New Issue