diff --git a/app/controllers/administrateurs/sessions_controller.rb b/app/controllers/administrateurs/sessions_controller.rb index be676864f..3c8328e30 100644 --- a/app/controllers/administrateurs/sessions_controller.rb +++ b/app/controllers/administrateurs/sessions_controller.rb @@ -1,4 +1,6 @@ class Administrateurs::SessionsController < Sessions::SessionsController + layout "new_application" + def demo return redirect_to root_path if Rails.env.production? diff --git a/app/controllers/gestionnaires/sessions_controller.rb b/app/controllers/gestionnaires/sessions_controller.rb index c0f7d7b9b..326cf2200 100644 --- a/app/controllers/gestionnaires/sessions_controller.rb +++ b/app/controllers/gestionnaires/sessions_controller.rb @@ -1,4 +1,6 @@ class Gestionnaires::SessionsController < Sessions::SessionsController + layout "new_application" + def demo return redirect_to root_path if Rails.env.production? diff --git a/app/views/users/sessions/new.html.haml b/app/views/users/sessions/new.html.haml index 7f399eeec..93e0aa480 100644 --- a/app/views/users/sessions/new.html.haml +++ b/app/views/users/sessions/new.html.haml @@ -31,8 +31,10 @@ = f.label :password, "Mot de passe" = f.password_field :password, value: @user.password, placeholder: "8 caractères minimum" - .reset-password.text-right - = link_to "Mot de passe oublié ?", new_password_path(resource_name), class: "link" + + - if [:user, :gestionnaire].include?(resource_name) + .reset-password.text-right + = link_to "Mot de passe oublié ?", new_password_path(resource_name), class: "link" - if devise_mapping.rememberable? = f.check_box :remember_me, as: :boolean @@ -50,7 +52,7 @@ .center = link_to "Qu’est-ce que FranceConnect ?", "https://franceconnect.gouv.fr/", target: "_blank", class: "link" - - if devise_mapping.registerable? + - if resource_name == :user %hr %p.register %span