Class: MetadataPresenter::AuthController

Inherits:
EngineController show all
Defined in:
app/controllers/metadata_presenter/auth_controller.rb

Constant Summary collapse

PRODUCTION_ENVS =
%w[test-production live-production].freeze

Instance Method Summary collapse

Methods inherited from EngineController

#analytics_cookie_name, #analytics_tags_present?, #answered?, #authorised_session!, #back_link, #external_or_relative_link, #get_saved_progress, #increment_record_counter, #invalidate_record, #load_autocomplete_items, #load_page_content, #maintenance_mode?, #reload_user_data, #require_basic_auth, #save_form_progress, #session_authorised?, #show_cookie_confirmation?

Instance Method Details

#createObject



12
13
14
15
16
17
18
19
20
21
# File 'app/controllers/metadata_presenter/auth_controller.rb', line 12

def create
  @auth_form = AuthForm.new(auth_params)

  if @auth_form.valid?
    authorised_session!
    redirect_to root_path
  else
    render :show
  end
end

#showObject



8
9
10
# File 'app/controllers/metadata_presenter/auth_controller.rb', line 8

def show
  @auth_form = AuthForm.new
end