You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
My controller with a method named: export_batch_action
module Admin
class SitesController < Admin::ApplicationController
def export_batch_action
Site.find(params[:batch_action_ids]).each(&:export)
redirect_to :admin_sites, notice: "Successfully exported #{params[:batch_action_ids].size} sites"
end
end
end
And model with a Site#export method
class Site < ApplicationRecord
def export
end
end
The text was updated successfully, but these errors were encountered:
The controller method
SitesController#export_batch_action
is undefined when renderingapp/views/admin/application/index.html.erb
Context: Ruby 2.7.5, Rails 6.1.4.4, Administrate 0.16.0
Comparing all changes between main and administrate_batch_actions branches:
https://github.com/stepheneb/wts-rails6/compare/main...administrate_batch_actions
In the interactive console under the view error and asking for tab completion on in-scope objects starting with
export
.My controller with a method named:
export_batch_action
And model with a
Site#export
methodThe text was updated successfully, but these errors were encountered: