I am using client_side_validations gem for inline validations. This was working fine until I installed nested_form gem for adding multiple images. Now the inline validations is not showing up errors .
In application.js I have
//= require jquery
//= require jquery_ujs
//= require twitter/bootstrap
//= require_self
//= require_tree .
//= require jquery_nested_form
In application.html.erb file I have
<%= stylesheet_link_tag "application", :media => "all" %>
<%= javascript_include_tag "application", "rails.validations" %>
<%= javascript_include_tag :defaults, "nested_form" %>
In _form.html.erb I have this code
<%= nested_form_for(@project, :html => {:multipart => true }, :validate => true) do |f| %>
I'm not able to understand where I went wrong.
Thanks.
I think you need to have
//= require rails.validations
in the application.js
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.