diff options
author | Go MAEDA <maeda@farend.jp> | 2023-04-09 01:38:36 +0000 |
---|---|---|
committer | Go MAEDA <maeda@farend.jp> | 2023-04-09 01:38:36 +0000 |
commit | 565d13d6540de55d177074ce51c65611cc7737a0 (patch) | |
tree | fbffc87679bad4959b5a1583b0db067ee13b37ec /app | |
parent | 544af76dda2810cb752fb343651849629cc81e1d (diff) | |
download | redmine-565d13d6540de55d177074ce51c65611cc7737a0.tar.gz redmine-565d13d6540de55d177074ce51c65611cc7737a0.zip |
"Issue's subject" filter for spent time (#27821).
Patch by Go MAEDA.
git-svn-id: https://svn.redmine.org/redmine/trunk@22173 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app')
-rw-r--r-- | app/models/time_entry_query.rb | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/app/models/time_entry_query.rb b/app/models/time_entry_query.rb index 4e14e0b40..fab5a3448 100644 --- a/app/models/time_entry_query.rb +++ b/app/models/time_entry_query.rb @@ -78,6 +78,11 @@ class TimeEntryQuery < Query :values => lambda {project.issue_categories.collect{|s| [s.name, s.id.to_s]}} ) if project add_available_filter( + "issue.subject", + :type => :text, + :name => l("label_attribute_of_issue", :name => l(:field_subject)) + ) + add_available_filter( "user_id", :type => :list_optional, :values => lambda {author_values} ) @@ -222,6 +227,10 @@ class TimeEntryQuery < Query sql_for_field("category_id", operator, value, Issue.table_name, "category_id") end + def sql_for_issue_subject_field(field, operator, value) + sql_for_field("subject", operator, value, Issue.table_name, "subject") + end + def sql_for_project_status_field(field, operator, value, options={}) sql_for_field(field, operator, value, Project.table_name, "status") end |