1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00
rails--rails/lib/active_relation/relations/compound.rb
Nick Kallen c54392872f introduced engine dependency for sql strategies
- hacked in default engine for scalars -- BAD
2008-03-02 17:56:18 -08:00

17 lines
No EOL
454 B
Ruby

module ActiveRelation
class Compound < Relation
attr_reader :relation
delegate :joins, :selects, :orders, :groupings, :table_sql, :inserts, :limit,
:offset, :name, :alias, :aggregation?, :alias?, :prefix_for, :column_for,
:hash, :engine,
:to => :relation
def attributes
relation.attributes.collect { |a| a.bind(self) }
end
def qualify
descend(&:qualify)
end
end
end