cancel
Showing results for 
Search instead for 
Did you mean: 

retrieving EP roles from web dynpro

christopher_griffin
Participant
0 Kudos

Hello

I'm sure this is a common problem but I've checked all the older posts and I just can't get it working.

We have a web dynpro app that runs within an EP iView (EP6SP14), and we need to retrieve the portal roles for the user.

With the APIs (using IRole and IUser and the getRoles() method) we only get the J2EE roles. These are not the same.

Can anyone help?

Thanks

Chris

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Christopher,

I think th following blog refers to the problem you are facing.

/people/preksha.malhotra/blog/2006/12/12/accessing-a-web-dynpro-application-through-portal-using-portal-user-id

Regards,

Alka.

Answers (2)

Answers (2)

Former Member
0 Kudos

hi,

Check out this thread.

Regards,

Gopi

ingo_hauchwitz
Explorer
0 Kudos

Hi Chris,

have you tried to read the groups of your user? As far as i know, the roles from EP are mapped to the groups in J2EE.

Try something like this:

IWDClientUser user = WDClientUser.getCurrentUser();
Iterator groups = user.getSAPUser().getParentGroups(false);

while (groups.hasNext()) {
  String bez = UMFactory.getGroupFactory().getGroup((String) groups.next()).getDisplayName();
  // bez contains your roles (groups)
}

i hope that helps

regards

ingo