我在使用带有 active_admin 的 rails3-jquery-autocomplete gem 时遇到问题
我正在使用最新版本的active_admin(来自 git),它现在依赖于 formtastic 2,我正在使用 1.04 的rails3-jquery-autocomplete
undefined local variable or method `autocomplete_artist_name_records_path' for #<ActiveAdmin::DSL:0x007fde797140d0>
它不喜欢我提供的 url 路由,有什么想法我可能做错了吗?
宝石
gem 'activeadmin', :git => 'git://github.com/gregbell/active_admin.git'
gem 'rails3-jquery-autocomplete', '~> 1.0.4'
记录.rb (active_admin)
ActiveAdmin.register Record do
#...
controller do
autocomplete :artist, :name#, :full => true
end
form do |f|
f.input :artist_name, :as => :autocomplete, :url => autocomplete_artist_name_records_path
end
end
路线.rb
resources :records do
get :autocomplete_artist_name, :on => :collection
end
我也尝试了这个我在某处找到的修复,但它没有改变任何东西,包括错误