Sha256: 59fbdda2e1cc903bd2461c872b0a99b5d0dd93a5b21721f8869ab9a8342ffbe2

Contents?: true

Size: 544 Bytes

Versions: 3

Compression:

Stored size: 544 Bytes

Contents

require 'features/thinking_sphinx/models/tag'
require 'features/thinking_sphinx/models/tagging'

class Developer < ActiveRecord::Base
  has_many :taggings, :as => :taggable
  has_many :tags, :through => :taggings
  
  define_index do
    indexes country,                      :facet => true
    indexes state,                        :facet => true
    indexes tags.text,  :as => :tags,     :facet => true
    has age,                              :facet => true
    has tags(:id),      :as => :tag_ids,  :facet => true
    facet city
  end
end

Version data entries

3 entries across 3 versions & 3 rubygems

Version Path
joshcutler-thinking-sphinx-1.3.18 features/thinking_sphinx/models/developer.rb
josh_cutler-thinking-sphinx-1.3.17 features/thinking_sphinx/models/developer.rb
thinking-sphinx-1.3.17 features/thinking_sphinx/models/developer.rb