diff options
author | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2007-06-29 17:21:37 +0000 |
---|---|---|
committer | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2007-06-29 17:21:37 +0000 |
commit | 87bad767c686c96d4bb1d83443749302c977e1bf (patch) | |
tree | 1338e1a1e6080445d7055e0698aab122de79d4db /app/models/issue.rb | |
parent | f816d4f3784409ff505f4f88ad46e7f7fb447a96 (diff) | |
download | redmine-87bad767c686c96d4bb1d83443749302c977e1bf.tar.gz redmine-87bad767c686c96d4bb1d83443749302c977e1bf.zip |
Each category can now be associated to a user, so that new issues in that category are automatically assigned to that user.
git-svn-id: http://redmine.rubyforge.org/svn/trunk@577 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app/models/issue.rb')
-rw-r--r-- | app/models/issue.rb | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/app/models/issue.rb b/app/models/issue.rb index 52aaa0931..adc79557d 100644 --- a/app/models/issue.rb +++ b/app/models/issue.rb @@ -60,6 +60,13 @@ class Issue < ActiveRecord::Base end end + def before_create + # default assignment based on category + if assigned_to.nil? && category && category.assigned_to + self.assigned_to = category.assigned_to + end + end + def before_save if @current_journal # attributes changes |