OpenProject is the leading open source project management software for product, project and portfolio management. A powerful Jira alternative with agile planning, issue tracking, roadmaps, Gantt charts, time tracking, collaboration features, and more. Available on premises or in the cloud. ⭐ Star us on GitHub
Ruby agile-developmentangularbcfboardsbug-trackerganttgantt-chartifcissue-trackerjira-alternativekanbanopenprojectproduct-managementproject-managementproject-planningroadmaprubyscrumtimelineworkflows
Add text-version of shared_work_package email
Aaron Contrerasec5481a056d8
diff --git a/app/mailers/sharing_mailer.rb b/app/mailers/sharing_mailer.rbindex 5a96df68484..86d5b4671b0 100644--- a/app/mailers/sharing_mailer.rb+++ b/app/mailers/sharing_mailer.rb@@ -49,11 +49,7 @@ class SharingMailer < ApplicationMailer[I18n.t('work_package.sharing.permissions.view')]end- allowed_actions = allowed_actions.map do |action|- "<span style=\"font-weight:bold;\">#{action.downcase}</span>"- end-- allowed_actions.to_sentence+ allowed_actions.map(&:downcase)enddef set_open_project_headers(work_package)diff --git a/app/views/sharing_mailer/shared_work_package.html.erb b/app/views/sharing_mailer/shared_work_package.html.erbindex 8c5e172c346..d1c03a79cfa 100644--- a/app/views/sharing_mailer/shared_work_package.html.erb+++ b/app/views/sharing_mailer/shared_work_package.html.erb@@ -26,7 +26,13 @@<table <%= placeholder_table_styles(width:'100%',style: 'width:100%;') %>><tr><td style="<%= placeholder_text_styles %>">- <%= t('mail.sharing.work_packages.allowed_actions', allowed_actions: @allowed_work_package_actions).html_safe %>+ <%+ formatted_actions = @allowed_work_package_actions.map do |action|+ "<span style=\"font-weight:bold;\">#{action.downcase}</span>"+ end.to_sentence+ %>++ <%= t('mail.sharing.work_packages.allowed_actions', allowed_actions: formatted_actions).html_safe %></td></tr></table>diff --git a/app/views/sharing_mailer/shared_work_package.text.erb b/app/views/sharing_mailer/shared_work_package.text.erbindex 9faeac92235..4ae633dcea3 100644--- a/app/views/sharing_mailer/shared_work_package.text.erb+++ b/app/views/sharing_mailer/shared_work_package.text.erb@@ -1,3 +1,12 @@-Sharing#shared_work_package+<%= I18n.t('mail.salutation', user: @shared_with_user.firstname) %>+<%= I18n.t('mail.sharing.work_packages.summary', user: @sharer) %>+<%= "-" * 100 %>-<%= @greeting %>, find me in app/views/sharing_mailer/shared_work_package.text.erb+<%= "=" * (('# ' + @work_package.id.to_s + @work_package.subject).length + 4) %>+= #<%= @work_package.id %> <%= @work_package.subject %> =+<%= "=" * (('# ' + @work_package.id.to_s + @work_package.subject).length + 4) %>++<%= I18n.t('mail.work_packages.reason.shared') %>:+<%= t('mail.sharing.work_packages.allowed_actions', allowed_actions: @allowed_work_package_actions.to_sentence).html_safe %>++<%= "-" * 100 %>