Skip to Content
1
Former Member
Nov 07, 2014 at 11:53 AM

How can I show username at the headerItem on HANA SHELL

25 Views

Hi all,

I have solved this problem before with the below code:

Code:

var username = '';

jQuery.ajax({

url: "/sap/hana/xs/ide/editor/server/dbinfo.xsjs",

type: 'GET',

dataType: "json",

async:false,

success: function(data, s, xhr) {

if (xhr.getResponseHeader("x-sap-login-page")) {

return;

}

if (data) {

username = data.user;

}

},

});

But after that I created a new user which haven't got editor privilage so that this code become useless.

Can anybody help me about showing username on shell?


NOTE: I'm using sap.ui.ux3.Shell.