Sha256: 7374a65fce32238b070b16f175c08053cd905dfd85d2c68fdc4c30cd18cb34cd

Contents?: true

Size: 418 Bytes

Versions: 4

Compression:

Stored size: 418 Bytes

Contents

require 'active_support'
require 'active_support/core_ext'
require 'dynamic_sunspot_search/version'
require 'dynamic_sunspot_search/translator'

module DynamicSunspotSearch
  def self.included(base)
    base.extend ClassMethods
  end

  module ClassMethods
    def dynamic_search(query_hash, search_options={})
      search(search_options) do
        Translator.translate(self, query_hash)
      end
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
dynamic_sunspot_search-0.1.4 lib/dynamic_sunspot_search.rb
dynamic_sunspot_search-0.1.3 lib/dynamic_sunspot_search.rb
dynamic_sunspot_search-0.1.2 lib/dynamic_sunspot_search.rb
dynamic_sunspot_search-0.1.1 lib/dynamic_sunspot_search.rb