diff options
author | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2015-03-31 04:19:01 +0300 |
---|---|---|
committer | Robert Speicher <rspeicher@gmail.com> | 2015-05-09 17:31:10 -0400 |
commit | de9e1c3bad18e4ca00cfdced75e5cc4c42905761 (patch) | |
tree | 5055c3d39cfda527139deda9758a8ee87ac5f03c /app/views/profiles/accounts/show.html.haml | |
parent | 50a2a229e7b8b789a199bd0cf84ce76d25201198 (diff) | |
download | gitlab-ce-de9e1c3bad18e4ca00cfdced75e5cc4c42905761.tar.gz |
Turn 2-factor authentication into 2 steps process. Disabled 2fa UI for ldap users since it is not supported
Diffstat (limited to 'app/views/profiles/accounts/show.html.haml')
-rw-r--r-- | app/views/profiles/accounts/show.html.haml | 31 |
1 files changed, 16 insertions, 15 deletions
diff --git a/app/views/profiles/accounts/show.html.haml b/app/views/profiles/accounts/show.html.haml index 19b0c5bcb41..dcce29a81f4 100644 --- a/app/views/profiles/accounts/show.html.haml +++ b/app/views/profiles/accounts/show.html.haml @@ -26,21 +26,22 @@ %span You don`t have one yet. Click generate to fix it. = f.submit 'Generate', class: "btn success btn-build-token" - %fieldset - %legend Two-Factor Authentication - %p - Keep your account secure by enabling two-factor authentication. - %br - Each time you log in, you’ll be required to provide your password plus a randomly generated access code. - %div - - if current_user.otp_required_for_login - %strong.text-success - %i.fa.fa-check - 2-Factor Authentication enabled - .pull-right - = link_to "Disable 2-Factor Authentication", profile_two_factor_auth_path, method: :delete, class: 'btn btn-close btn-sm' - - else - = link_to "Enable 2-Factor Authentication", new_profile_two_factor_auth_path, class: 'btn btn-success' + - unless current_user.ldap_user? + %fieldset + %legend Two-Factor Authentication + %p + Keep your account secure by enabling two-factor authentication. + %br + Each time you log in, you’ll be required to provide your password plus a randomly generated access code. + %div + - if current_user.otp_required_for_login + %strong.text-success + %i.fa.fa-check + 2-Factor Authentication enabled + .pull-right + = link_to "Disable 2-Factor Authentication", profile_two_factor_auth_path, method: :delete, class: 'btn btn-close btn-sm' + - else + = link_to "Enable 2-Factor Authentication", new_profile_two_factor_auth_path, class: 'btn btn-success' - if show_profile_social_tab? %fieldset |