Ansicht
Dokumentation

THM_HI_BEFORE_CREATE - BAdI: Enhancement for Hedged Items

THM_HI_BEFORE_CREATE - BAdI: Enhancement for Hedged Items

SUBST_MERGE_LIST - merge external lists to one complete list with #if... logic for R3up   PERFORM Short Reference  
This documentation is copyright by SAP AG.
SAP E-Book

This Business Add-In (BAdI) is used in the Hedge Accounting for Exposures(E-HA) component.
You can use this BAdI to add a description to a Hedged Item.

The following import parameters are used to access the hedged item data or exposure data:

I_HEDGED_ITEM
I_EXPOSURE_ID

To access the corresponding exposure position and its free characteristics, the function module THM_EXPPOS_TO_HEDGE_CALLBACK can be used.

METHOD if_thm_enrich_hi_before_create~get_description.

    DATA: l_position_id     TYPE ftr_position_id.

    CALL FUNCTION 'THM_EXPPOS_TO_HEDGE_CALLBACK'
      IMPORTING
        e_position_id = l_position_id.

    cl_tex_expos_query_service=>get_exp_position_by_pos_id( EXPORTING  iv_position_id     = l_position_id    " Exposure Position ID
                                                            IMPORTING  es_exp_positions   = DATA(l_exp_positions)    " Table of Positions
                                                            EXCEPTIONS position_not_found = 1
                                                                     OTHERS             = 2 ).

    r_description =        l_exp_positions-zzzforecastyear   && '-'
                        && l_exp_positions-zzzforecastmonth  && '|'
                       && l_exp_positions-zzztestnumber.

  ENDMETHOD.






Fill RESBD Structure from EBP Component Structure   General Material Data  
This documentation is copyright by SAP AG.

Length: 3257 Date: 20240523 Time: 155445     sap01-206 ( 25 ms )