Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Active admin - checkbox doesn't make batch action enabled

I install

gem 'activeadmin',         github: 'gregbell/active_admin', branch: 'rails4'

and it works fine but.. When i click on checkbox for some resources, batch action doesn't change to enabled. I have:

  index do |description|
   selectable_column
   column :id
   column :user
   column :description
   default_actions
  end



batch_action :destroy, :confirm => "delete ??", :plural_model => "descriptions" do |selection|
Profile.find(selection).each { |d| d.reset_description! }
redirect_to collection_path
  end

and batch action for :destroy. Is active admin works correct in rails 4?

like image 826
Wordica Avatar asked Sep 14 '26 02:09

Wordica


1 Answers

Had the same problem, the first comment of the OP solved it for me: Add

//= require active_admin/base 

to

active_admin.js
like image 100
eki eki patang Avatar answered Sep 16 '26 19:09

eki eki patang



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!