From 1b389586ad4531cb153137d9eb551bcacbdc5288 Mon Sep 17 00:00:00 2001 From: yanxd Date: Sat, 28 Dec 2013 12:16:08 +0800 Subject: [PATCH] =?UTF-8?q?=E7=95=99=E8=A8=80=E5=9B=9E=E5=A4=8D=E4=BA=BA?= =?UTF-8?q?=E9=94=99=E8=AF=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/models/journal_observer.rb | 4 ++-- app/views/words/_journal_reply.html.erb | 2 +- app/views/words/_journal_reply_items.html.erb | 2 +- app/views/words/_message.html.erb | 2 +- app/views/words/_new_respond.html.erb | 4 ++-- app/views/words/create_reply.js.erb | 2 +- 6 files changed, 8 insertions(+), 8 deletions(-) diff --git a/app/models/journal_observer.rb b/app/models/journal_observer.rb index 29a754ff..0357fb74 100644 --- a/app/models/journal_observer.rb +++ b/app/models/journal_observer.rb @@ -23,9 +23,9 @@ class JournalObserver < ActiveRecord::Observer (Setting.notified_events.include?('issue_status_updated') && journal.new_status.present?) || (Setting.notified_events.include?('issue_priority_updated') && journal.new_value_for('priority_id').present?) ) - # Thread.new do + Thread.new do Mailer.issue_edit(journal).deliver - # end + end end end end diff --git a/app/views/words/_journal_reply.html.erb b/app/views/words/_journal_reply.html.erb index 1249c9cb..6f87443c 100644 --- a/app/views/words/_journal_reply.html.erb +++ b/app/views/words/_journal_reply.html.erb @@ -2,6 +2,6 @@ <% id = "journal_reply_ul_" + journal.id.to_s%> diff --git a/app/views/words/_journal_reply_items.html.erb b/app/views/words/_journal_reply_items.html.erb index 9408722d..f90a259f 100644 --- a/app/views/words/_journal_reply_items.html.erb +++ b/app/views/words/_journal_reply_items.html.erb @@ -13,7 +13,7 @@ <%= format_time reply.created_on %>
- <%= render :partial => 'words/new_respond', :locals => {:journal => journal, :m_reply_id => journal.id} %> + <%= render :partial => 'words/new_respond', :locals => {:journal => journal, :m_reply_id => journal} %>
<%= render :partial => "words/journal_reply", :locals => {:journal => journal } %> diff --git a/app/views/words/_new_respond.html.erb b/app/views/words/_new_respond.html.erb index 25d4b7fc..cc0a117f 100644 --- a/app/views/words/_new_respond.html.erb +++ b/app/views/words/_new_respond.html.erb @@ -2,8 +2,8 @@ <%= text_area_tag 'user_notes', "", :class => 'noline', :style => "resize: none;", :rows => 4, :placeholder => l(:label_projects_feedback_respond_content) %> <%= hidden_field_tag 'reference_id', params[:reference_id], :value => journal.id %> -<%= hidden_field_tag 'reference_user_id', params[:reference_user_id], :value => journal.user.id %> -<%= hidden_field_tag 'reference_message_id', params[:reference_message_id], :value => m_reply_id %> +<%= hidden_field_tag 'reference_user_id', params[:reference_user_id], :value => m_reply_id.user.id %> +<%= hidden_field_tag 'reference_message_id', params[:reference_message_id], :value => m_reply_id.id %> <%= submit_tag l(:button_projects_feedback_respond), :name => nil , :class => "enterprise", :style => "margin-top: 1px;"%> <% end %> \ No newline at end of file diff --git a/app/views/words/create_reply.js.erb b/app/views/words/create_reply.js.erb index 6d625bdc..7c8e7599 100644 --- a/app/views/words/create_reply.js.erb +++ b/app/views/words/create_reply.js.erb @@ -1,7 +1,7 @@ <% if @save_succ %> var pre_append = $('<%= j( render :partial => "words/journal_reply_items", - :locals => {:reply => @jfm, :journal => @jfm.parent, :m_reply_id => @jfm.id} + :locals => {:reply => @jfm, :journal => @jfm.parent, :m_reply_id => @jfm} ) %>').hide(); $('#journal_reply_ul_<%=@jfm.m_parent_id%>').append(pre_append); pre_append.fadeIn(600);