diff options
author | Valery Sizov <vsv2711@gmail.com> | 2015-10-01 17:33:05 +0300 |
---|---|---|
committer | Valery Sizov <vsv2711@gmail.com> | 2015-10-02 12:48:57 +0300 |
commit | 731b860976772111ca673ba25aeadd3634adbe7d (patch) | |
tree | ffbd6d5f612b80448067ddc4d7e80cb9b6cb7fe5 /app/views/shared/_field.html.haml | |
parent | 2fa89a3dc6a7580969203e43808048b79f172c0c (diff) |
Hide password in the service settings form
Diffstat (limited to 'app/views/shared/_field.html.haml')
-rw-r--r-- | app/views/shared/_field.html.haml | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/app/views/shared/_field.html.haml b/app/views/shared/_field.html.haml index 45ec49280d2..8d6e16f74c3 100644 --- a/app/views/shared/_field.html.haml +++ b/app/views/shared/_field.html.haml @@ -8,7 +8,10 @@ - help = field[:help] .form-group - = form.label name, title, class: "control-label" + - if type == "password" && value.present? + = form.label name, "Change #{title}", class: "control-label" + - else + = form.label name, title, class: "control-label" .col-sm-10 - if type == 'text' = form.text_field name, class: "form-control", placeholder: placeholder @@ -19,6 +22,6 @@ - elsif type == 'select' = form.select name, options_for_select(choices, value ? value : default_choice), {}, { class: "form-control" } - elsif type == 'password' - = form.password_field name, value: value, class: 'form-control' + = form.password_field name, autocomplete: "new-password", class: 'form-control' - if help %span.help-block= help |