I want to install the plugin for fuzzy search. I searched a lot and came across:
https://github.com/iulianu/rails-fuzzy-search
In my model I have:
class User < ActiveRecord::Base
include FuzzySearch
act_as_fuzzy_search :name, :email
property :id, Integer, :serial => true
property :name, String, :nullable => false , :format 开发者_开发技巧=> /^[^<'&">]*$/, :length => 32
property :email,String, :nullable => false , :format => /^[^<'&">]*$/, :length => 32
.....
.....
end
But I am getting the following error:
uninitialized constant User::FuzzySearch
Does anyone know how to fix this?
See the README on that github page:
Installation
NOTE! The following plugin is a prerequisite: script/plugin install git://github.com/blythedunham/eload-select.git More details at http://www.snowgiraffe.com/tech/329/eager-loading-select-plugin-when-select-plays-nice-with-include/
Have you installed the prerequisite plugin?
精彩评论