Commit bbae98625f4013084ba5059e7837d0e49535cea5
1 parent
403fa5ef
Exists in
master
and in
28 other branches
ActionItem628: linking directly to the URL where pending tasks can be
solved.
Showing
4 changed files
with
7 additions
and
3 deletions
Show diff stats
app/models/add_friend.rb
| @@ -27,7 +27,7 @@ class AddFriend < Task | @@ -27,7 +27,7 @@ class AddFriend < Task | ||
| 27 | 27 | ||
| 28 | def target_notification_message | 28 | def target_notification_message |
| 29 | description + "\n\n" + | 29 | description + "\n\n" + |
| 30 | - _('You need to login to %{system} in order to accept %{requestor} as your friend. You can use the address below to do that.') % { :system => target.environment.name, :requestor => requestor.name } | 30 | + _('You need to login to %{system} in order to accept %{requestor} as your friend.') % { :system => target.environment.name, :requestor => requestor.name } |
| 31 | end | 31 | end |
| 32 | 32 | ||
| 33 | end | 33 | end |
app/models/approve_article.rb
| @@ -41,7 +41,7 @@ class ApproveArticle < Task | @@ -41,7 +41,7 @@ class ApproveArticle < Task | ||
| 41 | 41 | ||
| 42 | def target_notification_message | 42 | def target_notification_message |
| 43 | description + "\n\n" + | 43 | description + "\n\n" + |
| 44 | - _('You need to login on %{system} in order to approve or reject this article. You can use the address below to do that.') % { :system => target.environment.name } | 44 | + _('You need to login on %{system} in order to approve or reject this article.') % { :system => target.environment.name } |
| 45 | end | 45 | end |
| 46 | 46 | ||
| 47 | end | 47 | end |
app/models/task_mailer.rb
| @@ -20,7 +20,8 @@ class TaskMailer < ActionMailer::Base | @@ -20,7 +20,8 @@ class TaskMailer < ActionMailer::Base | ||
| 20 | :target => task.target.name, | 20 | :target => task.target.name, |
| 21 | :message => msg, | 21 | :message => msg, |
| 22 | :environment => task.requestor.environment.name, | 22 | :environment => task.requestor.environment.name, |
| 23 | - :url => url_for(:host => task.requestor.environment.default_hostname, :controller => 'home') | 23 | + :url => url_for(:host => task.requestor.environment.default_hostname, :controller => 'home'), |
| 24 | + :tasks_url => url_for(task.target.url.merge(:controller => 'tasks', :action => 'index')) | ||
| 24 | end | 25 | end |
| 25 | 26 | ||
| 26 | protected | 27 | protected |
app/views/task_mailer/target_notification.rhtml
| @@ -2,6 +2,9 @@ | @@ -2,6 +2,9 @@ | ||
| 2 | 2 | ||
| 3 | <%= word_wrap(@message) %> | 3 | <%= word_wrap(@message) %> |
| 4 | 4 | ||
| 5 | +<%= word_wrap(_('Access the address below to see this and other pending actions that need your attention:')) %> | ||
| 6 | +<%= @tasks_url %> | ||
| 7 | + | ||
| 5 | -- | 8 | -- |
| 6 | <%= @environment %> | 9 | <%= @environment %> |
| 7 | <%= @url %> | 10 | <%= @url %> |