Notify previous assignee when assignee changes (#2694).

git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@8695 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Jean-Philippe Lang
2012-01-23 17:55:29 +00:00
parent f2e7aa596b
commit 22317105f9
3 changed files with 30 additions and 10 deletions
+3 -3
View File
@@ -509,7 +509,7 @@ class User < Principal
true
when 'selected'
# user receives notifications for created/assigned issues on unselected projects
if object.is_a?(Issue) && (object.author == self || is_or_belongs_to?(object.assigned_to))
if object.is_a?(Issue) && (object.author == self || is_or_belongs_to?(object.assigned_to) || is_or_belongs_to?(object.assigned_to_was))
true
else
false
@@ -517,13 +517,13 @@ class User < Principal
when 'none'
false
when 'only_my_events'
if object.is_a?(Issue) && (object.author == self || is_or_belongs_to?(object.assigned_to))
if object.is_a?(Issue) && (object.author == self || is_or_belongs_to?(object.assigned_to) || is_or_belongs_to?(object.assigned_to_was))
true
else
false
end
when 'only_assigned'
if object.is_a?(Issue) && is_or_belongs_to?(object.assigned_to)
if object.is_a?(Issue) && (is_or_belongs_to?(object.assigned_to) || is_or_belongs_to?(object.assigned_to_was))
true
else
false