/* ******************************************************************
Function: getAuthorizations
Parameters:
Purpose: Calls function to read user SAP Profile
****************************************************************** */
function getAuthorizations(){
call('BAPI_USER_GET_DETAIL', {"in.USERNAME":"&V[_user]","table.PROFILES":"Z_PROFILES"});
}
/* ******************************************************************
Function: profileExists
Parameters:
profileName
Purpose: Checks to see if current user has the profileName match
****************************************************************** */
function profileExists(profileName) {
for (ii = 0; ii < Z_PROFILES.length; ii++) {
if(profileName == Z_PROFILES[ii].toString().substring(0,12).trim()) {
return true;
}
}
return false;
}