You can use this Business Add-In (BAdI) to replace the SAP standard authorization check for HR master data and infotypes with a customer-specific check.
You want to deny specific users access to specific personnel numbers. For example, you may want to prevent an administrator from processing his own, or his wife's salary data. You can only set up a special rule for one personnel number per user in the standard SAP system.
In this case, you could, for example, copy the standard SAP authorization check (class CL_HRPAD00AUTH_CHECK_STD ), and then adjust the copy to meet your requirements. You can then use this copy as a BAdI, to replace the standard SAP authorization checks.
Alternatively, you could implement your authorization check so that the functions you require (which are already in the standard SAP version) are delegated to the standard class. You would then only need to implement the additional functions that you require. (decorative template)
The BAdI is not implemented in the standard SAP system. If you do not implement it, the SAP system uses the standard authorization checks HR master data and infotypes.
After calling up the IMG activity, a dialog box appears, in which you can enter a name for the implementation.
If you have already made other implementations for this BAdI, another dialog box appears, in which the existing implementations are displayed. In this case, choose Create , and proceed as follows:
Interface
Method : Maximum Check for Infotype Authorization
Method : Maximum Check for Authorization Level
Method : Maximum Check for Subtype Authorization
Method : Minimum Check for Authorization Level
Method : Minimum Check for Subtype Authorization
Method: Set Organizational Assignment
Method: Set Partial Organizational Assignment
Method: Authorization Check
Method : Maximum Check for Personnel Number Authorization
Method : Minimum Check for Personnel Number Authorization
Method: Check Personnel Number Authorization
Method: Replacement for CONSTRUCTOR
You can use the classes used in the standard SAP system (CL_HRPAD00AUTH_CHECK_STD and CL_HRPAD00AUTH_CHECK_FAST) as a basis for your implementation.
For more information on using Business Add-Ins,
refer to the SAP Library under Basis Components ->ABAP
Workbench (BC-DWB) ->Changing the SAP Standard (BC)->Business
Add-Ins.