Fonction SAP BAPI_PRODORDCONF_GET_HDR_PROP - Propose Data for Order Confirmation

Paramètre Reférence Type Long. Valeur par déf. Facultatif Description
PROP_GMOV BAPI_CORU_PARAM-PROP_GMOV C 1 SPACE X Ind.: Propose Goods Movements

Paramètre Reférence Type Long. Description
RETURN BAPIRET1 u 470 Return parameter

Paramètre Reférence Long. Facultatif Description
ATHDRLEVELS BAPI_PP_HDRLEVEL 187 Table of order confirmations
DETAIL_RETURN BAPI_CORU_RETURN 568 X Return parameter for confirmation table
GOODSMOVEMENTS BAPI2017_GM_ITEM_CREATE 1106 X Table of goods movements
LINK_CONF_GOODSMOV BAPI_LINK_CONF_GOODSMOV 12 X Link table for confirmations/goods movement

Functionality
You can use this method to prepare default data for confirmationsfor production order.
Along with the confirmation data those goods movements can also beproposed that are specified according to standard SAP logic on thebasis of the quantity of the operation still to be confirmed forbackflushing and automatic goods receipt.
You must specify for which order the data is to be proposed in thetable Athdrlevels.
The order is to be provided in the field Athdrlevels-Orderid.

Notes
Authorization check
The authorization object C_AFRU_AWK with theactivity 01 (create) as well as the order type and plant of theproduction order to be confirmed is checked.
Parameter

  • PropGmov

  • You can use the parameter PropGmov to specify whether inaddition to the proposed time event data goods movements forbackflushing and automatic goods movements are to be proposed for thetime event data depending on the quantity still to be confirmed.
    • Return

    • If the default data is not provided because of a serious error theparameter Return contains information concerning the error thathas occurred.
      • Athdrlevels

      • The table Athdrlevels serves both as input for the keys for theoperations to be confirmed and also as output for the data still to beconfirmed for the various operations.
        • Goodsmovements

        • If default values were proposed for goods movements for confirmations(see parameter PropGmov) then these are provided in the tableGoodsmovements.
          • LinkConfGoodsmov

          • If default values for goods movements for the confirmation werecalculated then the table LinkConfGoodsmov links theconfirmation in table Athdrlevels to the associated goodsmovements in the table Goodsmovements. The index in the fieldLinkConfGoodsmov-Index_Confirm points to the line in therelevant confirmation in the table Athdrlevels and the index inthe field LinkConfGoodsmov-Index_Goodsmov to the relevant goodsmovement in the table Goodsmovements.
            • DetailReturn

            • The table DetailReturn provides information for every entry inthe table Athdrlevels as to whether an error arose on proposaland as to what error it concerned.
              If no error arose for an entry in the table Athdrlevels then anentry is made with initial data in the table DetailReturn.

              Description
              The Return parameter is only used for serious errors that prevent allconfirmations from being processed further. As a rule, this type oferror only occurs if the transferred confirmation data cannot beconverted into the internal structures, because conventions regardingdata definitions have not been adhered to.
              The Return parameter's structure contains all the necessaryinformation about the error in detail. This is also prepared in themessage text MESSAGE.

              Default
              If no serious error is found, the return parameter is returned withinitial values.

              Description
              The PropGmov parameter can be used to control whether goodsmovements are to be proposed for backflushing and automaticgoods receipt dependent on the quantity still to be confirmed, inaddition to the proposed confirmation data.

              Description
              Table of confirmations, as order confirmations.
              The confirmed order can be identified by entering the order inthe ORDERID field.
              Each entry in the AtHdrLevels table represents a separate timeevent that is processed in the sequence in which it is transferred.

              Description
              The parameter table DetailReturn provides information about anyexception that may occur due to incorrect data, for each confirmationin the AtHdrLevels table.
              An entry is made in the DetailReturn table for each time eventin the AtHdrLevels table. For example, the third entry in theDetailReturn table shows if an exception has arisen for thethird confirmation in the AtHdrLevels table.
              If no exception is detected, an entry with initial values is providedin the DetailReturn table.

              Description
              Automatic goods movements, that is automatic goods receipts andbackflushing of components, are only proposed if thePropGmov parameter is set.
              The goods movements are then determined on the basis of the quantity tobe confirmed, by the confirmation in question.

              Description
              Each individual goods movement item is assigned to a confirmation inthe AtHdrLevels table via the parameter tableLinkConfGoodsmov.
              Assignment occurs via the IndexConfirm and IndexGoodsmovindices. For this process the IndexConfirm index has to refer tothe confirmation in the parameter table AtHdrLevels and theIndexGoodsmov index to the goods movement in the parameter tableGoodsmovements.