cancel
Showing results for 
Search instead for 
Did you mean: 

BADI MM_PUR_S4_PO_FLDCNTRL_SIMPLE for Manage Purchase Orders Fiori App ID F0842A

SAPSupport
Employee
Employee
1,585

Hi Team,

A custom field is created and published using the Custom Fields and Logic Fiori App .
We are adding that custom field at PO Header Level to Manage Purchase Orders Fiori App ID F0842A using In-App Extensibility.
The field is visible and we are able to save the data entered in it.


We are trying to implement a custom logic for this PO Header Level field by using BADI MM_PUR_S4_PO_FLDCNTRL_SIMPLE.

This BADI is not getting triggered for this custom PO Header Level field.
We have gone through the below link for App Extensibility: Manage Purchase Orders

https://help.sap.com/docs/SAP_S4HANA_ON-PREMISE/af9ef57f504840d2b81be8667206d485/8676e556cca85267e10...


It is suggested here to use BADI MM_PUR_S4_PO_FLDCNTRL_SIMPLE_H for modifying the properties of Custom PO Header level fields.

Kindly suggest if we can use BADI MM_PUR_S4_PO_FLDCNTRL_SIMPLE to implement a custom logic for this PO Header Level field or we need to use BADI MM_PUR_S4_PO_FLDCNTRL_SIMPLE_H only.

We do not have BADI MM_PUR_S4_PO_FLDCNTRL_SIMPLE_H available in our system.

Please let us know how to proceed.

Thanks & Regards,


------------------------------------------------------------------------------------------------------------------------------------------------
Learn more about the SAP Support user and program here.

Accepted Solutions (1)

Accepted Solutions (1)

SAPSupport
Employee
Employee
0 Kudos

Dear Customer,

I can confirm that if your need is to control the field properties (hidden, display etc) then this is only available from S/4HANA 2021 by using the BADI MM_PUR_S4_PO_FLDCNTRL_SIMPLE_H. This can be checked here:

You will notice this information is for 2021 release, and if you try to find the same for 2020, it is not there.

https://help.sap.com/docs/SAP_S4HANA_ON-PREMISE/e296651f454c4284ade361292c633d69/94066142881b494a815...

The BADI MM_PUR_S4_PO_FLDCNTRL_SIMPLE is only called on Item level and will not work for header level fields. I am afraid the option to control the custom field properties is not available in your release for header level.

Kind Regards,

Lisa
SAP Support

Answers (2)

Answers (2)

SunnyZ
Contributor
0 Kudos

Hi there,

Thanks for the responses first of all, these 2 answers helped in locating the BAdI items for editing field behaviour when creating Purchase Orders.

Just to add on top, if we have made a field mandatory, we may want to also use the custom logic "Check of Purchase Order Before Saving" under the same section to add/edit the error message, as in the "Create Purchase Order - Advanced" app, there is no indicator(s) on the mandatory field(s).

However, as a newbie in S4 world, I do find the most challenging part would be writing the BAdI codes. Understand that the BAdI Documentation and the samples are helpful, but it is still quite confusing while starting with the actual code writing.

Thanks,

Sunny

Eric_Yu
Product and Topic Expert
Product and Topic Expert
0 Kudos

Dear Customer,

Would you please find more details from url below?

This BAdI can be used to set ot change values of custom fields.

Modify Purchase Order Header (MM_PUR_S4_PO_MODIFY_HEADER)

Set or change values of custom fields in purchase orders on header level.

This BAdI can be used to set the properties of the field, for example set it to read-only.

Change of Field Control for Purchase Order Header (MM_PUR_S4_PO_FLDCNTRL_SIMPLE_H)

Change the field control in purchase order apps by modifying the properties of specific fields on header level. These fields can be made hidden, read-only, mandatory, or optional.

https://help.sap.com/docs/SAP_S4HANA_CLOUD/0e602d466b99490187fcbb30d1dc897c/8676e556cca85267e1000000...