app/controllers/admin/base_controller.rb in ab_admin-0.3.4 vs app/controllers/admin/base_controller.rb in ab_admin-0.3.5
- old
+ new
@@ -22,10 +22,10 @@
rescue_from ::CanCan::AccessDenied, with: :render_unauthorized
def index
super do |format|
- format.js { render collection }
+ format.js { render layout: false }
format.csv do
doc = AbAdmin::Utils::CsvDocument.new(collection, export_options)
send_data(doc.render, filename: doc.filename, type: Mime::CSV, disposition: 'attachment')
end
if defined?(Mime::XLSX)
\ No newline at end of file