[英]How to get autocomplete/search field as input in activeadmin
Hai i have a intermediate table projects currently i have implemented it as checkboxes as input. Hai,我有一个中间表项目,目前我已将其实现为复选框作为输入。 I need to know how to use it as a search and select like a field which can search the projects and add multiple projects rather than selecting the checkbox.
我需要知道如何将其用作搜索并选择一个可以搜索项目并添加多个项目的字段,而不是选择复选框。
f.input :projects, as: :check_boxes
I need to search and select multiple the projects from a list i should also be able to discard the selected one 我需要从列表中搜索并选择多个项目,我也应该能够丢弃所选的项目
You can try to use chosen
gem. 您可以尝试使用
chosen
宝石。 Here is a tutorial explaining all the process. 这是解释所有过程的教程。 I expect that this can help you:
我希望这可以帮助您:
http://tech.eshaiju.in/blog/2014/01/01/autocomplete-using-chosen-in-rails/ http://tech.eshaiju.in/blog/2014/01/01/autocomplete-using-chosen-in-rails/
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.