diff options
author | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2010-03-13 15:29:34 +0000 |
---|---|---|
committer | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2010-03-13 15:29:34 +0000 |
commit | d550c46160deb2b9bca12a75f315afdd18cfbdfa (patch) | |
tree | aaebe04473fbbe1fdd332fba29a0ad816c4ea6f5 /app/models/issue_relation.rb | |
parent | 8e3d1b694ab47317638b474082cb70e08a8d02e7 (diff) | |
download | redmine-d550c46160deb2b9bca12a75f315afdd18cfbdfa.tar.gz redmine-d550c46160deb2b9bca12a75f315afdd18cfbdfa.zip |
Makes subtasks rescheduled when a 'precedes' relation is set on a parent task.
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@3574 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app/models/issue_relation.rb')
-rw-r--r-- | app/models/issue_relation.rb | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/app/models/issue_relation.rb b/app/models/issue_relation.rb index 2c110a72f..a28175d48 100644 --- a/app/models/issue_relation.rb +++ b/app/models/issue_relation.rb @@ -73,9 +73,8 @@ class IssueRelation < ActiveRecord::Base def set_issue_to_dates soonest_start = self.successor_soonest_start - if soonest_start && (!issue_to.start_date || issue_to.start_date < soonest_start) - issue_to.start_date, issue_to.due_date = successor_soonest_start, successor_soonest_start + issue_to.duration - issue_to.save + if soonest_start + issue_to.reschedule_after(soonest_start) end end |