Method: Arel::Nodes::Window#order

Defined in:
activerecord/lib/arel/nodes/window.rb

#order(*expr) ⇒ Object



14
15
16
17
18
19
20
# File 'activerecord/lib/arel/nodes/window.rb', line 14

def order(*expr)
  # FIXME: We SHOULD NOT be converting these to SqlLiteral automatically
  @orders.concat expr.map { |x|
    String === x || Symbol === x ? Nodes::SqlLiteral.new(x.to_s) : x
  }
  self
end