Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

SAP EWM: FM or Class to generate Doc. Flow linkage between Warehouse Request and Warehouse Task

abhishek_bs
Discoverer
0 Kudos
733

Requirement: An Fiori app which can create Warehouse Request and then create Warehouse Task from that Warehouse Request.

Need help in backend logic.

We were able to create warehouse request using class-method: /SCWM/CL_DLV_MANAGEMENT_PRD -> CREATE_WHR.

Once the warehouse request was created, we then went ahead and passed warehouse request details in FM: /SCWM/TO_CREATE_WHR to create Warehouse Task. We are passing below parameters to FM.

We have passed below fields in LT_CREATE_WR:

LT_CREATE_WR-rdoccat (Doc. Category )

LT_CREATE_WR-rdocid (Warehouse Header Document ID )

LT_CREATE_WR-ritmid (Warehouse Item Document ID)

LT_CREATE_WR-anfme (Quantity)

LT_CREATE_WR-altme (Alt. UoM)

LT_CREATE_WR-opunit (Oper. Unit)

LT_CREATE_WR-hutyp (HU Type)

LT_CREATE_WR-vltyp (Source storage type)

LT_CREATE_WR-vlpla (Source storage Bin)

LT_CREATE_WR-nltyp (Destination storage type)

LT_CREATE_WR-nlpla (Destination storage bin)

LT_CREATE_WR-matid (Product id)

Warehouse Task is created successfully.

At warehouse task level we can see its reference Warehouse Request

But now when we check warehouse request in tcode /SWCM/IM_ST, we are not able to see the document flow between Warehouse Request and Warehouse Task in Document flow tab in third sub screen section of tcode /SWCM/IM_ST.

If we create a warehouse request and warehouse task from tcode /SWCM/IM_ST, there is a document flow linkage generated at Warehouse Request level

Is there any class or FM which we can use to create Document Flow linkage between Warehouse Request and Warehouse Task.

Thanks in advance.

Regards,

Abhishek S

1 ACCEPTED SOLUTION

abhishek_bs
Discoverer
0 Kudos
367

Hello All,

We were able to achieve our requirement of generating document flow between Warehouse Request and Warehouse Task using Function module: /SCDL/DL_DOCFLOW_UPDATE which updates/inserts/delete entries into document flow table /SCDL/DB_DF and /SCDL/DB_DFDOCID.

We need to pass all the necessary information regarding the Warehouse Request and Warehouse Task in importing tables IT_DF and IT_DF_DOCID. In order generate the required document flow we need to pass field IT_DF-OBJCHG = 'I' (Insert).

Regards,

Abhishek S

1 REPLY 1

abhishek_bs
Discoverer
0 Kudos
368

Hello All,

We were able to achieve our requirement of generating document flow between Warehouse Request and Warehouse Task using Function module: /SCDL/DL_DOCFLOW_UPDATE which updates/inserts/delete entries into document flow table /SCDL/DB_DF and /SCDL/DB_DFDOCID.

We need to pass all the necessary information regarding the Warehouse Request and Warehouse Task in importing tables IT_DF and IT_DF_DOCID. In order generate the required document flow we need to pass field IT_DF-OBJCHG = 'I' (Insert).

Regards,

Abhishek S