课程列表中:点击课程的名称就弹出新的tab页,进入课程的页面

This commit is contained in:
cxt 2016-09-05 16:20:38 +08:00
parent ad0acb5188
commit 7123c66481
2 changed files with 4 additions and 4 deletions

View File

@ -19,10 +19,10 @@
<% syllabuses.each_with_index do |syllabus, index|%>
<div class="syllabus_courses_box">
<% course_count = syllabus.courses.not_deleted.count %>
<div class="syllabus_courses_list" onclick="expand_courses(<%=syllabus.id %>,<%=course_count %>);" id="syllabus_courses_list_<%= syllabus.id %>">
<div class="syllabus_courses_list" id="syllabus_courses_list_<%= syllabus.id %>">
<div class="<%=index == 0 ? 'sy_courses_open' : 'sy_courses_close' %>">
<span class="<%=index == 0 && course_count != 0 ? 'icons_sy_open' : 'icons_sy_close' %> fl mr5"></span>
<h3 class="syllabus_courses_title fl"><%=syllabus.title %></h3>
<span onclick="expand_courses(<%=syllabus.id %>,<%=course_count %>);" class="<%=index == 0 && course_count != 0 ? 'icons_sy_open' : 'icons_sy_close' %> fl mr5" title="点击展开/收起班级列表"></span>
<%=link_to syllabus.title, syllabus_path(syllabus.id), :class => 'syllabus_courses_title fl', :target => '_blank' %>
</div>
<p class="fl sy_p_grey">更新时间:<%=format_date syllabus.updated_at %>
<span class="mr10"></span>创建老师:<%=syllabus.user.show_name %>

View File

@ -88,7 +88,7 @@ input.syllabus_input_min{
.syllabus_box{ width:750px; border:1px solid #e7e7e7; background-color:#fff;}
.syllabus_courses_list{ padding:15px; border-bottom:1px solid #e7e7e7; cursor:pointer;}
.syllabus_courses_list:hover{ background:#f6fafd;}
.syllabus_courses_title{ font-size:16px; color:#333; width:650px; font-weight:normal;white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.syllabus_courses_title{ font-size:16px; color:#333 !important; width:650px; font-weight:normal;white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.sy_p_grey{ margin-left:25px; color:#888; margin-top:5px; font-size:12px;}
.syllabus_class_box{ padding-left:43px; background:#f6f6f6;}
.syllabus_class_list{ padding:12px 0 12px 15px; height:44px;border-left:1px solid #e7e7e7;border-bottom:1px solid #e7e7e7; position:relative;}