diff --git a/app/views/devise/registrations/_password_details.html.erb b/app/views/devise/registrations/_password_details.html.erb index 26cf54b..ef63ce6 100644 --- a/app/views/devise/registrations/_password_details.html.erb +++ b/app/views/devise/registrations/_password_details.html.erb @@ -1,43 +1,33 @@ -<%= form_for(resource, as: resource_name, url: registration_path(resource_name, tab: 'password-details-tab'), html: {method: :put, id: "password_details_registration_form", class: "form-horizontal"}) do |f| %> +<%= form_for(resource, as: resource_name, url: registration_path(resource_name, tab: 'password-details-tab'), html: {method: :put, id: "password_details_registration_form" }) do |f| %> -

<%= _('If you would like to change your password please complete the following fields.') %>

+

<%= _('If you would like to change your password please complete the following fields.') %>

<%= hidden_field_tag :skip_personal_details, "true" %> -
- <%= f.label(:current_password, _('Current password'), class: 'col-sm-2 control-label') %> -
- <%= f.password_field(:current_password, class: 'form-control', "aria-required": true ) %> +
+ <%= f.label(:current_password, _('Current password'), class: 'control-label') %> + <%= f.password_field(:current_password, class: 'form-control', "aria-required": true ) %> +
+ +
+ <%= f.label(:password, _('New password'), class: 'control-label') %> + <%= f.password_field(:password, class: 'form-control', "aria-required": true , id: 'user_new_password') %> +
+ +
+ <%= f.label(:password_confirmation, _('Password confirmation'), class: 'control-label') %> + <%= f.password_field(:password_confirmation, class: 'form-control', "aria-required": true, ) %> +
+ +
+
+
-
- <%= f.label(:password, _('New password'), class: 'col-sm-2 control-label') %> -
- <%= f.password_field(:password, class: 'form-control', "aria-required": true , id: 'user_new_password') %> -
-
- -
- <%= f.label(:password_confirmation, _('Password confirmation'), class: 'col-sm-2 control-label') %> -
- <%= f.password_field(:password_confirmation, class: 'form-control', "aria-required": true, ) %> -
-
- -
-
-
- -
-
-
- -
-
- <%= f.button(_('Save'), class: "btn btn-default", type: "submit") %> -
+
+ <%= f.button(_('Save'), class: 'btn btn-default', type: "submit") %>
<% end %> diff --git a/app/views/devise/registrations/_personal_details.html.erb b/app/views/devise/registrations/_personal_details.html.erb index 69db266..1995270 100644 --- a/app/views/devise/registrations/_personal_details.html.erb +++ b/app/views/devise/registrations/_personal_details.html.erb @@ -1,97 +1,79 @@ -<%= form_for(resource, as: resource_name, url: registration_path(resource_name, tab: 'personal-details-tab'), html: {method: :put, id: "personal_details_registration_form", class: "form-horizontal"}) do |f| %> +<%= form_for(resource, as: resource_name, url: registration_path(resource_name, tab: 'personal-details-tab'), html: {method: :put, id: 'personal_details_registration_form' }) do |f| %>

<%= _("Please note that your email address is used as your username. If you change this, remember to use your new email address on sign in.") %>

-

<%= _('You can edit any of the details below.') %>

- <%= hidden_field_tag :unlink_flag, "false", id: "unlink_flag" %> +

<%= _('You can edit any of the details below.') %>

