Class: Qor::Layout::SettingsController
- Inherits:
-
ApplicationController
- Object
- ApplicationController
- Qor::Layout::SettingsController
- Defined in:
- app/controllers/qor/layout/settings_controller.rb
Instance Method Summary collapse
Instance Method Details
#toggle ⇒ Object
6 7 8 9 |
# File 'app/controllers/qor/layout/settings_controller.rb', line 6 def toggle inline_editing_qor_layout? ? disable_editing_qor_layout : enable_editing_qor_layout redirect_to params[:back] || :back end |
#update ⇒ Object
11 12 13 14 15 16 17 18 19 20 |
# File 'app/controllers/qor/layout/settings_controller.rb', line 11 def update @resource = Qor::Layout::Setting.find_by_id(params[:id]) @resource.update_attributes(params[:setting]) if request.xhr? render :text => 'ok' else redirect_to params[:back] || :back end end |