cancel
Showing results for 
Search instead for 
Did you mean: 

Personas 3.0: How to create a button that is enabled/disabled based on user's role?

Former Member
0 Kudos

Hi Personas 3.0 experts,

This maybe is a very straight forward question - I want add a button that is enabled for some users but disabled for some other users based on their role. Anyone know how to do this? Please write the steps here.

Thanks a lot!

Dong

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Well, you could always simply write a BAPI that rummages through the role and profile tables looking for the relevant thing and then have the onLoad script call it and set the button properties accordingly. If you really mean "role" here.

A more traditional solution would look for a specific authorisation, not a role, so the BAPI would just do an AUTHORITY CHECK.

Is that what you mean?

Steve.

Former Member
0 Kudos

Hi Steve,

Thanks for the reply. Your suggestion is surely working. Beyond that I was looking if there was a "direct" binding. Using RFC has overhead like ABAP programming and set FM Whitelist. But if there is no other way, RFC or calling tcode would be the only option.

By the way, is there any way of extending the Personas "button" class with new method, eg, "AttachRole" or "AttachAuth" so that everytime I create a button it will be just calling the method.

Thanks.

Dong

Answers (2)

Answers (2)

0 Kudos

create 2 flavors one with button and second without button and assign to specific roles

kaus19d
Active Contributor
0 Kudos

This message was moderated.

Former Member
0 Kudos

Hi Kaushik,

Thanks for the reply. The materials you mentioned are helpful. While, I am looking something different, see my reply to Steve. Thanks.

Dong