Merge pull request #2994 from diasp/improve-reset-password

Improve reset password views
This commit is contained in:
Maxwell Salzberg 2012-03-12 18:13:52 -07:00
commit da6866c04c
2 changed files with 22 additions and 19 deletions

View file

@ -1,15 +1,18 @@
%h2 Change your password .span-12.prepend-6.last
= form_for(resource, :as => resource_name, :url => password_path(resource_name), :html => { :method => :put }) do |f| .floating
= devise_error_messages! %h2
= f.hidden_field :reset_password_token = t('.change_password')
%p = form_for(resource, :as => resource_name, :url => password_path(resource_name), :html => { :method => :put }) do |f|
= f.label :password = devise_error_messages!
%br/ = f.hidden_field :reset_password_token
= f.password_field :password %p
%p = f.label :password, t('password')
= f.label :password_confirmation %br/
%br/ = f.password_field :password
= f.password_field :password_confirmation %p
%p = f.label :password_confirmation, t('password_confirmation')
= f.submit t('.change_password') %br/
= render :partial => "devise/shared/links" = f.password_field :password_confirmation
%p
= f.submit t('.change_password')
= render :partial => "devise/shared/links"

View file

@ -1,13 +1,13 @@
.span-12.prepend-6.last .span-12.prepend-6.last
.floating .floating
%h3 %h2
=t('.forgot_password') = t('.forgot_password')
- unless devise_error_messages!.empty? - unless devise_error_messages!.empty?
%i= t('.no_account') %i= t('.no_account')
= form_for(resource, :as => resource_name, :url => password_path(resource_name)) do |f| = form_for(resource, :as => resource_name, :url => password_path(resource_name)) do |f|
%p %p
= f.label :email = f.label :email, t('email')
= f.text_field :email = f.text_field :email
%p %p
= f.submit t('.send_password_instructions') = f.submit t('.send_password_instructions')