Skip to content
Snippets Groups Projects
Commit bd86796d authored by Ruben Davila's avatar Ruben Davila
Browse files

Add support to change language in profile form

parent acc807cd
No related branches found
No related tags found
No related merge requests found
Loading
Loading
@@ -85,7 +85,8 @@ class ProfilesController < Profiles::ApplicationController
:twitter,
:username,
:website_url,
:organization
:organization,
:preferred_language
)
end
end
Loading
Loading
@@ -72,6 +72,9 @@
= f.label :public_email, class: "label-light"
= f.select :public_email, options_for_select(@user.all_emails, selected: @user.public_email), { include_blank: 'Do not show on profile' }, class: "select2"
%span.help-block This email will be displayed on your public profile.
.form-group
= f.label :preferred_language, class: "label-light"
= f.select :preferred_language, Gitlab::I18n::AVAILABLE_LANGUAGES, {}, class: "select2"
.form-group
= f.label :skype, class: "label-light"
= f.text_field :skype, class: "form-control"
Loading
Loading
module Gitlab
module I18n
AVAILABLE_LANGUAGES = [
[_('English'), 'en'],
[_('Spanish'), 'es'],
[_('Deutsch'), 'de']
]
end
end
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment