cancel
Showing results for 
Search instead for 
Did you mean: 

changing field properties base on business roles

jerome_lim
Participant
0 Kudos

Hi,

I am looking for a solution to solve the following problem.

I need to change a standard field in bp_head the properties base on the role.

1. for business role A, I need the field use a input field with search help, and I need to disable some other fields when data is returned from the ui.

2. for business role B, he will only see the input field with no search help.

What will be the best approach to achieve this ?

KR/Benjamin

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi Jerome,

1. To show search help based on business role use the following code in GET_V_XXX method of that field.

DATA: lr_profile TYPE REF TO if_crm_ui_profile,

           lv_role type TPARA-PARTEXT.

     lr_profile = cl_crm_ui_profile=>get_instance( ).

     lv_role = lr_profile->get_profile( ).

if lv_role = 'A'.

""code to attach search help.

endif.

Now for Business role A , you will see the search help.

2. To disable some fields based on business role, fetch business role (like in above code) on GET_I_XXX method of that field and set  rv_disabled to true for Business role A.

Thanks,

Ritu

Former Member
0 Kudos

Hi Jerome

This would not be accomplished via any standard configuration.

You should build a new SM30 Table to manage which roles can use the Search Help (alternatively custom authorisations), from my side the SM30 solution can be delivered much faster.

Then you'll need a developer to build in the relevant logic into the relevant UI View.

Hope this helps.

Regards

Arden