Feature #5289

Add Initials to options in 'User Display' settings

Added by Simon Pickles over 7 years ago. Updated over 7 years ago.

Status:NewStart date:2010-04-10
Priority:NormalDue date:
Assignee:-% Done:

0%

Category:UI
Target version:-
Resolution:

Description

Please could I request an option for Initials option in User Display? Use of Initials is a normal business model for fast identification.

Especially useful would be to add middle names to help uniqueness. Eg SDSP in my case, not just SP

History

#1 Updated by Felix Schäfer over 7 years ago

I already treated (or not for that matter, as the OP never replied it seems) a similar question over on the forum, so if you feel comfortable maintaining a small code change on your redmine until this gets in stable, head there.

#2 Updated by Simon Pickles over 7 years ago

Felix Schäfer wrote:

I already treated (or not for that matter, as the OP never replied it seems) a similar question over on the forum, so if you feel comfortable maintaining a small code change on your redmine until this gets in stable, head there.

Hi, I had a look at the forum link but I don't see any instructions for code changes. Could you give me directions? Thanks

#3 Updated by Eric Thomas over 7 years ago

If the login name is your initials, then you can do this by going to Administration-->Settings-->Display-->Users display format and selecting the login name.

#4 Updated by Simon Pickles over 7 years ago

Eric Thomas wrote:

If the login name is your initials...

This had occurred to me, but I am reluctant to ask all our users to switch login names!

#5 Updated by Felix Schäfer over 7 years ago

Simon Pickles wrote:

Hi, I had a look at the forum link but I don't see any instructions for code changes. Could you give me directions? Thanks

Add a new line to USER_FORMATS in source:trunk/app/models/user.rb#L28, for initials e.g. something like :initials => '#{firstname[0,1]}.#{lastname[0,1]}.', (or :initials => '#{(firstname + " " + lastname).split(/-|\s/).collect{ |x| x[0,1] + "." }.join},' if you want to handle names with spaces and/or dashes in them), that should give you an added option in the display settings that shows the first character of the first and last name with dots (i.e. F.S. for me).

Please note that you will probably need to restart your rails server for this change to take effect, and that I have only quickly tested the string handling stuff in the second proposal but not in an actual redmine.

EDIT: Forgot a , at the end of the second solution.

Also available in: Atom PDF