[EMAIL PROTECTED] wrote: > In the user_services.xhtml, the label.loggedAsUser refers to the *name* > property of the nuxeoPrincipal contained in the context. In our case > (LDAP context) the name is the login and is not very self explanatory > for other users since it is a big number (10024597 for instance). > > I'd like to replace it with the concatenated string firstName + > lastName. I could replace only in the label, but the problem is the same > for other parts of the webapp (author of documents for instance). > > The solution would be to inherit our own LMUserPrincipal from the > UserPrincipal and replace the getName method to refer what we need. I > guess there will be side effects in the login module since it uses the > name property of the UserPrincipal to authenticate.... I should also > inherit from the JBossLoginModule to put the modification.... > > What do you think of those modifications ?
I don't think this is good idea. the getName() should return the
principal id. All code at app level expects this. For me, this is pure
UI issue.
What we could do to tackle this could be just to extend the API of the
listener dealing with user and groups to provide a convenient method to
get the fullname.
public String getFullNameFor(String principalName);
public String getFullNameFor(NuxeoPrincipal principal);
or something like that we could use from the jsf and from other listeners.
Of course, this is a legitimate request...
What do you think ?
Cheers,
J.
--
Julien Anguenot | Nuxeo R&D (Paris, France)
Open Source ECM - http://www.nuxeo.com
Nuxeo 5 : http://www.nuxeo.org
Mobile: +33 (0) 6 72 57 57 66
signature.asc
Description: OpenPGP digital signature
_______________________________________________ ECM mailing list [EMAIL PROTECTED] http://lists.nuxeo.com/mailman/listinfo/ecm
