Ansicht
Dokumentation
CFX_API_FLDGRP_AUTH_SET - Sets field group authorizations for a generic object instance
BAL_S_LOG - Application Log: Log header data SUBST_MERGE_LIST - merge external lists to one complete list with #if... logic for R3upThis documentation is copyright by SAP AG.
Functionality
Sets the field group authorizations for a field group of a generic object instance on the basis of the following input parameters:
I_OBJECT_ID : <
I_FIELDGROUP_ID : <
I_FIELDGROUP_NS : << The field group Namespace as specified for the given
fieldgroup in the
I_FIELDGROUP_INT_ID : << the internal ID of the field group>>
I_USER_ACTIVITIES : Internal table which holds USER_ID of type ACO_USER_ID and ACTIVITY of type ACO_ACTVT
I_USER_ROLE_ACTIVITIES Internal table which holds USER_ID of type ACO_ROLE_ID and ACTIVITY of type ACO_ACTVT
I_USER_GRP_ACTIVITIES Internal table which holds USER_ID of type ACO_USER_GROUP_ID and ACTIVITY of type ACO_ACTVT
The options for ACTIVITY are 'Admin' , 'Write' / 'Read' or 'NoAuth'.
Example
This example will give you an idea how to use this API.
Create a class 'Z_TEST_FG_AUTHORIZATION_APIS' and create method 'SET_FG_AUTH' to call the function module CFX_API_FLDGRP_AUTH_SET
method SET_FG_AUTH.
,, data : lt_user_activities type CFX_API_TT_USER_AUTH,
ls_user_activities type CFX_API_TS_USER_AUTH.
ls_user_activities-user_id = '.'. "Some Sample User
ls_user_activities-activity = 'Read'."User Activity such as 'Read' / 'Write' / 'Admin' /'NoAuth'
append ls_user_activities to lt_user_activities.
CALL FUNCTION 'CFX_API_FLDGRP_AUTH_SET'
EXPORTING
I_OBJECT_ID = I_OBJECT_ID "the internal ID of the Generic Object
I_FIELDGROUP_ID = I_FIELDGROUP_ID "The field group ID as specified for the given fieldgroup in the <
I_FIELDGROUP_NS = I_FIELDGROUP_NS " The field group name as specified for the given fieldgroup in the
I_FIELDGROUP_INT_ID = I_FIELDGROUP_INT_ID "The internal ID of the field group , this input needs to be provided only if the first three are not provided
IMPORTING
ES_FAULT ,,,,,,= ES_FAULT
E_FAULTSTRING ,,,,= E_FAULT_STRING
TABLES
I_USER_ACTIVITIES = lt_USER_ACTIVITIES
I_USER_ROLE_ACTIVITIES = I_USER_ROLE_ACTIVITIES
I_USER_GRP_ACTIVITIES = I_USER_GRP_ACTIVITIES
.
*ES_FAULT and E_FAULTSTRING holds the error information in case the authorizations were not set.
endmethod.
Parameters
ES_FAULTE_FAULTSTRING
I_FIELDGROUP_ID
I_FIELDGROUP_INT_ID
I_FIELDGROUP_NS
I_OBJECT_ID
I_USER_ACTIVITIES
I_USER_GRP_ACTIVITIES
I_USER_ROLE_ACTIVITIES
Exceptions
Function Group
CFX_API_OBJ_FLDGRP_AUTHCPI1466 during Backup CL_GUI_FRONTEND_SERVICES - Frontend Services
This documentation is copyright by SAP AG.
Length: 3315 Date: 20240523 Time: 112510 sap01-206 ( 41 ms )