remove trailing white-spaces from app/models/query.rb
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@10469 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
parent
95fe4d61c9
commit
49c2f316c2
|
@ -38,7 +38,7 @@ class QueryColumn
|
|||
def sortable?
|
||||
!@sortable.nil?
|
||||
end
|
||||
|
||||
|
||||
def sortable
|
||||
@sortable.is_a?(Proc) ? @sortable.call : @sortable
|
||||
end
|
||||
|
@ -711,10 +711,10 @@ class Query < ActiveRecord::Base
|
|||
"(#{nl} #{Issue.table_name}.assigned_to_id #{sw} IN (SELECT DISTINCT #{Member.table_name}.user_id FROM #{Member.table_name}" +
|
||||
" WHERE #{Member.table_name}.project_id = #{Issue.table_name}.project_id))"
|
||||
when "=", "!"
|
||||
role_cond = value.any? ?
|
||||
role_cond = value.any? ?
|
||||
"#{MemberRole.table_name}.role_id IN (" + value.collect{|val| "'#{connection.quote_string(val)}'"}.join(",") + ")" :
|
||||
"1=0"
|
||||
|
||||
|
||||
sw = operator == "!" ? 'NOT' : ''
|
||||
nl = operator == "!" ? "#{Issue.table_name}.assigned_to_id IS NULL OR" : ''
|
||||
"(#{nl} #{Issue.table_name}.assigned_to_id #{sw} IN (SELECT DISTINCT #{Member.table_name}.user_id FROM #{Member.table_name}, #{MemberRole.table_name}" +
|
||||
|
|
Loading…
Reference in New Issue