天天看点

如何在SAP S/4HANA里创建自定义的partner function

Requirement: create custom partner function and consume it in Service scenario in S/4HANA for Customer Management.

As introduced in my blog One Order Partner Component model in S/4HANA for Customer Management, there are corresponding fields in flat table CRMS4D_SERV_H which stores the ID of different party roles. How about if customers would like to create their own partner functions and maintain some business partners based on those custom partner functions?

如何在SAP S/4HANA里创建自定义的partner function

Here below are the steps in detail.

(1) Create a new extension field with type Text and length equals to 10. For detail please refer to my blog One order extensibility in S4HANA for Customer Management.

如何在SAP S/4HANA里创建自定义的partner function

Find the technical name of this extension field in backend: ZZ1_JERRYCUSTOMPARTNER_SRH

如何在SAP S/4HANA里创建自定义的partner function

(2) Create a custom partner function Z0000002:

如何在SAP S/4HANA里创建自定义的partner function

tcode SM30, maintain table CRMS4C_PARTNER:

maintain the extension field name and custom partner function ID as below:

如何在SAP S/4HANA里创建自定义的partner function

(3) Create a new partner determination procedure:

如何在SAP S/4HANA里创建自定义的partner function

and assign the custom partner function Z0000002 to the created procedure:

如何在SAP S/4HANA里创建自定义的partner function

Create a new transaction type and assign the custom patner determination procedure to it:

如何在SAP S/4HANA里创建自定义的partner function

Now it is ready for test.

It is possible now to maintain business partners with custom partner function in WebUI. In my example the partner ID is 142.

如何在SAP S/4HANA里创建自定义的partner function

This partner ID is stored in the very extension field we created in the first step:

如何在SAP S/4HANA里创建自定义的partner function

The partner with this custom partner function could still be read out via CRM_ORDER_READ:

如何在SAP S/4HANA里创建自定义的partner function
如何在SAP S/4HANA里创建自定义的partner function

继续阅读