cancel
Showing results for 
Search instead for 
Did you mean: 

Access class concept: application/foundation layer

hannes_henninger
Explorer
0 Kudos

Hi everybody,

I need some help regarding the acces class concept in MDG.

"The master class is the one beeing called by the MDG framework. Its object instance actually depends on the current software layer is it running in. In the MDG foundation layer, it is a reference of class CL_MDG_BS_FND_ACCESS whereas in the MDG application layer it is a reference of class CL_MDG_BS_ECC_ACCESS..."  from SAP Guide - Extend the MDG Business Partner

While debugging I found out the object instance is always of class CL_MDG_BS_ECC_ACCESS - even if I'm just creating a business partner (and no customer/supplier). In this case - for my understanding - it should be of of class CL_MDG_BS_FND_ACCESS?

So I'm wondering: is it always running on application layer?

In the master class CL_MDG_BS_BP_ACCESS_MASTER-DELIVER_ACCESS_CLASS_NAME

it's checking for the required access class in line 23:

*   if customer or supplier (EhP5 or EhP6) is active then use ECC access class

     IF cl_abap_switch=>get_switch_state( 'MDG_BS_BP_SWITCH_01' ) = 'T'.     "On

     ...


This seems to be always true. Is this a general system setting? Meaning sth like: the system is using customer and supplier functions, therefore just use application layer?

Kind regards,

Hannes



Accepted Solutions (0)

Answers (1)

Answers (1)

former_member196830
Active Participant
0 Kudos

Hey Hannes,

The way the Suppier (Vendor) and Custom MDG works is it always creates the Business Partner first. Depending on your version of MDG it might be slightly different, but the CL_MDG_BS_ECC_ACCESS is always called in order to save the BP.

Once BP is saved, based on your CVI configuration, a Supplier or Customer would be created copying big chunk of the BP and enhancing it with the specific data from the Change Request.

Hope that explains why the class is always called

Regards,

Boris