app/views/devise/registrations/edit.html.erb in enju_leaf-1.2.0 vs app/views/devise/registrations/edit.html.erb in enju_leaf-1.2.1

- old
+ new

@@ -1,24 +1,49 @@ <div id="content_detail" class="ui-corner-all ui-widget-content"> -<h2 class="title"><%= t('activerecord.models.registration') %></h2> -<div id="content_list"> + <h2 class="title"><%= t('activerecord.models.registration') %></h2> + <div id="content_list"> -<%= form_for(resource, :as => resource_name, :url => user_registration_path, :html => { :method => :put }) do |f| %> +<%= form_for(resource, as: resource_name, url: registration_path(resource_name), html: { method: :put }) do |f| %> <%= devise_error_messages! %> - <p><%= f.label :current_password %> - <p><%= f.password_field :current_password %></p> + <div class="field"> + <%= f.label :email %><br /> + <%= f.email_field :email, autofocus: true %> + </div> - <p><%= f.label :password %> - <p><%= f.password_field :password %></p> + <% if devise_mapping.confirmable? && resource.pending_reconfirmation? %> + <div>Currently waiting confirmation for: <%= resource.unconfirmed_email %></div> + <% end %> - <p><%= f.label :password_confirmation %></p> - <p><%= f.password_field :password_confirmation %></p> + <div class="field"> + <%= f.label :password %> <i>(leave blank if you don't want to change it)</i><br /> + <%= f.password_field :password, autocomplete: "off" %> + <% if @minimum_password_length %> + <br /> + <em><%= @minimum_password_length %> characters minimum</em> + <% end %> + </div> - <p><%= f.submit t('page.update') %></p> + <div class="field"> + <%= f.label :password_confirmation %><br /> + <%= f.password_field :password_confirmation, autocomplete: "off" %> + </div> + + <div class="field"> + <%= f.label :current_password %> <i>(we need your current password to confirm your changes)</i><br /> + <%= f.password_field :current_password, autocomplete: "off" %> + </div> + + <div class="actions"> + <%= f.submit t('page.update') %> + </div> <% end %> -</div> +<h3>Cancel my account</h3> + +<p>Unhappy? <%= button_to "Cancel my account", registration_path(resource_name), data: { confirm: "Are you sure?" }, method: :delete %></p> + + </div> </div> <div id="submenu" class="ui-corner-all ui-widget-content"> <ul> <li><%= link_to t('page.back'), :back %></li>