mirror of
https://github.com/rickbarrette/redmine_qbo.git
synced 2026-10-03 17:00:43 -04:00
scope.includes(:customer)
This commit is contained in:
1 parent
886d5f4ace
commit
2f9ef6304f
1 file changed
+6
-1
@@ -16,12 +16,17 @@ module RedmineQbo
|
||||
|
||||
def base_scope
|
||||
scope = super
|
||||
|
||||
if filters['customer_name'].present?
|
||||
scope = scope.left_outer_joins(:customer)
|
||||
end
|
||||
scope
|
||||
|
||||
if has_column?(:customer) || filters['customer_name'].present?
|
||||
scope = scope.includes(:customer)
|
||||
end
|
||||
|
||||
scope
|
||||
end
|
||||
|
||||
# Add qbo options to the aviable columns
|
||||
def available_columns
|
||||
|
||||
Reference in new issue
Block a user