diff options
| author | hukl <contact@smyck.org> | 2009-04-28 00:15:53 +0200 |
|---|---|---|
| committer | hukl <contact@smyck.org> | 2009-05-01 17:14:02 +0200 |
| commit | 4bd16f053847f2efe347ebda9136ef2233ee0d2c (patch) | |
| tree | f4c11f89455de991c8d87726d5757b752e7129e2 /vendor/plugins/thinking-sphinx/features/support/models/comment.rb | |
| parent | d3a9b46ba5c863a0ff377dcffae9a494fe476e02 (diff) | |
added thinking_sphinx plugin for fulltext search on nodes and heads
Diffstat (limited to 'vendor/plugins/thinking-sphinx/features/support/models/comment.rb')
| -rw-r--r-- | vendor/plugins/thinking-sphinx/features/support/models/comment.rb | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/vendor/plugins/thinking-sphinx/features/support/models/comment.rb b/vendor/plugins/thinking-sphinx/features/support/models/comment.rb new file mode 100644 index 0000000..a93451c --- /dev/null +++ b/vendor/plugins/thinking-sphinx/features/support/models/comment.rb | |||
| @@ -0,0 +1,10 @@ | |||
| 1 | class Comment < ActiveRecord::Base | ||
| 2 | belongs_to :post | ||
| 3 | belongs_to :category | ||
| 4 | |||
| 5 | define_index do | ||
| 6 | indexes :content | ||
| 7 | |||
| 8 | has category.name, :facet => true, :as => :category_name, :type => :string | ||
| 9 | end | ||
| 10 | end | ||
