Sha256: 1bd09abe0e53f6923977a07feb46d366eabfb6bfe4404cc95d8f51e98db12d13

Contents?: true

Size: 810 Bytes

Versions: 6

Compression:

Stored size: 810 Bytes

Contents

module ActsAsTaggableOn
  module ActiveRecord
    module Backports
      def self.included(base)
        base.class_eval do
          named_scope :where,    lambda { |conditions| { :conditions => conditions } }  
          named_scope :joins,    lambda { |joins|      { :joins => joins } }
          named_scope :group,    lambda { |group|      { :group => group } }
          named_scope :order,    lambda { |order|      { :order => order } }
          named_scope :select,   lambda { |select|     { :select => select } }
          named_scope :limit,    lambda { |limit|      { :limit => limit } }
          named_scope :readonly, lambda { |readonly|   { :readonly => readonly } }
          
          def self.to_sql
            construct_finder_sql({})
          end
        end
      end
    end
  end
end

Version data entries

6 entries across 5 versions & 4 rubygems

Version Path
rylwin-acts-as-taggable-on-2.1.1a lib/acts_as_taggable_on/compatibility/active_record_backports.rb
rylwin-acts-as-taggable-on-2.1.1a lib/acts_as_taggable_on/taggable/compatibility/active_record_backports.rb
acts-as-taggable-on-2.1.1 lib/acts_as_taggable_on/compatibility/active_record_backports.rb
acts-as-taggable-on-2.1.0 lib/acts_as_taggable_on/compatibility/active_record_backports.rb
yetanothernguyen-acts-as-taggable-on-0.0.4 lib/acts_as_taggable_on/compatibility/active_record_backports.rb
ghazel-acts-as-taggable-on-2.0.6.1 lib/acts_as_taggable_on/compatibility/active_record_backports.rb