cancel
Showing results for 
Search instead for 
Did you mean: 

sap ui5 api to Username

vivek_agrawal2
Participant
0 Kudos

Hi

Is there any sapui5 library which i can use to get the logged on sso user in HTML5 application on HANA Cloud Platform.

Accepted Solutions (1)

Accepted Solutions (1)

jamie_cawley
Advisor
Advisor
0 Kudos

Please see

Regards,

Jamie

SAP - Technology RIG

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi

You could try the following if you are using the Launchpad.

sap.ushell.Container.getService("UserInfo")

sap.ushell.Container.getService("UserInfo").getId()

Cheers

Andrew

Former Member
0 Kudos

vivek_agrawal2
Participant
0 Kudos


Hi Robbe

This blog talks about BSP Applications which i dont have any idea.

Can you tell me how to get the user info if I am developing a SAPUI5 application on  SAP HANA Cloud Platform .

Former Member
0 Kudos

Have you tried it?

var oModel= new sap.ui.model.json.JSONModel();

oModel.loadData("http://<server host>:<server port>/sap/bc/ui2/start_up");

var myFullName = oModel.getData().fullname;

NagaPrakashT
Contributor
0 Kudos

Hi Vivek,

Below are the HANA tables in which user information is stored,May be you can build XSODATA service around it.

USERS - All Users

USER_PARAMETERS - All parameters and their values, which have been assigned to users in the system

Thanks,

Naga