Class: MailyHerald::Webui::SessionsController

Inherits:
ApplicationController show all
Defined in:
app/controllers/maily_herald/webui/sessions_controller.rb

Instance Method Summary collapse

Methods inherited from ApplicationController

#expert_mode?, #work_mode

Methods included from MenuManager::ControllerExtensions

included

Methods included from Breadcrumbs::ControllerExtensions

included

Instance Method Details

#switch_modeObject



3
4
5
6
7
8
9
# File 'app/controllers/maily_herald/webui/sessions_controller.rb', line 3

def switch_mode
  if %w{regular expert}.include? params[:mode]
    session[:work_mode] = params[:mode].to_sym
  end

  redirect_to :back
end