+ <%= hidden_field_tag :unlink_flag, "false", id: 'unlink_flag' %> <%= hidden_field_tag :skip_personal_details, "false" %> -
- <%= f.label(:email, _('Email'), class: "col-sm-2 control-label") %> -
- <%= f.email_field(:email, class: "form-control", "aria-required": true, 'data-toggle': "tooltip", title: _('Please enter your current password below when changing your email address.'), value: @user.email) %> -
+
+ <%= f.label(:email, _('Email'), class: 'control-label') %> + <%= f.email_field(:email, class: 'form-control', "aria-required": true, 'data-toggle': "tooltip", title: _('Please enter your current password below when changing your email address.'), value: @user.email) %>
-
- <%= f.label(:firstname, _('First name'), class: "col-sm-2 control-label") %> -
- <%= f.text_field(:firstname, class: 'form-control', "aria-required": true, value: @user.firstname) %> -
+
+ <%= f.label(:firstname, _('First name'), class: 'control-label') %> + <%= f.text_field(:firstname, class: 'form-control', "aria-required": true, value: @user.firstname) %>
-
- <%= f.label(:surname, _('Last name'), class: "col-sm-2 control-label") %> -
- <%= f.text_field(:surname, class: 'form-control', "aria-required": true, value: @user.surname) %> -
+
+ <%= f.label(:surname, _('Last name'), class: 'control-label') %> + <%= f.text_field(:surname, class: 'form-control', "aria-required": true, value: @user.surname) %>
-
- <%= f.label(:recovery_email, _('Recovery email'), class: "col-sm-2 control-label") %> -
- <%= f.email_field(:recovery_email, class: 'form-control', "aria-required": true, 'data-toggle': "tooltip", title: _('This email will be used to recover your account if you change institutions'), value: @user.recovery_email) %> -
+
+ <%= f.label(:recovery_email, _('Recovery email'), class: 'control-label') %> + <%= f.email_field(:recovery_email, class: 'form-control', "aria-required": true, 'data-toggle': "tooltip", title: _('This email will be used to recover your account if you change institutions'), value: @user.recovery_email) %>
-
- <%= f.label(:password, _('Password'), class: "col-sm-2 control-label") %> -
- <%= f.password_field(:password, class: 'form-control', "aria-required": true) %> -
+
+ <%= f.label(:password, _('Password'), class: 'control-label') %> + <%= f.password_field(:password, class: 'form-control', "aria-required": true) %>
-
- <%= f.label(:org_name, _('Organisation'), class: "col-sm-2 control-label") %> -
- <%= render partial: "shared/accessible_combobox", - locals: {name: "#{resource_name}[org_name]", - id: "#{resource_name}_org_name", - default_selection: @default_org, - models: @orgs, - attribute: 'name', - classes: 'form-control'} %> +
+ <%= f.label(:org_name, _('Organisation'), class: 'control-label') %> + <%= render partial: "shared/accessible_combobox", + locals: {name: "#{resource_name}[org_name]", + id: "#{resource_name}_org_name", + default_selection: @default_org, + models: @orgs, + attribute: 'name'} %> - + -
- <% other_organisations = Org.where("parent_id IS ? AND is_other = ?", nil, true).pluck(:id) %> -
- <%= f.label _('Organisation name'), for: :other_organisation, class: "col-sm-2 control-label" %> - <%= f.text_field :other_organisation, :autocomplete => "off", class: 'form-control', 'data-toggle' => "tooltip", 'title': _('Please enter the name of your organisation.') %> -
+ <% other_organisations = Org.where("parent_id IS ? AND is_other = ?", nil, true).pluck(:id) %> +
+ <%= f.label _('Organisation name'), for: :other_organisation, class: 'control-label' %> + <%= f.text_field :other_organisation, :autocomplete => "off", class: 'form-control', 'data-toggle' => "tooltip", 'title': _('Please enter the name of your organisation.') %>
<% if MANY_LANGUAGES %> -
+
<% lang_id = current_user.language.nil? ? Language.id_for(FastGettext.default_locale) : current_user.language.id %> - <%= f.label(:language_id, _('Language'), class: "col-sm-2 control-label") %> -
- <%= select_tag("user[language_id]", - options_from_collection_for_select(@languages, "id", "name", lang_id), - class: "form-control") %> -
+ <%= f.label(:language_id, _('Language'), class: 'control-label') %> + <%= select_tag("user[language_id]", + options_from_collection_for_select(@languages, "id", "name", lang_id), + class: 'form-control') %>
<% end %> <% @identifier_schemes.each do |scheme| %> -
+
<% if scheme.name == 'shibboleth' %> -