Sha256: 89e93350afde60ee6564b5e37de1e6a8fd04c49951e2f3dde6cf30d04f9e9ae6

Contents?: true

Size: 640 Bytes

Versions: 7

Compression:

Stored size: 640 Bytes

Contents

ThinkingSphinx::Index.define :article, :with => :active_record do
  indexes title, content
  indexes user.name, :as => :user
  indexes user.articles.title, :as => :related_titles

  has published, user_id
  has taggings.tag_id, :as => :tag_ids
  has taggings.created_at, :as => :taggings_at

  set_property :min_infix_len => 4
  set_property :enable_star   => true
end

ThinkingSphinx::Index.define :article, :with => :active_record,
  :name => 'stemmed_article' do

  indexes title

  has published, user_id
  has taggings.tag_id, :as => :tag_ids
  has taggings.created_at, :as => :taggings_at

  set_property :morphology => 'stem_en'
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
thinking-sphinx-3.0.4 spec/internal/app/indices/article_index.rb
thinking-sphinx-3.0.3 spec/internal/app/indices/article_index.rb
thinking-sphinx-3.0.2 spec/internal/app/indices/article_index.rb
thinking-sphinx-3.0.1 spec/internal/app/indices/article_index.rb
thinking-sphinx-3.0.0 spec/internal/app/indices/article_index.rb
thinking-sphinx-3.0.0.rc spec/internal/app/indices/article_index.rb
thinking-sphinx-3.0.0.pre spec/internal/app/indices/article_index.rb