Skip to Content
0

Plant wise F4 Help restriction for end users in SAP S4/Hana

Dec 07, 2017 at 07:53 AM

72

avatar image

Dear Experts,

Our team faces a following issue, we have three plants in the company code 1001,1002 and 1003. So when a user from 1001 plant presses F4 help option anywhere in their SAP S4Hana,then it must display values corresponding only to their plant. For instance 1001 user must be able to view only their 1001 plant details like materials,production orders etc etc..in F4 help.

Client is very specific about this issue.

Kindly help me, thanks in advance.

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

1 Answer

Raymond Giuseppi
Dec 07, 2017 at 08:30 AM
1

For such requirement (filters on search help) I created once an Enhancement Implementation in function group SDSD which manages such search helps. I put my code at explicit ehnancement points at start (save maxrecords) and end (remove some records) of forms GET_VALUES_SH and GET_FALUES_FV (for search help and domain values) there I called my own BAdIs (*) with filter on search help or domain name. Then me and other Abaper can implement our own filters on most search helps implemeting those BAdI, using, for example, some authority-check or any depending filter.

For sample: end of GET_VALUES_FV

enhancement 3  z_sh_hide.    "active version
* allow specific implentation of filter on search-help
  data: lo_handle type ref to z_fv_hide, " Ehn Spot defined with SE18
        lv_domname type domname.
* Map search help name to domain name
lv_domname = shlp-shlpname. 
* Look for BAdI implementation and call it
get badi lo_handle
  filters
    domname = lv_domname.
call badi lo_handle->change_value_tab
  exporting
    shlp      = shlp
  changing
    value_tab = record_tab[].
* apply max records
if lv_maxrows <> 0.
  add 1 to lv_maxrows.
  delete record_tab from lv_maxrows.
endif.
endenhancement.

As can be seen the method CHANGE_VALUE_TAB has a SHLP (SHP_DESCR_T) importing and a VALUE_TAB (DDSHRESLTS) changing parameters.

Show 3 Share
10 |10000 characters needed characters left characters exceeded

Hello Raymond,

Thanks for your prompt reply. I'll show this to my technical team, discuss with them regarding this and revert back soon.

Regards,

Jeffrey.

0

Hello Raymond,

Is this above mentioned program needs to be done for each and every field in SAP? Is there any global setting for this restriction,so that if you maintain there then correspondingly it will effect in all fields?

0

The first implementation which 'create' the BAdI is done only once. Then created some implementation of the z-BAdI with filter values resulting in some sets of search-helps.

You could remove the filter in get badi and create the z-BAdI without filter, so ever implementation will be called. Or you could even filter immediately the data without using any z-BAdI, all your code will be in one point, and less maintanable?

1