Class: Rql::Scope::BlockMethods

Inherits:
MethodGroup show all
Defined in:
lib/rql/scope/block_methods.rb

Instance Method Summary collapse

Methods inherited from MethodGroup

#initialize, #scope

Constructor Details

This class inherits a constructor from Rql::Scope::MethodGroup

Instance Method Details

#includes(&block) ⇒ Object



20
21
22
# File 'lib/rql/scope/block_methods.rb', line 20

def includes(&block)
  scope.includes(*build_join_path(&block))
end

#joins(&block) ⇒ Object



16
17
18
# File 'lib/rql/scope/block_methods.rb', line 16

def joins(&block)
  scope.joins(*build_join_path(&block))
end

#order(&block) ⇒ Object



12
13
14
# File 'lib/rql/scope/block_methods.rb', line 12

def order(&block)
  scope.order(*build_attributes(&block))
end

#select(&block) ⇒ Object



8
9
10
# File 'lib/rql/scope/block_methods.rb', line 8

def select(&block)
  scope.select(*build_attributes(true, &block))
end

#where(&block) ⇒ Object



4
5
6
# File 'lib/rql/scope/block_methods.rb', line 4

def where(&block)
  scope.where(scope.eval_rql(&block).arel)
end