diff --git a/app/views/courses/_course_activity.html.erb b/app/views/courses/_course_activity.html.erb index aa99236df..b79964a8d 100644 --- a/app/views/courses/_course_activity.html.erb +++ b/app/views/courses/_course_activity.html.erb @@ -68,13 +68,22 @@ } } - function expand_reply_input(id) { - $(id).toggle(); - } - $(function () { init_activity_KindEditor_data(<%= activity.id%>, null, "87%"); showNormalImage('activity_description_<%= activity.id %>'); + if($("#intro_content_<%= activity.id %>").height() > 360) { + $("#intro_content_show_<%= activity.id %>").show(); + } + $("#intro_content_show_<%= activity.id %>").click(function(){ + $("#activity_description_<%= activity.id %>").toggleClass("maxh360"); + $("#intro_content_show_<%= activity.id %>").hide(); + $("#intro_content_hide_<%= activity.id %>").show(); + }); + $("#intro_content_hide_<%= activity.id %>").click(function(){ + $("#activity_description_<%= activity.id %>").toggleClass("maxh360"); + $("#intro_content_hide_<%= activity.id %>").hide(); + $("#intro_content_show_<%= activity.id %>").show(); + }); }); <% if activity && activity.course_act%> diff --git a/app/views/users/_course_homework.html.erb b/app/views/users/_course_homework.html.erb index df42f6ee9..4bde4476d 100644 --- a/app/views/users/_course_homework.html.erb +++ b/app/views/users/_course_homework.html.erb @@ -43,9 +43,15 @@
截止时间:<%= activity.end_time.to_s %>
-
- <%= activity.description.html_safe %> +
+
+ <%= activity.description.html_safe %> +
+
+ + +
<%# if is_teacher%>