From 6a445b42003007cbb6c06f477c4d7a0b175688c1 Mon Sep 17 00:00:00 2001 From: Dmitriy Zaporozhets Date: Mon, 20 Feb 2012 20:37:37 +0200 Subject: fixed forgot password form --- app/views/devise/passwords/edit.html.erb | 16 ---------------- app/views/devise/passwords/edit.html.haml | 12 ++++++++++++ app/views/devise/passwords/new.html.erb | 3 ++- app/views/projects/_project_head.html.haml | 17 +++++++---------- 4 files changed, 21 insertions(+), 27 deletions(-) delete mode 100644 app/views/devise/passwords/edit.html.erb create mode 100644 app/views/devise/passwords/edit.html.haml diff --git a/app/views/devise/passwords/edit.html.erb b/app/views/devise/passwords/edit.html.erb deleted file mode 100644 index ff76588c144..00000000000 --- a/app/views/devise/passwords/edit.html.erb +++ /dev/null @@ -1,16 +0,0 @@ -

Change your password

- -<%= form_for(resource, :as => resource_name, :url => password_path(resource_name), :html => { :method => :put }) do |f| %> - <%= devise_error_messages! %> - <%= f.hidden_field :reset_password_token %> - -
<%= f.label :password, "New password" %>
- <%= f.password_field :password %>
- -
<%= f.label :password_confirmation, "Confirm new password" %>
- <%= f.password_field :password_confirmation %>
- -
<%= f.submit "Change my password" %>
-<% end %> - -<%= render :partial => "devise/shared/links" %> diff --git a/app/views/devise/passwords/edit.html.haml b/app/views/devise/passwords/edit.html.haml new file mode 100644 index 00000000000..dfd715ac13b --- /dev/null +++ b/app/views/devise/passwords/edit.html.haml @@ -0,0 +1,12 @@ += form_for(resource, :as => resource_name, :url => password_path(resource_name), :html => { :method => :put, :class => "login-box" }) do |f| + = image_tag "login-logo.png", :width => "304", :height => "66", :class => "login-logo", :alt => "Login Logo" + %h3 Change your password + = devise_error_messages! + = f.hidden_field :reset_password_token + %div + = f.password_field :password, :class => "text top", :placeholder => "New password" + %div + = f.password_field :password_confirmation, :class => "text bottom", :placeholder => "Confirm new password" + %div + = f.submit "Change my password", :class => "btn primary" + .right= render :partial => "devise/shared/links" diff --git a/app/views/devise/passwords/new.html.erb b/app/views/devise/passwords/new.html.erb index 76fc34968ff..cf56c5d2710 100644 --- a/app/views/devise/passwords/new.html.erb +++ b/app/views/devise/passwords/new.html.erb @@ -1,7 +1,8 @@ <%= form_for(resource, :as => resource_name, :url => password_path(resource_name), :html => { :class => "login-box", :method => :post }) do |f| %> <%= image_tag "login-logo.png", :width => "304", :height => "66", :class => "login-logo", :alt => "Login Logo" %> <%= devise_error_messages! %> - <%= f.email_field :email, :placeholder => "Email", :class => "text top" %> + <%= f.email_field :email, :placeholder => "Email", :class => "text" %> +

<%= f.submit "Reset password", :class => "primary btn" %>
<%= render :partial => "devise/shared/links" %>
diff --git a/app/views/projects/_project_head.html.haml b/app/views/projects/_project_head.html.haml index f8a4f9c5c38..ebf0748c8a4 100644 --- a/app/views/projects/_project_head.html.haml +++ b/app/views/projects/_project_head.html.haml @@ -16,16 +16,13 @@ %li{ :class => " #{'active' if (controller.controller_name == "snippets") }" } = link_to project_snippets_path(@project), :class => "snippets-tab tab" do Snippets - -#%li{:class => "#{'active' if current_page?(project_repository_path(@project)) }"} - -#= link_to project_repository_path(@project) do - -#%span - -#Activities - %li{:class => "#{'active' if controller.controller_name == "hooks" }"} - = link_to project_hooks_path(@project) do - %span - Hooks - %li{:class => "#{'active' if controller.controller_name == "deploy_keys"}"} - - if can? current_user, :admin_project, @project + + - if can? current_user, :admin_project, @project + %li{:class => "#{'active' if controller.controller_name == "hooks" }"} + = link_to project_hooks_path(@project) do + %span + Hooks + %li{:class => "#{'active' if controller.controller_name == "deploy_keys"}"} = link_to project_deploy_keys_path(@project) do %span Deploy Keys -- cgit v1.2.3