Ansicht
Dokumentation

REEX_AL_ACROBJ - Implement Enhancements: Exclude Contracts (BAdI)

REEX_AL_ACROBJ - Implement Enhancements: Exclude Contracts (BAdI)

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

Using this Business Add-In (BAdI), you can exclude the cash flow records of individual contracts from the accrual/deferral of net amounts or taxes. To do this, implement the IS_CONTRACT_ACR_RELEVANT method.

SAP Note 1516683 makes it possible to use this Business Add-In to exclude individual cash flow records from the accrual/deferral of net amounts or taxes. To do this, implement the IS_CFITEM_ACR_RELEVANT method.

The BAdI is called during accruals/deferrals (transaction RERAALCN) for each contract.

If you do not implement this BAdI then the accruals/deferrals are performed as follows:

  • The accrual/deferral of net amounts is made for all contracts provided that the used flow types of the cash flow are indicated as relevant for accrual/deferral.
  • The accrual/deferral of tax amounts is made for all contracts provided that the tax accrual/deferral has been activated in the company code and the used tax types and groups of the cash flow are designated as relevant for accrual/deferral.

Implement the IS_CONTRACT_ACR_RELEVANT method using transaction SE19.

The following parameters are used:

  • IO_CONTRACT: Reference to the contract that is currently being processed
  • ID_KEYDATE: Key date of accrual/deferral
  • ID_MODE: Mode of the posting run ('E': update run, 'S': Simulation)
  • CF_TAX_ACR_REL
    Change this indicator if you want to override the company code default setting for tax accruals/deferrals for the current contract.
  • CF_NET_ACR_REL
    This indicator should not be set if the contract is to be excluded from the accrual/deferral. This indicator is set in the standard system.

Important:It is notpossible to accrue only the taxes but not the net amounts.

To exclude individual cash flow records from the accrual/deferral, implement the IS_CFITEM_ACR_RELEVANT method.

You can use the following parameters:

  • IO_CONTRACT: Reference to the contract that is currently being processed
  • ID_KEYDATE: Key date of accrual/deferral
  • ID_MODE: Mode of the posting run ('E': update run, 'S': Simulation)
  • IS_CASHFLOW_PAY: The cash flow record that is currently being processed from the partner-related cash flow. If the cash flow record that is currently being processed is a record from the object cash flow, then this parameter is blank.
  • IS_CASHFLOW_OBJ: The cash flow record that is currently being processed from the object cash flow. If the cash flow record that is currently being processed is a record from the partner-related cash flow, then this parameter is blank.
  • CF_TAX_ACR_REL
    Change this indicator if you want to override the company code default setting for tax accruals/deferrals for the current cash flow record.
  • CF_NET_ACR_REL
    This indicator should not be set if the current cash flow record is to be excluded from the accrual/deferral. This indicator is set in the standard system.

Important:It is notpossible to accrue only the taxes but not the net amounts.

In the standard system, accruals and deferrals that have begun for the cash flow records and that have the status "Actual" (CFSTATUS = I) are reversed during the next scheduled accrual/deferral run. In subsequent runs, they are not taken into account if the underlying contract or condition has expired. This logic can be altered with an implementation of method GET_BEHAVIOR_CONTEXT.

You can use the following parameters:

  • IO_CONTRACT: Reference to the contract that is currently being processed
  • ID_KEYDATE: Key date of accrual/deferral
  • ID_MODE: Mode of the posting run ('E': update run, 'S': Simulation)
  • IS_CASHFLOW_PAY: The cash flow record that is currently being processed from the partner-related cash flow. If the cash flow record that is currently being processed is a record from the object cash flow, then this parameter is blank.
  • IS_CASHFLOW_OBJ: The cash flow record that is currently being processed from the object cash flow. If the cash flow record that is currently being processed is a record from the partner-related cash flow, then this parameter is blank.
  • CF_REVERSAL_ON_ENDED_CONTRACT
    If you change this indicator to ABAP_FALSE, any accruals/deferrals that have begun are continued and new accrual/deferral records are created even if the contract has expired.
  • CF_REVERSAL_ON_ENDED_COND
    If you change this indicator to ABAP_FALSE, any accruals/deferrals that have begun are continued and new accrual/deferral records are created even if the underlying condition has expired (explicitly).
  • CF_CFSTATUS_RELEVANT_FOR_REV
    If you change this indicator to ABAP_FALSE, any accruals/deferrals that have begun are reversed regardless of the cash flow status (CFSTATUS) if the underlying contract or condition has expired.

Implement method SET_ADDITIONAL_PARAM to save additional parameters for the deferral subobject (corresponds to a cash flow record). These parameters are stored in table ACEDSOP and can be accessed using function module ACEDSDB_PARAM_READ_SID_ALLDAT, for example. The following parameters are available:

  • IO_CONTRACT: Reference to the contract that is currently being processed
  • ID_KEYDATE: Key date of accrual/deferral
  • IS_CASHFLOW_PAY: The cash flow record that is currently being processed from the partner-related cash flow. If the cash flow record that is currently being processed is a record from the object cash flow, then this parameter is blank.
  • IS_CASHFLOW_OBJ: The cash flow record that is currently being processed from the object cash flow. If the cash flow record that is currently being processed is a record from the partner-related cash flow, then this parameter is blank.
  • CT_PARAMETERS: Add the parameters that you want to save for the deferral subobject to this table. Caution: Do not use any parameter names (PARAM_NAME field) that are already used by SAP. These are TAXCODE, ALLOCATION, and OBJNR.

For a contract type EXMP, no taxes should be accrued, regardless of the company code default setting.

Therefore you determine the contract type for the current contract in the IS_CONTRACT_ACR_RELEVANT method. If the contract type is EXMP, you reset the indicator CF_TAX_ACR_REL.

In addition, no planned records from the cash flow should be accrued/deferred for contract type EXP2. Therefore, determine the contract type of the current contract in the IS_CFITEM_ACR_RELEVANT method. For contracts with contract type EXP2 and planned cash flow records, reset the indicators CF_NET_ACR_REL and CF_TAX_ACR_REL.

Refer to the sample code (Goto → Sample Code → Display).

Notes for Developers






TXBHW - Original Tax Base Amount in Local Currency   Addresses (Business Address Services)  
This documentation is copyright by SAP AG.

Length: 7809 Date: 20240523 Time: 202529     sap01-206 ( 137 ms )