cancel
Showing results for 
Search instead for 
Did you mean: 

Add a title in BadI Open Channel

NancyD4
Discoverer
172

Hello,

We have implemented the BadI "open Channel: Enhance Payload for Data Transfer" in this, We have added the fields that are used to send the information, but in the campaigns view, I want to add a division of the information so that it has more order.

Does anyone know if I can add this "title" or "division" in BadI, itself and how I would ad the code?Add title or division.png

jan_kaemmerle
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hello Nancy,

you can add campaign fields in the BAdI. 
Please check out the sample code for BAdI implementation "open Channel: Enhance Payload for Data Transfer".

E.g.
READ TABLE header_attributes ASSIGNING FIELD-SYMBOL(<header_attributes>) " table contains also the action parameters WITH KEY param_name = 'ZOC_EXPORT_PRIORITY'.
IF sy-subrc IS INITIAL.
  IF <header_attributes>-param_value = 'PRIORITY_1'. " defined as 'High' in enhancement '(2) Open Channel: Define Parameters for Implementation'
  " add a special attribute that shall be added to every target group member; will be part of the odata payload transferred to HCI
  INSERT VALUE #(
                attribute_id = 'ZOC_EXPORT_PRIORITY'
                attribute_name = 'Priority' attribute_type = 'Edm.String' ) INTO TABLE target_group_member_attributes.
  zoc_export_priority_1 = abap_true. " helper variable, needed in next loop
 ENDIF.
ENDIF.

Br,
Jan

Accepted Solutions (0)

Answers (1)

Answers (1)

NancyD4
Discoverer
0 Kudos

Hello @jan_kaemmerle,

Thank you for your answer, but it's not only de field, We want to add a title, because We want to separate the information.

Do you know how we can add a title?

Best regards,

Nancy