ruby on rails - Summernote gem on active admin -
i'm trying use summernode gem on activeadmin form have code in post.rb file
activeadmin.register post permit_params :user_id, :title, :body, :featured_image controller def find_resource scoped_collection.friendly.find(params[:id]) rescue activerecord::recordnotfound scoped_collection.find(params[:id]) end end form |f| f.inputs 'blog post' f.input :title f.input :featured_image f.input :body, input_html: { 'data-provider' => "summernote"} f.input :user_id, as: :hidden, input_html: {value: current_admin_user.id} end f.actions end end
but not working.
Comments
Post a Comment