Class: Plugins::CamaleonImageOptimizer::AdminController

Inherits:
CamaleonCms::Apps::PluginsAdminController
  • Object
show all
Includes:
MainHelper
Defined in:
app/controllers/plugins/camaleon_image_optimizer/admin_controller.rb

Instance Method Summary collapse

Instance Method Details

#indexObject



5
6
# File 'app/controllers/plugins/camaleon_image_optimizer/admin_controller.rb', line 5

def index
end

#save_settingsObject

save values from settings form



13
14
15
16
17
18
# File 'app/controllers/plugins/camaleon_image_optimizer/admin_controller.rb', line 13

def save_settings
  @plugin.set_options(params[:options]) if params[:options].present? # save option values
  @plugin.set_metas(params[:metas]) if params[:metas].present? # save meta values
  @plugin.set_field_values(params[:field_options]) if params[:field_options].present? # save custom field values
  redirect_to url_for(action: :settings), notice: "Settings Saved Successfully"
end

#settingsObject

show settings form



9
10
# File 'app/controllers/plugins/camaleon_image_optimizer/admin_controller.rb', line 9

def settings
end