summaryrefslogtreecommitdiff
path: root/app/views/profile
diff options
context:
space:
mode:
Diffstat (limited to 'app/views/profile')
-rw-r--r--app/views/profile/_top_menu.html.haml5
-rw-r--r--app/views/profile/index.html.haml1
-rw-r--r--app/views/profile/password.html.haml20
-rw-r--r--app/views/profile/show.html.haml8
4 files changed, 34 insertions, 0 deletions
diff --git a/app/views/profile/_top_menu.html.haml b/app/views/profile/_top_menu.html.haml
new file mode 100644
index 00000000000..6bf3b09f499
--- /dev/null
+++ b/app/views/profile/_top_menu.html.haml
@@ -0,0 +1,5 @@
+%div.top_project_menu
+ %span= link_to "Profile", profile_path, :class => current_page?(:controller => "profile", :action => :show) ? "current" : nil
+ %span= link_to "Password", profile_password_path, :style => "width:70px;", :class => current_page?(:controller => "profile", :action => :password) ? "current" : nil
+ %span= link_to "Keys", keys_path, :class => controller.controller_name == "keys" ? "current" : nil
+
diff --git a/app/views/profile/index.html.haml b/app/views/profile/index.html.haml
new file mode 100644
index 00000000000..84174ac5be7
--- /dev/null
+++ b/app/views/profile/index.html.haml
@@ -0,0 +1 @@
+%h1 Profile
diff --git a/app/views/profile/password.html.haml b/app/views/profile/password.html.haml
new file mode 100644
index 00000000000..f77d3855364
--- /dev/null
+++ b/app/views/profile/password.html.haml
@@ -0,0 +1,20 @@
+%p Note: after success password update you will be redirected to login page where you should login with new password
+= form_for @user, :url => profile_password_path, :method => :put do |f|
+ -if @user.errors.any?
+ #error_explanation
+ %h2= "#{pluralize(@user.errors.count, "error")} prohibited this password from being saved:"
+ %ul
+ - @user.errors.full_messages.each do |msg|
+ %li= msg
+
+ .div
+ = f.label :password
+ %br
+ = f.password_field :password
+ .div
+ = f.label :password_confirmation
+ %br
+ = f.password_field :password_confirmation
+ .actions
+ = f.submit 'Save', :class => "lbutton vm"
+
diff --git a/app/views/profile/show.html.haml b/app/views/profile/show.html.haml
new file mode 100644
index 00000000000..12737ba8143
--- /dev/null
+++ b/app/views/profile/show.html.haml
@@ -0,0 +1,8 @@
+.span-2
+ = image_tag gravatar_icon(@user.email), :class => "left", :width => 60, :style => "padding-right:5px;"
+%p
+ %b Name:
+ = @user.name
+%p
+ %b Email:
+ = @user.email