Ansicht
Dokumentation

S2P_GROUP_PLNG_ITEMS - BAdI: Grouping Planning Elements

S2P_GROUP_PLNG_ITEMS - BAdI: Grouping Planning Elements

Fill RESBD Structure from EBP Component Structure   CPI1466 during Backup  
This documentation is copyright by SAP AG.
SAP E-Book

In the supply-to-production table, in the list of planning elements, you can use the pushbutton Group Planning Elements to group planning elements of the same type (for example, APO requirements). This means you can improve the clarity of the table at planning element level. This function only affects the display of the planning elements and does not affect the missing parts calculation.

Using the Business Add-In (BAdI) S2L_GROUP_PLNG_ITEMS you can define your own logic for grouping planning elements.

The standard logic groups all consecutive planning elements of the same type (with the exception of replenishment proposals).

Create an implementation of the Business Add-In and implement the two interface methods IF_EX_S2L_GROUP_PLNG_ITEMS~CHECK_MERGABILITY and IF_EX_S2L_GROUP_PLNG_ITEMS~MERGE. Create a forward declaration for the type pool S2L to enable access to the fixed values listed below.

Method CHECK_MERGABILITY

Using the details data of the current planning element (Import-Parameter: CURRENT_ITEM_DETAILS) and the preceding planning elements (import parameter: PREVIOUS_ITEM_DETAILS), you can determine whether and how a planning element is to be grouped with its predecessor. The method is only accessed if it is basically possible to group the planning element with its predecessor. The predecessor planning element may already contain several grouped planning elements.

You can transfer the following fixed values to the export parameter MERGE.

  • S2L_NO_MERGE
    Planning element should not be grouped with predecessor.
  • S2L_STANDARD_MERGE
    Planning element is grouped according to standard logic.
  • S2L_CUSTOM_MERGE
    Planning element is grouped according to user-specific logic (Methode MERGE).

Method MERGE

You can access this method if method CHECK_MERGABILITY provides the fixed value S2L_CUSTOM_MERGE. You can group the current planning element (import parameters: CURRENT_ITEM_DETAILS) with its predecessor (changing parameters: PREVIOUS_ITEM_DETAILS) taking your own user-specific logic into account.

You only want special planning element types (for example, requirements) to be grouped (see example implementation).






TXBHW - Original Tax Base Amount in Local Currency   ABAP Short Reference  
This documentation is copyright by SAP AG.

Length: 2783 Date: 20240523 Time: 202038     sap01-206 ( 57 ms )