e5f449b595
By default, Devise will look for views: 1. First in `views/resource/passwords/…`, 2. Then in `views/devise/passwords/…` if not found. By moving the views to `views/devise`, we avoid having a partial in `views/shared` that we need to include manually, and instead let Devise do the job automatically.
22 lines
831 B
Text
22 lines
831 B
Text
- content_for(:title, 'Changement de mot de passe')
|
|
|
|
- content_for :footer do
|
|
= render partial: 'root/footer'
|
|
|
|
.container.devise-container
|
|
.one-column-centered
|
|
= devise_error_messages!
|
|
|
|
= form_for(resource, as: resource_name, url: password_path(resource_name), html: { method: :patch, class: 'form' }) do |f|
|
|
|
|
%h1 Changement de mot de passe
|
|
|
|
= f.hidden_field :reset_password_token
|
|
|
|
= f.label 'Nouveau mot de passe'
|
|
= render 'password_complexity/field', { form: f, test_complexity: populated_resource.validate_password_complexity? }
|
|
|
|
= f.label 'Confirmez le nouveau mot de passe'
|
|
= f.password_field :password_confirmation, autocomplete: 'off'
|
|
|
|
= f.submit 'Changer le mot de passe', class: 'button large primary expand', id: "submit-password", data: { disable_with: "Envoi…" }
|