diff --git a/app/views/issues/_jounal_refresh.js.erb b/app/views/issues/_jounal_refresh.js.erb index df3d605f4..db5a068bf 100644 --- a/app/views/issues/_jounal_refresh.js.erb +++ b/app/views/issues/_jounal_refresh.js.erb @@ -1,8 +1,5 @@ -$("#reply_div_<%= @issue.id %>").html("<%= escape_javascript(render :partial => 'issues/issue_replies', :locals => {:issue => @issue}) %>"); -$("#issue_detail_show").html('<%= escape_javascript(render :partial => 'issues/detail') %>') -$("#issue_edit_show").html('<%= escape_javascript(render :partial => 'issues/edit') %>') -$("#div_issue_attachment_<%=@issue.id %>").html("<%= escape_javascript(render :partial => 'issues/issue_attachments', :locals => {:issue => @issue}) %>"); -sd_create_editor_from_data(<%= @issue.id %>, null, "100%", "<%= @issue.class.name %>"); + +location.reload(); issue_desc_editor = KindEditor.create('#issue_description', {"width":"85%", "resizeType":0, @@ -17,5 +14,3 @@ issue_desc_editor = KindEditor.create('#issue_description', "uploadJson":"/kindeditor/upload", "fileManagerJson":"/kindeditor/filemanager"}); // $("#issue_test_<%#= @issue.id %>").html("<%#= escape_javascript(render :partial => 'issues/edit', :locals => {:issue => Issue.find( @issue_id)}) %>"); -$(".homepagePostReplyBannerCount").html('<%= escape_javascript(render :partial => 'issues/issue_reply_banner') %>'); -sd_create_editor_from_data(<%= @issue.id%>, null, "100%","<%= @issue.class.name %>"); \ No newline at end of file diff --git a/app/views/layouts/_show_messages_list.html.erb b/app/views/layouts/_show_messages_list.html.erb index 584970f16..2d6da0770 100644 --- a/app/views/layouts/_show_messages_list.html.erb +++ b/app/views/layouts/_show_messages_list.html.erb @@ -138,7 +138,7 @@
  • <%=ma.forge_message.author.show_name %> 评论了新闻:<%= ma.forge_message.commented.title%>
  • <% end %> <% elsif ma.class == MemoMessage %> - <% if ma.memo_type == "Memo" %> + <% if ma.memo_type == "Memo" && !ma.memo.nil? && !ma.memo.author.nil? %>
  • <%= ma.memo.parent_id.nil? ? ma.memo.subject : message_content(ma.memo.content)%>"><%=ma.memo.author.show_name %> <%= ma.memo.parent_id.nil? ? "在贴吧发布帖子:" : "回复了贴吧帖子:" %><%= ma.memo.parent_id.nil? ? ma.memo.subject : message_content(ma.memo.content)%>
  • <% end %> <% elsif ma.class == UserFeedbackMessage %> diff --git a/app/views/users/_user_message_forum.html.erb b/app/views/users/_user_message_forum.html.erb index 4544fd651..5d6c5bcad 100644 --- a/app/views/users/_user_message_forum.html.erb +++ b/app/views/users/_user_message_forum.html.erb @@ -1,5 +1,5 @@ <% if ma.class == MemoMessage %> - <% if ma.memo_type == "Memo" && ma.memo %> + <% if ma.memo_type == "Memo" && !ma.memo.nil? && !ma.memo.author.nil? %>