Sha256: a25ca27c5adad9d77650c56b895a078279d52e3ec370ad2e8c342c8b8dcf3e72
Contents?: true
Size: 844 Bytes
Versions: 9
Compression:
Stored size: 844 Bytes
Contents
require "rsolr" module Supernova KM_TO_METER = 1000.0 MILE_TO_METER = 1609.3472 DEG_TO_RADIAN = Math::PI / 180.0 RADIAN_TO_REG = 1 / DEG_TO_RADIAN module ClassMethods attr_accessor :criteria_class, :defined_named_search_scopes def search_scope self.criteria_class.new(self).named_scope_class(self) end def named_search_scope(name, &block) self.class.send(:define_method, name) do |*args| self.search_scope.instance_exec(*args, &block) end self.defined_named_search_scopes ||= [] self.defined_named_search_scopes << name end end end require "supernova/numeric_extensions" require "supernova/symbol_extensions" require "supernova/condition" require "supernova/collection" require "supernova/criteria" require "supernova/thinking_sphinx" require "supernova/solr"
Version data entries
9 entries across 9 versions & 1 rubygems