[owncloud-devel] get display and login name
blizzz at owncloud.com
Mon Jan 18 14:05:36 GMT 2016
On Mittwoch, 13. Januar 2016 11:49:44 CET Klaus Herberth wrote:
> I implemented a auto-completion field for my app jsxc which requires
> to get the display and login names according to an entered string. I
> thought the user id is always the same as the login name and therefore
> I used the OCP\User::getDisplayNames function.
> But login name and uid is only equal in the internal backend and now I
> am looking for a solution that works also with other backends like ldap.
> Is there a better way as to:
> - check the backend type
> - get uids
> - map every uid to a login name
> to get a tuple of login name and uid?
Bad news for you: Nope, login names are not stored centrally and backends also
do not offer a way to look up login names. Also I fail to see a cheap or new
solution (other than requiring the LDAP admin to also include the login name
attributes in the user search attributes and just use the user search to
accomplish the task).
The share dialog, for instance, is also looking up users like this.
> Devel mailing list
> Devel at owncloud.org
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
Q: What is the most annoying thing in e-mail?
XMPP: blizzz at jabber.arthur-schiwon.de
www.owncloud.com - Your Data, Your Cloud, Your Way!
ownCloud GmbH, GF: Markus Rex, Holger Dyroff, Frank Karlitschek
Schloßäckerstrasse 26a, 90443 Nürnberg, HRB 28050 (AG Nürnberg)
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 819 bytes
Desc: This is a digitally signed message part.
More information about the Devel