summaryrefslogtreecommitdiffstats
path: root/app/models
diff options
context:
space:
mode:
authorToshi MARUYAMA <marutosijp2@yahoo.co.jp>2019-11-07 03:41:39 +0000
committerToshi MARUYAMA <marutosijp2@yahoo.co.jp>2019-11-07 03:41:39 +0000
commit28047659fca9e1602c7e9a5f6a9d6dc61efc82d0 (patch)
tree588f070da219052f8dea218f569af0a8f5a3b5df /app/models
parent989b44ac3b363f23e1530030e569e0d0646aaef2 (diff)
downloadredmine-28047659fca9e1602c7e9a5f6a9d6dc61efc82d0.tar.gz
redmine-28047659fca9e1602c7e9a5f6a9d6dc61efc82d0.zip
cleanup: rubocop: fix Layout/AlignArguments in IssueQuery#available_columns
git-svn-id: http://svn.redmine.org/redmine/trunk@18929 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app/models')
-rw-r--r--app/models/issue_query.rb22
1 files changed, 13 insertions, 9 deletions
diff --git a/app/models/issue_query.rb b/app/models/issue_query.rb
index b134cec21..b2d219f4c 100644
--- a/app/models/issue_query.rb
+++ b/app/models/issue_query.rb
@@ -221,11 +221,13 @@ class IssueQuery < Query
" JOIN #{Project.table_name} ON #{Project.table_name}.id = #{TimeEntry.table_name}.project_id" +
" WHERE (#{TimeEntry.visible_condition(User.current)}) AND #{TimeEntry.table_name}.issue_id = #{Issue.table_name}.id"
- @available_columns.insert index, QueryColumn.new(:spent_hours,
- :sortable => "COALESCE((#{subselect}), 0)",
- :default_order => 'desc',
- :caption => :label_spent_time,
- :totalable => true
+ @available_columns.insert(
+ index,
+ QueryColumn.new(:spent_hours,
+ :sortable => "COALESCE((#{subselect}), 0)",
+ :default_order => 'desc',
+ :caption => :label_spent_time,
+ :totalable => true)
)
subselect = "SELECT SUM(hours) FROM #{TimeEntry.table_name}" +
@@ -234,10 +236,12 @@ class IssueQuery < Query
" WHERE (#{TimeEntry.visible_condition(User.current)})" +
" AND subtasks.root_id = #{Issue.table_name}.root_id AND subtasks.lft >= #{Issue.table_name}.lft AND subtasks.rgt <= #{Issue.table_name}.rgt"
- @available_columns.insert index+1, QueryColumn.new(:total_spent_hours,
- :sortable => "COALESCE((#{subselect}), 0)",
- :default_order => 'desc',
- :caption => :label_total_spent_time
+ @available_columns.insert(
+ index + 1,
+ QueryColumn.new(:total_spent_hours,
+ :sortable => "COALESCE((#{subselect}), 0)",
+ :default_order => 'desc',
+ :caption => :label_total_spent_time)
)
end