diff options
author | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2015-05-30 08:38:35 +0000 |
---|---|---|
committer | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2015-05-30 08:38:35 +0000 |
commit | 216a153421b05bce4d4e64b590889b740367b92e (patch) | |
tree | a01c6009db7d9aefc80ea09b073e1ca48131ffab /app/helpers | |
parent | affeabcc526449057b29ca636f456234a87798b6 (diff) | |
download | redmine-216a153421b05bce4d4e64b590889b740367b92e.tar.gz redmine-216a153421b05bce4d4e64b590889b740367b92e.zip |
Update activities list when changing project/issue id on the time entry form (#19656).
git-svn-id: http://svn.redmine.org/redmine/trunk@14287 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app/helpers')
-rw-r--r-- | app/helpers/timelog_helper.rb | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/app/helpers/timelog_helper.rb b/app/helpers/timelog_helper.rb index f4a97bcab..106a8943c 100644 --- a/app/helpers/timelog_helper.rb +++ b/app/helpers/timelog_helper.rb @@ -38,6 +38,7 @@ module TimelogHelper # is optional and will be used to check if the selected TimeEntryActivity # is active. def activity_collection_for_select_options(time_entry=nil, project=nil) + project ||= time_entry.try(:project) project ||= @project if project.nil? activities = TimeEntryActivity.shared.active |