diff -urN redmine-0.8.3.orig/app/models/mail_handler.rb redmine-0.8.3/app/models/mail_handler.rb --- redmine-0.8.3.orig/app/models/mail_handler.rb 2009-04-05 08:44:17.000000000 -0400 +++ redmine-0.8.3/app/models/mail_handler.rb 2009-04-26 00:18:37.000000000 -0400 @@ -126,8 +126,14 @@ raise UnauthorizedAction unless user.allowed_to?(:add_issue_notes, issue.project) || user.allowed_to?(:edit_issues, issue.project) raise UnauthorizedAction unless status.nil? || user.allowed_to?(:edit_issues, issue.project) + # strip quoted text + note_details = plain_text_body + regexp = /^(\>|:|\|)*\s*----- REPLY ABOVE THIS LINE$(.*?)^(\>|:|\|)*\s*----- REPLY BELOW THIS LINE$/m + if regexp =~ note_details + note_details = $` + $' + end # add the note - journal = issue.init_journal(user, plain_text_body) + journal = issue.init_journal(user, note_details) add_attachments(issue) # check workflow if status && issue.new_statuses_allowed_to(user).include?(status) diff -urN redmine-0.8.3.orig/app/views/mailer/layout.text.html.rhtml redmine-0.8.3/app/views/mailer/layout.text.html.rhtml --- redmine-0.8.3.orig/app/views/mailer/layout.text.html.rhtml 2009-04-05 08:44:17.000000000 -0400 +++ redmine-0.8.3/app/views/mailer/layout.text.html.rhtml 2009-04-26 00:40:11.000000000 -0400 @@ -25,8 +25,10 @@ +----- REPLY ABOVE THIS LINE
<%= yield %>
<%= Redmine::WikiFormatting.to_html(Setting.text_formatting, Setting.emails_footer) %> +----- REPLY BELOW THIS LINE
diff -urN redmine-0.8.3.orig/app/views/mailer/layout.text.plain.rhtml redmine-0.8.3/app/views/mailer/layout.text.plain.rhtml --- redmine-0.8.3.orig/app/views/mailer/layout.text.plain.rhtml 2009-04-05 08:44:17.000000000 -0400 +++ redmine-0.8.3/app/views/mailer/layout.text.plain.rhtml 2009-04-26 00:40:24.000000000 -0400 @@ -1,3 +1,5 @@ +----- REPLY ABOVE THIS LINE <%= yield %> -- <%= Setting.emails_footer %> +----- REPLY BELOW THIS LINE