In Billing processes the billing document is automatically posted if the document is complete. In my case the business user wanted to review the billing document and do some sanity checks and post the document manually to finance. This blog provides details on how to configure the S/4HANA Cloud system, to block the automatic posting of Billing Documents.
Following are the steps to achieve the automatic posting block via Central Business Configuration
Login to your CBC system and open the configuration activity Configure Billing and Invoicing which is available in project phase Product-specific configuration.
You should be able to see the list of configuration activities. Expand Billing and Invoicing -> Billing Preparation -> Sales Billing to navigate to the required configuration activities.
There are three activities that needs to be completed in this sequence.
A.Define Formula for Flexible Billing Posting: In this activity define the rules when should the billing document be blocked from automatic posting. Example:
Make a new entry (Click New Entries) to define a new formula. Give the Formula ID e.g., INVOICE_BLOCKING. Give a description to it.
Select the new Formula defined and double click on Assign Formula Parameters. Here you need to add the parameters based on which you want to decide the block of automatic posting, e.g., BILLINGDOCUMENTTYPE, SALESORGANIZATION etc.
Pick the Formula Tasks that needs to be done by clicking on Formula Tasks. Select BLOCK_AUTO_POSTING for this scenario.
Double click on Assign Parameter priority. Here you define the priority of the parameters added earlier, e.g., BILLINGDOCUMENTTYPE is 1 and SALESORGANIZATION is 2.
Double click on Define Decision Table. Here you will define the values for the parameters that leads to blocking of automatic posting, e.g., if the Billing Type is CIX1 (i.e., the Billing document is created with reference to external billing document) and Sales Organization is 1000, then block the automatic posting. These rules are evaluated in sequence from top to bottom.
Save the definition.
B. Define Custom Routines for Flexible Billing Document Posting: Create a new routine and assign it to the formula defined in the previous step.
Add a new entry to define a new routine number e.g., 3000000 (Test BLL)
Select the new routine number defined and navigate to Assign Enhancement IDs to a Routine Number by double clicking on it
Enter Process Enhancement Option Task as GLO_BIL_FLEX_FI_INTEGRATION and assign the Formula defined in first activity to it e.g., INVOICE_BLOCKING
Save the activity and close.
C. Assign Custom Routines to Tax Departure Countries/Regions:In this activity you shall assign the created custom routine to a tax country applicable for Billing document.
Create a new entry and define the custom routine and the Tax Departure country Code., e.g., DE, 3000000
Save the activity and close.
To test the configuration done follow the steps
Login to S/4HANA cloud system
Create two Billing documents with reference to an external billing document (you can use Billing Document API to create such a billing document) by providing all required details.
Define the Sales organization e.g., 1000 in the first billing document and 3000 in second billing document
You should notice that the billing document with sales organization 1000 is created in status “To be Posted” and the one with sales organization 3000 with status “Completed”