Professional Documents
Culture Documents
Note:
a. All the enhancement mentioned in this document should be created in Customer Namespace
and should be saved in a Custom Package
b. It is recommended to create Z-object with same name as shown in screen shots.
To enhance the interface, select the “Interface” from the menu options and choose the
“Enhance” option as per below screenshots:
Provide the “Enhancement Implementation” and “Short Text” then press continue.
Go to Attributes tab and add instance attribute GT_ATTRIBUTE_INDICATOR with below details
Screen shot:
2. Creation of new method ZWUI_ON_BEFORE_OUTPUT along with methods DO_REQUEST and
IF_BSP_CONTROLLER~HANDLE_EVENT enhancement in class CL_BSP_WD_VIEW_CONTROLLER
Select the menu option “Class” and choose “Enhance” to create the enhancement
implementation.
Provide the “Enhancement Implementation” name and “Short Text” then press continue.
Provide the description “Before Output Event” in popup prompted then select the check box
“Event Handler for” and mention the class “CL_BSP_WD_VIEW_CONTROLLER” along with event
“BEFORE_OUTPUT” then click on change button as shown in below screenshot:
The method should show an event attached to it as shown below:
IF sender IS BOUND.
" Context.
TRY.
ASSIGN sender->('CONTEXT') TO <lr_context>.
CATCH cx_root.
RETURN.
ENDTRY.
IF <lr_context> IS ASSIGNED.
ENDIF.
To create implicit enhancement at the start of method DO_REQUEST, click on “Enhance” button
as marked in below screenshot:
Place the cursor over marked line shown for Implicit Enhancement Option and click on button
“Create” to create Enhancement Implementation as per below screenshot:
Choose Enhancement Mode as “Code”:
To create implicit enhancement at the start of method, click on “Enhance” button as marked
below:
Note: You may refer step2 which contains the detail steps to create an enhancement
implementation of class
Add two parameters er_owner and ev_id to the new method UIMWUI_GET_DETAILS.
Go to the parameters of method, add two exporting parameters ER_OWNER and EV_ID by
providing associated type as shown below:
Screen shot:
Insert the following lines of code inside newly created method uimwui_get_details:
METHOD uimwui_get_details.
er_owner = owner.
ev_id = id.
ENDMETHOD.
Screen shot:
4. Enhancement of method GET_S_STRUCT of class CL_BSP_WD_CONTEXT_NODE
To save the details in a log table for field access tracking for a configured field, create
enhancement in method DO_REQUEST of Class CL_BSP_WD_VIEW_MANAGER.
Screen shot:
To perform masking for unauthorized user on the CRM Tree, create implicit enhancement at the
end of the method GET_T_TABLE in class CL_BSP_WD_CONTEXT_NODE_TREE
Insert the following lines of code inside implicit enhancement:
Screen shot: