Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class Story < ActiveRecord::Base
- # FULLTEXT INDEXING
- is_indexed :fields => [
- {:field => 'title', :sortable => true},
- :content, :teaser, :category_id
- ],
- :include => [
- {:association_name => 'category', :field => 'name', :as => 'category_name'},
- {:association_name => 'category', :field => 'parent_id'}
- ]
- end
Add Comment
Please, Sign In to add comment