cancel
Showing results for 
Search instead for 
Did you mean: 

Enable or Disable POrg and PGrp fields in RFx screen

Former Member
0 Kudos

Hi guys,

I need to enable or disable the purchase organisation and purchase group fields in the RFx screen based on a condition.

I have tried using the class /SAPSRM/CL_PDO_DYN_MDF_HD_RFQ as post-exit method. But it is not working.

I have tried the configuration through SPRO transaction also by creating a custom class and method and configuring it in SPRO.

But since my code is getting triggered first and then it is going through SAP code, the data I am changing is getting reveresed.

Can you please suggest a method to do this?

Accepted Solutions (1)

Accepted Solutions (1)

RicardoRomero_1
Active Contributor
0 Kudos

Hi,

I did the same for purchase group of SC and it's working fine.

What I did is go to SPRO to the following path:

SAP Supplier Relationship Management -> SRM Server -> Cross-Application Basic Settings -> Extensions and Field Control (Personalization) -> Configure Field Control -> Configure Control for Fields of Substructures -> Metadata for Fields of Substructures and Table-Like Enhancements

Here you can add a new entry for Set Type 21 (Organizational Management), field PROC_GROUP_ID, and you can set a dynamic class and method for enable or disable the field dinamically.

with this should work. If not may be you need to create an enhancement point in the WD for change the binding of the property read_only of these fields dinamically...

Regards,

Former Member
0 Kudos

Hi Ricardo,

For this do we need to create some sub-structures?

RicardoRomero_1
Active Contributor
0 Kudos

Hi Sreedevi,

No, it's not necessary to create any sub-structure.

Former Member
0 Kudos

Hi Ricardo,

After adding that in the transaction I am getting an error "Formal parameter not found during dynamic method call".

Do I need to check the fields :Field Visible" enabled etc?

RicardoRomero_1
Active Contributor
0 Kudos

Hi Sreedevi,


Create the method with the following parameteres:

IS_ITEM                 Importing    Type    BBP_PDS_BID_ITEM_D

IS_SET                  Importing    Type    BBP_PDS_ORG

IS_HEADER          Importing    Type    BBP_PDS_BID_HEADER_D

IV_OBJECT_TYPE Importing    Type    BBP_BUS_OBJECT_TYPE

IV_FIELD_NAME    Importing    Type    NAME_KOMP

IS_ADD_DATA       Importing    Type    /SAPSRM/S_PDO_META_FLD_ADD_DAT (Optional)

CS_METADATA     Changing    Type    /SAPSRM/S_PDO_FIELD_METADATA

Former Member
0 Kudos

Hi Ricardo,

The field is now disabled but it is not visible. Eventhough I have set cs_metadata-visible  and cs_metadata-required = abap_true, the field itself is not visible.

Do we need to check the fields "Visible, Enabled" etc in the configuration also?

RicardoRomero_1
Active Contributor
0 Kudos

Hi Sreedevi,

Try to check all the fields in the configuration and change it from your dynamic method.

I've just tried in my system with a SC and it's working fine for me.

Former Member
0 Kudos

Hey Ricardo,

Many Thanks. It is working fine now.

Answers (0)