Does The Ancestry Gem Work With Rails 4?

一个人想着一个人 提交于 2019-12-10 08:14:38

问题


Only mentions Rails 3 in the GitHub documentation - does anyone know if it's compatible with Rails 4?

I ask because it looks like it's been updated to handle Ruby 2.1.0


回答1:


According to the travis build, tests pass with active record 4.




回答2:


Indeed, it works. We've been using it in one of our recent projects. You can also look at travis.yml file in the repo. It was tested to work with ActiveRecord 4.0.




回答3:


Yes it's compatible with Rails 4, but you need to add :parent_id to permit params in your controller.



来源:https://stackoverflow.com/questions/21333218/does-the-ancestry-gem-work-with-rails-4

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!