6
7
8
9
10
11
12
13
14
15
16
17
|
# File 'app/controllers/bulky/updates_controller.rb', line 6
def update
if params[:ids].blank?
redirect_to bulky_edit_path(model: params[:model]), alert: I18n.t('flash.alert.blank_ids') and return
end
unless params[:bulk].is_a?(Hash)
redirect_to bulky_edit_path(model: params[:model]), alert: I18n.t('flash.alert.bulk_not_hash') and return
end
Bulky.enqueue_update(model, ids, params[:bulk])
redirect_to bulky_edit_path(model: params[:model]), notice: I18n.t('flash.notice.enqueue_update')
end
|