From 5eff3db9e877e874589d6c936089937cb2950c85 Mon Sep 17 00:00:00 2001
From: yuanke <249218296@qq.com>
Date: Mon, 23 May 2016 15:58:32 +0800
Subject: [PATCH] =?UTF-8?q?1.=E9=97=AE=E7=AD=94=E5=8C=BA=E6=97=B6=E9=97=B4?=
=?UTF-8?q?=E6=8E=92=E5=BA=8FBUG=E4=BF=AE=E5=A4=8D=E3=80=81=E5=8F=AA?=
=?UTF-8?q?=E6=98=BE=E7=A4=BA=E6=9B=B4=E6=96=B0=E6=97=B6=E9=97=B4=E3=80=81?=
=?UTF-8?q?=E5=8F=91=E8=B4=B4=E4=BA=BA=E6=94=BE=E5=B7=A6=E4=B8=8B=E8=A7=92?=
=?UTF-8?q?=E3=80=81=E5=86=85=E5=AE=B9=E6=88=AA=E6=96=AD=E4=B8=80=E7=82=B9?=
=?UTF-8?q?=202.KE=E7=BC=96=E8=BE=91=E5=99=A8=E8=BE=93=E5=85=A5=E5=86=85?=
=?UTF-8?q?=E5=AE=B9=E6=97=B6=E9=9C=80=E6=9C=89=E4=B8=80=E7=82=B9=E4=B8=8B?=
=?UTF-8?q?=E8=BE=B9=E8=B7=9D=203.KE=E4=B8=AD=E7=BC=96=E8=BE=91=E4=BD=BF?=
=?UTF-8?q?=E7=94=A8=E6=AE=B5=E8=90=BD=E6=98=BE=E7=A4=BA=E6=97=B6=E6=9C=89?=
=?UTF-8?q?=E9=A2=9C=E8=89=B2=E7=9A=84=E9=97=AE=E9=A2=98?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../_org_subfield_leftMD.html.erb | 20 +++++++++----------
app/views/users/_course_boardlist.html.erb | 11 +++++-----
app/views/users/_course_newslist.html.erb | 9 ++++-----
app/views/users/_intro_content_ex.html.erb | 5 +++++
app/views/users/_project_boardlist.html.erb | 11 +++++-----
app/views/users/_user_course_list.html.erb | 2 +-
public/javascripts/create_kindeditor.js | 2 +-
public/stylesheets/public.css | 8 ++++----
public/stylesheets/public_new.css | 6 +++---
9 files changed, 38 insertions(+), 36 deletions(-)
diff --git a/app/views/organizations/_org_subfield_leftMD.html.erb b/app/views/organizations/_org_subfield_leftMD.html.erb
index d0439439a..afa7d0716 100644
--- a/app/views/organizations/_org_subfield_leftMD.html.erb
+++ b/app/views/organizations/_org_subfield_leftMD.html.erb
@@ -28,7 +28,7 @@
<%= link_to activity.name.to_s, student_work_index_url_in_org(activity.id), :target => '_blank', :class => "resources-title sn-hidden" %>
- <%=render :partial =>"users/intro_content_ex", :locals=>{:user_activity_id => activity.id, :content=> activity.description, :maxheight=>54, :maxwordsnum => 28} %>
+ <%=render :partial =>"users/intro_content_ex", :locals=>{:user_activity_id => activity.id, :content=> activity.description, :maxheight=>54, :maxwordsnum => 28, :maxwidth=>0} %>
<%#= link_to activity.description.to_s.html_safe, student_work_index_url_in_org(activity.id), :target => '_blank', :class => "resources-tag" %>
<%#= link_to "更多", student_work_index_url_in_org(activity.id), :class => "more-btn", :target => "_blank" %>
@@ -50,7 +50,7 @@
<% end %>
- <%=render :partial =>"users/intro_content_ex", :locals=>{:user_activity_id => activity.id, :content=> activity.content, :maxheight=>54, :maxwordsnum => 28} %>
+ <%=render :partial =>"users/intro_content_ex", :locals=>{:user_activity_id => activity.id, :content=> activity.content, :maxheight=>54, :maxwordsnum => 28, :maxwidth=>0} %>
<%#= link_to activity.content.to_s.html_safe, board_message_url_in_org(activity.board_id, activity.id), :target => '_blank', :class => "resources-tag" %>
@@ -67,7 +67,7 @@
<%= link_to activity.title.to_s, news_url_in_org(activity.id), :target => '_blank', :class => "resources-title sn-hidden" %>
- <%=render :partial =>"users/intro_content_ex", :locals=>{:user_activity_id => activity.id, :content=> activity.description, :maxheight=>54, :maxwordsnum => 28} %>
+ <%=render :partial =>"users/intro_content_ex", :locals=>{:user_activity_id => activity.id, :content=> activity.description, :maxheight=>54, :maxwordsnum => 28, :maxwidth=>0} %>
<%#= link_to activity.description.to_s.html_safe, news_url_in_org(activity.id), :target => '_blank', :class => "resources-tag" %>
<%#= link_to "更多", news_url_in_org(activity.id), :class => "more-btn", :target => "_blank" %>
@@ -130,7 +130,7 @@
<%= link_to activity.subject.to_s, issue_url_in_org(activity.id), :target => '_blank', :class => "resources-title sn-hidden" %>
- <%=render :partial =>"users/intro_content_ex", :locals=>{:user_activity_id => activity.id, :content=> activity.description, :maxheight=>54, :maxwordsnum => 28} %>
+ <%=render :partial =>"users/intro_content_ex", :locals=>{:user_activity_id => activity.id, :content=> activity.description, :maxheight=>54, :maxwordsnum => 28, :maxwidth=>0} %>
<%#= link_to activity.description.to_s.html_safe, issue_url_in_org(activity.id), :target => '_blank', :class => "resources-tag" %>
@@ -151,7 +151,7 @@
<% end %>
- <%=render :partial =>"users/intro_content_ex", :locals=>{:user_activity_id => activity.id, :content=> activity.content, :maxheight=>54, :maxwordsnum => 28} %>
+ <%=render :partial =>"users/intro_content_ex", :locals=>{:user_activity_id => activity.id, :content=> activity.content, :maxheight=>54, :maxwordsnum => 28, :maxwidth=>0} %>
<%#= link_to activity.content.to_s.html_safe, board_message_url_in_org(activity.board_id, activity.id), :target => '_blank', :class => "resources-tag" %>
@@ -168,7 +168,7 @@
<%= link_to activity.description.to_s.html_safe, news_url_in_org(activity.id), :target => '_blank', :class => "resources-title sn-hidden" %>
- <%=render :partial =>"users/intro_content_ex", :locals=>{:user_activity_id => activity.id, :content=> activity.description, :maxheight=>54, :maxwordsnum => 28} %>
+ <%=render :partial =>"users/intro_content_ex", :locals=>{:user_activity_id => activity.id, :content=> activity.description, :maxheight=>54, :maxwordsnum => 28, :maxwidth=>0} %>
<%#= link_to activity.content.to_s.html_safe, news_url_in_org(activity.id), :target => '_blank', :class => "resources-tag" %>
<%#= link_to "更多", news_url_in_org(activity.id), :class => "more-btn", :target => "_blank" %>
@@ -214,7 +214,7 @@
<%= link_to document.title, org_document_comment_path(:id => document.id, :organization_id => document.organization.id), :target => '_blank', :class => "resources-title sn-hidden" %>
- <%=render :partial =>"users/intro_content_ex", :locals=>{:user_activity_id => document.id, :content=> document.content, :maxheight=>54, :maxwordsnum => 28} %>
+ <%=render :partial =>"users/intro_content_ex", :locals=>{:user_activity_id => document.id, :content=> document.content, :maxheight=>54, :maxwordsnum => 28, :maxwidth=>0} %>
<%#= link_to document.content.to_s.html_safe, org_document_comment_path(:id => document.id, :organization_id => document.organization.id), :target => '_blank', :class => "resources-tag" %>
<%#= link_to "更多", org_document_comment_path(:id => document.id, :organization_id => document.organization.id), :class => "more-btn", :target => "_blank" %>
@@ -244,7 +244,7 @@
<% end %>
- <%= render :partial =>"users/intro_content_ex", :locals=>{:user_activity_id => message.id, :content=> content, :maxheight=>54, :maxwordsnum => 28} %>
+ <%= render :partial =>"users/intro_content_ex", :locals=>{:user_activity_id => message.id, :content=> content, :maxheight=>54, :maxwordsnum => 28, :maxwidth=>0} %>
<%#= link_to content.to_s.html_safe, board_message_url_in_org(activity.board_id, activity.id), :target => '_blank', :class => "resources-tag" %>
<%#= link_to "更多", board_message_url_in_org(message.board.id,message.id), :class => "more-btn", :target => "_blank" %>
@@ -264,7 +264,7 @@
<% end %>
- <%= render :partial =>"users/intro_content_ex", :locals=>{:user_activity_id => message.id, :content=> content, :maxheight=>54, :maxwordsnum => 28} %>
+ <%= render :partial =>"users/intro_content_ex", :locals=>{:user_activity_id => message.id, :content=> content, :maxheight=>54, :maxwordsnum => 28, :maxwidth=>0} %>
<%#= link_to content.to_s.html_safe, board_message_path(message.board,activity), :target => '_blank', :class => "resources-tag" %>
<%#= link_to "更多", board_message_path(message.board,activity), :class => "more-btn", :target => "_blank" %>
@@ -285,7 +285,7 @@
<%#= link_to news.description.to_s.html_safe, news_path(news), :target => '_blank', :class => "resources-tag" %>
- <%= render :partial =>"users/intro_content_ex", :locals=>{:user_activity_id => news.id, :content=> news.description, :maxheight=>54, :maxwordsnum => 28, :maxwordsnum => 28} %>
+ <%= render :partial =>"users/intro_content_ex", :locals=>{:user_activity_id => news.id, :content=> news.description, :maxheight=>54, :maxwordsnum => 28, :maxwordsnum => 28, :maxwidth=>0} %>
<%#= link_to "更多", news_path(news), :class => "more-btn", :target => "_blank" %>
diff --git a/app/views/users/_course_boardlist.html.erb b/app/views/users/_course_boardlist.html.erb
index bf23d9a97..5cb2c27a7 100644
--- a/app/views/users/_course_boardlist.html.erb
+++ b/app/views/users/_course_boardlist.html.erb
@@ -31,9 +31,6 @@
锁
<% end %>
<% u = User.where("id=?",activity.author_id).first%>
-
- 发帖人: <%=(u.try(:realname) != " " ? u.lastname + u.firstname : u.try(:login)) %>
-
@@ -42,11 +39,13 @@
<% else %>
<% content = activity.parent.content %>
<% end %>
-
<%=render :partial =>"users/intro_content_ex", :locals=>{:user_activity_id =>activity.id, :content=>content, :maxheight=>54, :maxwordsnum=>100} %>
+
<%=render :partial =>"users/intro_content_ex", :locals=>{:user_activity_id =>activity.id, :content=>content, :maxheight=>54, :maxwordsnum=>75, :maxwidth=>563} %>
-
发帖:<%= format_time(activity.created_on) %>
-
更新:<%= format_time(CourseActivity.where("course_act_type='#{activity.class}' and course_act_id =#{activity.id}").first.updated_at) %>
+
+ 发帖人: <%=(u.try(:realname) != " " ? u.lastname + u.firstname : u.try(:login)) %>
+
+
更新:<%= format_time(activity.children.any? ? activity.children.last[:created_on] : activity[:created_on] ) %>
<% count=0 %>
<% if activity.parent %>
<% count=activity.parent.children.count%>
diff --git a/app/views/users/_course_newslist.html.erb b/app/views/users/_course_newslist.html.erb
index 0e5805112..87dbe6b95 100644
--- a/app/views/users/_course_newslist.html.erb
+++ b/app/views/users/_course_newslist.html.erb
@@ -24,16 +24,15 @@
顶
<% end%>
<% u = User.where("id=?",activity.author_id).first%>
-
- 发布者: <%=(u.try(:realname) != " " ? u.lastname + u.firstname : u.try(:login)) %>
-
-
<%=render :partial =>"users/intro_content_ex", :locals=>{:user_activity_id =>activity.id, :content=>activity.description, :maxheight=>54, :maxwordsnum=>100} %>
+
<%=render :partial =>"users/intro_content_ex", :locals=>{:user_activity_id =>activity.id, :content=>activity.description, :maxheight=>54, :maxwordsnum=>100, :maxwidth=>563} %>
-
发布:<%= format_time(activity.created_on) %>
+
+ 发布者: <%=(u.try(:realname) != " " ? u.lastname + u.firstname : u.try(:login)) %>
+
更新:<%= format_time(CourseActivity.where("course_act_type='#{activity.class}' and course_act_id =#{activity.id}").first.updated_at) %>
<% count=0 %>
<% count=activity.comments.count %>
diff --git a/app/views/users/_intro_content_ex.html.erb b/app/views/users/_intro_content_ex.html.erb
index e3baf3fe2..082d0cb94 100644
--- a/app/views/users/_intro_content_ex.html.erb
+++ b/app/views/users/_intro_content_ex.html.erb
@@ -12,6 +12,11 @@
$("#activity_description_<%= user_activity_id%>").css("max-height", heightType + "px");
}
+ var maxWidth = <%= maxwidth %>
+ if (maxWidth > 0) {
+ $("#intro_content_<%= user_activity_id%>").css("max-width", maxWidth + "px");
+ }
+
description_showwords_ellipsis(<%=user_activity_id %>,<%= maxwordsnum %>);
});
\ No newline at end of file
diff --git a/app/views/users/_project_boardlist.html.erb b/app/views/users/_project_boardlist.html.erb
index 25fd675fb..fe7bc03f2 100644
--- a/app/views/users/_project_boardlist.html.erb
+++ b/app/views/users/_project_boardlist.html.erb
@@ -31,9 +31,6 @@
锁
<% end %>
<% u = User.where("id=?",activity.author_id).first%>
-
- 发帖人:<%=(u.try(:realname) != " " ? u.lastname + u.firstname : u.try(:login)) %>
-
@@ -42,11 +39,13 @@
<% else %>
<% content = activity.parent.content %>
<% end %>
-
<%=render :partial =>"users/intro_content_ex", :locals=>{:user_activity_id =>activity.id, :content=>content, :maxheight=>54, :maxwordsnum=>100} %>
+
<%=render :partial =>"users/intro_content_ex", :locals=>{:user_activity_id =>activity.id, :content=>content, :maxheight=>54, :maxwordsnum=>75, :maxwidth=>563} %>
-
发帖:<%= format_time(activity.created_on) %>
-
更新:<%= format_time(ForgeActivity.where("forge_act_type='#{activity.class}' and forge_act_id =#{activity.id}").first.updated_at) %>
+
+ 发帖人:<%=(u.try(:realname) != " " ? u.lastname + u.firstname : u.try(:login)) %>
+
+
更新:<%= format_time(activity.children.any? ? activity.children.last[:created_on] : activity[:created_on] ) %>
<% count=0 %>
<% if activity.parent %>
<% count=activity.parent.children.count%>
diff --git a/app/views/users/_user_course_list.html.erb b/app/views/users/_user_course_list.html.erb
index 5e3f48963..ea8f3fc40 100644
--- a/app/views/users/_user_course_list.html.erb
+++ b/app/views/users/_user_course_list.html.erb
@@ -24,7 +24,7 @@
<% teacher = User.where("id=?",course.tea_id).first%>
<%='主讲老师:'+(teacher.try(:realname) != " " ? teacher.lastname + teacher.firstname : teacher.try(:login)) %>
-
+
diff --git a/public/javascripts/create_kindeditor.js b/public/javascripts/create_kindeditor.js
index 2ff5336e1..d6fc52a8d 100644
--- a/public/javascripts/create_kindeditor.js
+++ b/public/javascripts/create_kindeditor.js
@@ -25,7 +25,7 @@ function sd_create_editor(params){
var edit = this.edit;
var body = edit.doc.body;
edit.iframe.height(paramsHeight);
- this.resize(null, Math.max((params.kindutil.IE ? body.scrollHeight : (params.kindutil.GECKO ? body.offsetHeight+26:body.offsetHeight)) , paramsHeight));
+ this.resize(null, Math.max((params.kindutil.IE ? body.scrollHeight : (params.kindutil.GECKO ? body.offsetHeight+26:body.offsetHeight+7)) , paramsHeight));
},
afterBlur:function(){
//params.toolbar_container.hide();
diff --git a/public/stylesheets/public.css b/public/stylesheets/public.css
index 2ca221d5c..c7fa7d60c 100644
--- a/public/stylesheets/public.css
+++ b/public/stylesheets/public.css
@@ -24,9 +24,9 @@ table{ background:#fff;}
a.btn_message_free{ background:#ff5722; display:block; text-align:center; color:#fff; padding:3px 0; width:80px; margin-bottom:10px;}
.db {display:block;}
/* font & color */
-h2{ font-size:18px; color:#15bccf;}
-h3{ font-size:14px; color:#e8770d;}
-h4{ font-size:14px; color:#3b3b3b;}
+h2{ font-size:18px; }
+h3{ font-size:14px; }
+h4{ font-size:14px; }
.f12{font-size:12px; font-weight:normal;}
.f14{font-size:14px;}
.f16{font-size:16px;}
@@ -1139,4 +1139,4 @@ a.st_down{ display: block; width:8px; float:left; height:13px; background:url(..
.likeNum{color: #7f7f7f}
/*弹框*/
-.apply_content{ border:1px solid #ddd;line-height: 16px; height:80px;width:420px; background:#fff; margin-bottom:10px;}
+.apply_content{ border:1px solid #ddd;line-height: 16px; height:80px;width:420px; background:#fff; margin-bottom:10px;}
diff --git a/public/stylesheets/public_new.css b/public/stylesheets/public_new.css
index 56c867829..ec0290918 100644
--- a/public/stylesheets/public_new.css
+++ b/public/stylesheets/public_new.css
@@ -22,9 +22,9 @@ table{ background:#fff;}
.none{display: none;}
/* font & color */
-h2{ font-size:18px; color:#15bccf;}
-h3{ font-size:14px; color:#e8770d;}
-h4{ font-size:14px; color:#3b3b3b;}
+h2{ font-size:18px; }
+h3{ font-size:14px; }
+h4{ font-size:14px; }
.f12{font-size:12px; font-weight:normal;}
.f14{font-size:14px;}
.f16{font-size:16px;}