Redirect Customer related GUI transactions (XD01/XD02) to MDG Customer Maintenance
While I was surfing through few S/4 systems, I came across a behavior in a system (1511), whenever I have executed the transaction XD01 or XD02, it is redirected to transaction ‘BP’
Initially I thought it was a configuration, later I figured it out as SAP hard coding.
Recently I got a requirement to redirect XD01/XD02 to MDG Customer Maintenance Screens as we have implemented MDG and Business wanted either create/change has to happen from MDG Portal not from backend XD01/XD02 transactions.
I recalled that I have seen behavior of redirecting XD01 transaction to BP somewhere, later I understood that it is not a part of configuration but it is S/4 HANA code.
I have used BADI to call piece of code mentioned below to redirect XD01 to MDG Customer Maintenance Screen.
My Approach towards the Solution:
**–Get the Base URL of the System
DATA(lv_url) = cl_nwbc=>url_base( ).
**–Concatenate SAP MDG Customer Role to URL CONCATENATE lv_url ‘~roletest/SAP_MDGC_CL_MENU_04/?sap-nwbc-node=root’
**–Call the URL
CALL METHOD cl_nwbc=>url_launch( lv_url ).
**–Exit the Current Transaction
LEAVE TO TRANSACTION ‘SMEN’.
With this Similar Approach, we can redirect all GUI transactions for Customer/Vendor/Material/FI related transaction to MDG Portal.