OnDemand User Group
Support Forums => Content Navigator => Topic started by: Andreas Baaserud Hauge on September 15, 2023, 01:26:24 AM
-
Hi,
I am working on a Content Navigator Plugin where I need to get hold of the user id for the logged in user in Content Navigator.
Does anyone have any clue how I can achieve this?
Love your reply <3
-
Here's what I did to get hold of the user id through Java
# Preliminary - Passing PluginServiceCallbacks callbacks Plugin
# get hold of the ODServer object by the repositoryID
ODServer server = callbacks.getODServer(repositoryId);
# Now we can retrieve user info
String userId = server.getUserId();
Through Javascript can use something like ecm.model.desktop.userId