Sha256: 26c3aa96d7112851124ff23ba278f34cef3f786d56a580873838f9322958d818
Contents?: true
Size: 543 Bytes
Versions: 2
Compression:
Stored size: 543 Bytes
Contents
module Users class AccountSwitcherController < PgEngine.config.users_controller rescue_from ActsAsTenant::Errors::NoTenantSet, with: :internal_error skip_before_action :require_tenant_set before_action do @no_main_frame = true end layout 'pg_layout/centered' def list @user_accounts = Current.user.user_accounts end def switch user_account = UserAccount.find(params[:user_account_id]) session['current_user_account'] = user_account.id redirect_to root_path end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
pg_rails-7.5.4 | pg_engine/app/controllers/users/account_switcher_controller.rb |
pg_rails-7.5.3 | pg_engine/app/controllers/users/account_switcher_controller.rb |