Searchable plugin
Plugin details
Documentation
Install the plugin:
ruby script/plugin install http://svn.mojodna.net/repository/acts_as_searchable/trunk/
The first way is to simply `include Searchable` which triggers Searchable's default behavior, which is to index all attributes returned by `Model.content_columns` using each attributes name as its field name within the index.
For example:
class Person < ActiveRecord::Base
include Searchable
# attrs: first_name, last_name
end
This model can then be searched:
Person.search("seth")
This will attempt to match "_seth_" on all fields available in the index (_first\_name_ and _last\_name_). If you wish to target a specific field:
Person.search("first_name: seth")
Further Documentation
There is currently no advanced documentation for this plugin.
New documentationEdit plugin | (0 older versions) | Last edited by: hardway, 7 months ago

