diff options
author | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2012-10-30 08:40:12 +0000 |
---|---|---|
committer | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2012-10-30 08:40:12 +0000 |
commit | 399223daba6f993775fe783828b6612747e7a89f (patch) | |
tree | 85c10bb0c00ea4c8cadbd40545bda962e522e1a0 /app/models/user.rb | |
parent | cdc8944a89af65405564dd196d237baf2e6bb59d (diff) | |
download | redmine-399223daba6f993775fe783828b6612747e7a89f.tar.gz redmine-399223daba6f993775fe783828b6612747e7a89f.zip |
New user name format: firstname + first letter of lastname (#12085).
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@10770 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app/models/user.rb')
-rw-r--r-- | app/models/user.rb | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/app/models/user.rb b/app/models/user.rb index 87db4eb5a..6702b7e58 100644 --- a/app/models/user.rb +++ b/app/models/user.rb @@ -33,30 +33,35 @@ class User < Principal :order => %w(firstname lastname id), :setting_order => 1 }, + :firstname_lastinitial => { + :string => '#{firstname} #{lastname.to_s.chars.first}.', + :order => %w(firstname lastname id), + :setting_order => 2 + }, :firstname => { :string => '#{firstname}', :order => %w(firstname id), - :setting_order => 2 + :setting_order => 3 }, :lastname_firstname => { :string => '#{lastname} #{firstname}', :order => %w(lastname firstname id), - :setting_order => 3 + :setting_order => 4 }, :lastname_coma_firstname => { :string => '#{lastname}, #{firstname}', :order => %w(lastname firstname id), - :setting_order => 4 + :setting_order => 5 }, :lastname => { :string => '#{lastname}', :order => %w(lastname id), - :setting_order => 5 + :setting_order => 6 }, :username => { :string => '#{login}', :order => %w(login id), - :setting_order => 6 + :setting_order => 7 }, } |