Module: BabySqueel::ActiveRecord::QueryMethods

Defined in:
lib/baby_squeel/active_record.rb

Instance Method Summary collapse

Instance Method Details

#joining(&block) ⇒ Object

Constructs Arel for ActiveRecord::Base#joins using the DSL.



7
8
9
# File 'lib/baby_squeel/active_record.rb', line 7

def joining(&block)
  joins DSL.evaluate(unscoped, &block)
end

#ordering(&block) ⇒ Object

Constructs Arel for ActiveRecord::Base#order using the DSL.



17
18
19
# File 'lib/baby_squeel/active_record.rb', line 17

def ordering(&block)
  order DSL.evaluate(self, &block)
end

#selecting(&block) ⇒ Object

Constructs Arel for ActiveRecord::Base#select using the DSL.



12
13
14
# File 'lib/baby_squeel/active_record.rb', line 12

def selecting(&block)
  select DSL.evaluate(self, &block)
end