Project

General

Profile

RE: Changing text in email object field ? ยป redmine_issue_nested_subject.patch

JayD -, 2014-06-22 16:11

View differences:

mailer.rb 2014-06-22 22:04:26.554745207 +0800
39 39
    @issue = issue
40 40
    @users = to_users + cc_users
41 41
    @issue_url = url_for(:controller => 'issues', :action => 'show', :id => issue)
42

  
43
    s = "["
44
    s << "#{issue.project.parent.name} - " if defined?(issue.project.parent.name)
45
    s << "#{issue.project.name} - "
46
    s << "#{issue.tracker.name} ##{issue.id}] "
47
    s << issue.subject
42 48
    mail :to => to_users.map(&:mail),
43 49
      :cc => cc_users.map(&:mail),
44
      :subject => "[#{issue.project.name} - #{issue.tracker.name} ##{issue.id}] (#{issue.status.name}) #{issue.subject}"
50
      :subject => s
45 51
  end
46 52

  
47 53
  # Notifies users about a new issue
......
63 69
    message_id journal
64 70
    references issue
65 71
    @author = journal.user
66
    s = "[#{issue.project.name} - #{issue.tracker.name} ##{issue.id}] "
72
    s = "["
73
    s << "#{issue.project.parent.name} - " if defined?(issue.project.parent.name)
74
    s << "#{issue.project.name} - "
75
    s << "#{issue.tracker.name} ##{issue.id}] "
67 76
    s << "(#{issue.status.name}) " if journal.new_value_for('status_id')
68 77
    s << issue.subject
69 78
    @issue = issue
    (1-1/1)