diff options
author | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2013-11-27 10:32:37 +0200 |
---|---|---|
committer | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2013-11-27 10:32:37 +0200 |
commit | b2e4664cc78d61ec058e81f37cdff11636b02967 (patch) | |
tree | 090ad0589d9b7cbd40cbbc17c2b118f3bbf4214a /app/views/profiles/show.html.haml | |
parent | 44c55307a0dc1d011cb9deabb2f1d631ebd2cb63 (diff) | |
download | gitlab-ce-b2e4664cc78d61ec058e81f37cdff11636b02967.tar.gz |
Read-only email field for LDAP user
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
Diffstat (limited to 'app/views/profiles/show.html.haml')
-rw-r--r-- | app/views/profiles/show.html.haml | 18 |
1 files changed, 12 insertions, 6 deletions
diff --git a/app/views/profiles/show.html.haml b/app/views/profiles/show.html.haml index d382d2d70c4..c22e00d3d77 100644 --- a/app/views/profiles/show.html.haml +++ b/app/views/profiles/show.html.haml @@ -21,16 +21,22 @@ .controls = f.text_field :name, class: "input-xlarge", required: true %span.help-block Enter your name, so people you know can recognize you. + .control-group = f.label :email, class: "control-label" .controls - = f.text_field :email, class: "input-xlarge", required: true - - if @user.unconfirmed_email.present? - %span.help-block - We sent confirmation email to - %strong #{@user.unconfirmed_email} + - if @user.ldap_user? + = f.text_field :email, class: "input-xlarge", required: true, readonly: true + %span.help-block.light + Email is read-only for LDAP user - else - %span.help-block We also use email for avatar detection if no avatar is uploaded. + = f.text_field :email, class: "input-xlarge", required: true + - if @user.unconfirmed_email.present? + %span.help-block + We sent confirmation email to + %strong #{@user.unconfirmed_email} + - else + %span.help-block We also use email for avatar detection if no avatar is uploaded. .control-group = f.label :skype, class: "control-label" .controls= f.text_field :skype, class: "input-xlarge" |