Feature #4199 ยป reassign_to_author.patch
app/models/changeset.rb (working copy) | ||
---|---|---|
112 | 112 |
journal = issue.init_journal(user || User.anonymous, ll(Setting.default_language, :text_status_changed_by_changeset, csettext)) |
113 | 113 |
issue.status = fix_status |
114 | 114 |
issue.done_ratio = done_ratio if done_ratio |
115 |
reassign_to = nil |
|
116 |
issue.assignable_users.each do |assignuser| |
|
117 |
reassign_to = assignuser if assignuser.id == issue.author_id |
|
118 |
end |
|
119 |
issue.assigned_to = reassign_to |
|
115 | 120 |
Redmine::Hook.call_hook(:model_changeset_scan_commit_for_issue_ids_pre_issue_update, |
116 | 121 |
{ :changeset => self, :issue => issue }) |
117 | 122 |
issue.save |