Enterprise Resource Planning Blogs by SAP
Get insights and updates about cloud ERP and RISE with SAP, SAP S/4HANA and SAP S/4HANA Cloud, and more enterprise management capabilities with SAP blog posts.
cancel
Showing results for 
Search instead for 
Did you mean: 
Hongjun_Qian
Product and Topic Expert
Product and Topic Expert
Our standard Fiori app 'Check Cash Flow Items' (CCFI) allows the end user to perform manual adjust on flows from Accounting. However, the manual adjusted flows will be override automatically if its original accounting document chain got updated or a rebuilt via Flow Builder performed.

For instance, you use manual adjustment in CCFI, changed liquidity item of accounting document 0001/2018/123456789 (company code/fiscal year/document number) from A to B. The system will remove the old flow (with liquidity item A) and insert new flow (with liquidity item B) .

Once you use Flow Builder to rebuild flows for that document, the elder flows belong to that document will be deleted before new flows generated, in another word, the manual adjustment you applied will lost.

However, you can keep your manual adjusted flows by leveraging Flow Builder's standard exit:
IF_FCLM_HADI_APAR~FLOW_ADJUST

 

Here comes the steps you need to do:

  1. Copy the sample class CL_FCLM_APAR_HADI_SAMPLE to a new class, for instance, ZCL_FCLM_APAR_HADI_SAMPLE. Feel free to assign class to a suitable package to meet the requirement of transport.

  2. Rewrite the method: IF_FCLM_HADI_APAR~FLOW_ADJUST. A code snippet provided as below;

  3. Use your new exit class to generate a new loading class via Flow Builder Configuration tool (t-code:FCLM_FB_UTIL);

  4. You also need a re-assign in case you picked up a new exit class.


  METHOD if_fclm_hadi_apar~flow_adjust BY DATABASE PROCEDURE FOR HDB LANGUAGE SQLSCRIPT USING fqm_flow.

et_flows = select * from :it_flows as a
where not exists ( select * from fqm_flow where fi_document_number = a.fi_document_number
and company_code = a.company_code
and fi_fiscal_year = a.fi_fiscal_year
and origin_flow_id like '%M'
and flg_actual = 'X'
and mandt = :iv_mandt
and deleted = ''
);

ENDMETHOD.

 

In case you have other specific logic implemented in this method already, you need combining your logic together.

 

Hope the code snippets above helps. Good luck!