mailer bug fix
git-svn-id: http://redmine.rubyforge.org/svn/trunk@55 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
parent
42181112ff
commit
418b8d861a
|
@ -93,11 +93,11 @@ class IssuesController < ApplicationController
|
|||
#@issue.assigned_to_id = (params[:issue][:assigned_to_id])
|
||||
#@issue.done_ratio = (params[:issue][:done_ratio])
|
||||
#@issue.lock_version = (params[:issue][:lock_version])
|
||||
@issue.init_journal(self.logged_in_user, params[:notes])
|
||||
journal = @issue.init_journal(self.logged_in_user, params[:notes])
|
||||
@issue.status = @new_status
|
||||
if @issue.update_attributes(params[:issue])
|
||||
flash[:notice] = l(:notice_successful_update)
|
||||
Mailer.deliver_issue_change_status(@issue) if Permission.find_by_controller_and_action(@params[:controller], @params[:action]).mail_enabled?
|
||||
Mailer.deliver_issue_edit(journal) if Permission.find_by_controller_and_action(@params[:controller], @params[:action]).mail_enabled?
|
||||
redirect_to :action => 'show', :id => @issue
|
||||
end
|
||||
rescue ActiveRecord::StaleObjectError
|
||||
|
|
|
@ -15,7 +15,9 @@
|
|||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
|
||||
class Mailer < ActionMailer::Base
|
||||
class Mailer < ActionMailer::Base
|
||||
|
||||
helper IssuesHelper
|
||||
|
||||
def issue_add(issue)
|
||||
# Sends to all project members
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
Issue #<%= @issue.id %> has been updated.
|
||||
<%= @journal.user.name %>
|
||||
<% for detail in @journal.details %>
|
||||
<%= show_detail(detail) %>
|
||||
<%= show_detail(detail, true) %>
|
||||
<% end %>
|
||||
<%= @journal.notes if @journal.notes? %>
|
||||
----------------------------------------
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
Issue #<%= @issue.id %> has been updated.
|
||||
<%= @journal.user.name %>
|
||||
<% for detail in @journal.details %>
|
||||
<%= show_detail(detail) %>
|
||||
<%= show_detail(detail, true) %>
|
||||
<% end %>
|
||||
<%= @journal.notes if @journal.notes? %>
|
||||
----------------------------------------
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
Issue #<%= @issue.id %> has been updated.
|
||||
<%= @journal.user.name %>
|
||||
<% for detail in @journal.details %>
|
||||
<%= show_detail(detail) %>
|
||||
<%= show_detail(detail, true) %>
|
||||
<% end %>
|
||||
<%= @journal.notes if @journal.notes? %>
|
||||
----------------------------------------
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
La demande #<%= @issue.id %> a été mise à jour.
|
||||
<%= @journal.user.name %> - <%= format_date(@journal.created_on) %>
|
||||
<% for detail in @journal.details %>
|
||||
<%= show_detail(detail) %>
|
||||
<%= show_detail(detail, true) %>
|
||||
<% end %>
|
||||
<%= journal.notes if journal.notes? %>
|
||||
----------------------------------------
|
||||
|
|
Loading…
Reference in New Issue