课程列表,列表描述内容去掉空格
This commit is contained in:
parent
196501bc39
commit
789f3906a5
|
@ -28,10 +28,10 @@
|
|||
<div class="cl"></div>
|
||||
<li class="ml15">
|
||||
<span class="grayTxt">
|
||||
开课学期: <span><%= current_time_and_term course %></span>
|
||||
创建时间:<%= format_time(course.created_at) %>
|
||||
</span>
|
||||
<span class="grayTxt">
|
||||
创建时间:<%= format_time(course.created_at) %>
|
||||
开课学期: <span><%= current_time_and_term course %></span>
|
||||
</span>
|
||||
<% if User.current.admin? || User.current.allowed_to?(:as_teacher,@course) %>
|
||||
<% homework_num = course.homework_commons.count %>
|
||||
|
|
|
@ -1246,6 +1246,9 @@ function description_showwords_ellipsis(id){
|
|||
str = str + $(this).text();
|
||||
});
|
||||
|
||||
//去掉空格
|
||||
str = str.replace(/\s/gi,'');
|
||||
|
||||
if(str.length > 100){
|
||||
str = str.substring(0,100)+"...";
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue