Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
V11
V12 • Updated documentation for BAdI methods:
• SET_INVOICE_STATUS_SD
• SET_INVOICE_STATUS_MFI
V13 • Added documentation for the following BAdI
methods:
• FILL_AFS
V15 • SET_DELIVERY_DATE
V16 • SET_PRODUCTNUMBERCODE
V17 • GET_NON_REVEUNE_BASED_TAX_CODE
You use this BAdI to update or modify the default values reported in the output XML file generated by the
Standard Audit File for Tax Purpose (SAFT) (RPFIEU_SAFT) report as per customer-specific
requirements.
This BAdI is called when you execute the Standard Audit File for Tax Purpose (RPFIEU_SAFT) report.
Standard settings
For more information about the standard settings (filters, single or multiple uses), see the Enhancement Spot
Element Definitions tab in the BAdI Builder (transaction SE18).
See also
BAdI Methods:
BAdI Methods
1. BAdI Method: UPDATE_CUSTOMER_MASTER
Use
You use this Business Add-In (BAdI) method to add customers in the Customer section inside the
MasterFiles section.
Parameters
The following list contains only the changing parameters that require additional information:
Changing Parameters:
• CT_CUST_MASTERS : If you want to add the customers not getting reported in the SAF-
T file.
====================================================================================
You use this Business Add-In (BAdI) method to update the vendor details in the Supplier section
inside the MasterFiles section.
Parameters
The following list contains only the changing parameters that require additional information:
Changing Parameters:
=====================================================================================
You use this Business Add-In (BAdI) method to update the debit amount, credit amount, and unit
price of the line item in the SalesInvoices section inside the SourceDocuments section.
Parameters
The following list contains only the changing parameters that require additional information:
Changing Parameters:
• CV_INV_DEBIT_AMT: Tf you want to modify the line item debit amount reported by
default in the XML file, update this changing parameter based on the import parameters
• CV_INV_CREDIT_AMT: If you want to modify the line item credit amount reported by
default in the XML file, update this changing parameter based on the import parameters
• CV_UNIT_PRICE: If you want to modify the line item unit price reported by default in
the XML file, update this changing parameter based on the import parameters
If the currency is not EURO, then only you need to set the values of the following parameters:
o CV_CURR_DEBTI_AMT
o CV_CURR_CREDIT_AMT
=====================================================================================
You use this Business Add-In (BAdI) method to update the journal general description and
transaction description in the Journal section inside the GeneralLedgerEntries section.
Parameters
The following list contains only the changing parameters that require additional information:
Changing Parameters:
=====================================================================================
You use this Business Add-In (BAdI) method to include tax like material amounts in the
DocumentTotal sections.
Parameters
The following list contains only the changing parameters that require additional information:
Changing Parameters:
=====================================================================================
You use this Business Add-In (BAdI) method to update the transcation id in the TranscationID
field in case if multiple accounting documents exist for a SD invoice.
Parameters
The following list contains only the changing parameters that require additional information:
Changing Parameters:
• CS_TRANSAID: If you want to modify the transaction ID reported by default in the XML
file, update this changing parameter based on the import parameters
=====================================================================================
You use this Business Add-In (BAdI) method to update the NetTotal and TaxPayable fields in
DocumentTotal in case of offers scenario.
Parameters
The following list contains only the changing parameters that require additional information:
Changing Parameters:
• CV_INV_NET_AMT: If you want to modify the net total amount reported by default in
the XML file, update this changing parameter based on the import parameters
• CV_INV_TAX_AMT: If you want to modify the tax payable amount reported by default
in the XML file, update this changing parameter based on the import parameters
=====================================================================================
8. BAdI Method: SET_NEG_POSTING_AMT_INV
You use this Business Add-In (BAdI) method to if you want to switch the debit amount and credit
amount reported in the GeneralLedger section of the output XML file. This method is used when
have documents posted with negative values. As per the requirements of tax authorities, negative
values are not to be reported in the output XML file.
Parameters
The following list contains only the changing parameters that require additional information:
Changing Parameters:
• EV_TOGGLE_AMT: If you want to switch the debit and credit amount reported in the
GeneralLedger section of the output file (to prevent the reporting of negative values in the
output file), set the value of this changing parameter as X.
=====================================================================================
Parameters
The following list contains only the changing parameters that require additional information:
Changing Parameters:
• CV_TRANS_TYP: In this parameter you set the allowed transaction type. The report by
defualt sets N for all documents.
=====================================================================================
Parameters
The following list contains only the changing parameters that require additional information:
Changing Parameters
• CV_INV_TYP: This parameter allows you to modify the invoice type reported by default in
the XML file.
=====================================================================================
Parameters
The following list contains only the changing parameters that require additional information:
Changing Parameters
• CV_LAND: This parameter allows you to modify the country key reported in the XML file.
=====================================================================================
Parameters
The following list contains only the changing parameters that require additional information:
Changing Parameters
• CV_CUST_ADDRESS
• CV_CUST_CITY
• CV_CUST_POSTALCODE
• CV_CUST_COUNTRY
=====================================================================================
Parameters
The following list contains only the changing parameters that require additional information:
Changing Parameters
• CV_PLANT_ADDRESS
• CV_PLANT_CITY
• CV_PLANT_POSTALCODE
• CV_PLANT_COUNTRY
=====================================================================================
Parameters
The following list contains only the changing parameters that require additional information:
Changing Parameters
• CV_CUST_ID: This parameter allows you to modify the customer number reported in the
XML file.
15. BAdI Method: IDENTIFY_EXT_INVOICES_SD (Obsolete)
(Note: The feature was replaced by the SIPT_IF_VBRK table. See note 2166344)
You use this Business Add-In (BAdI) method to identify SD invoices generated in an external
system. The system considers these invoices when calculating the total debit and total credit, and
offsets the source billing as “I” in the output file.
Parameters
The following list contains only the changing parameters that require additional information:
Changing Parameters
====================================================================================
Parameters
The following list contains only the changing parameters that require additional information:
Changing Parameters
====================================================================================
Note
This method is called by the Standard Audit File for Tax Purpose (SAF-T)
(RPFIEU_SAFT) report only for documents having source billing values I (external
system) and M (manual/backup invoices).
Prerequisites
Parameters
The following list contains only the changing parameters that require additional information:
Changing Parameters
Note
You can change the above-mentioned parameters only when the source billing value is I.
If the source billing value is M, then you can only change the CV_HASHCONTROL
parameter.
=====================================================================================
Note
This method is called by the Standard Audit File for Tax Purpose (SAF-T)
(RPFIEU_SAFT) report only for documents having source billing values I (external
system) and M (manual/backup invoices).
Prerequisites
Parameters
The following list contains only the changing parameters that require additional information:
Changing Parameters
=====================================================================================
Parameters
The following list contains only the changing parameters that require additional information:
Changing Parameters
• IV_PROD_TYP: If you want to change the product type, update this changing parameter
based on the import parameters.
=====================================================================================
Parameters
The following list contains only the changing parameters that require additional information:
Changing Parameters
CV_TAXCODE CV_TAX_PER
CV_TAXTYPE CV_TAX_EXMP_RSN
CV_TAX_CNTRY_REG CV_TAX_AMT
=====================================================================================
21. BAdI Method: REPLACE_CURRENCY_KEY
You use this Business Add-In (BAdI) method to clear the currency key you have defined
internally, and hence avoid reporting the incorrect currency key in the output file.
Parameters
The following list contains only the changing parameters that require additional information:
Changing Parameters
• CV_CURR_KEY: If you want to avoid reporting the incorrect currency key, update this
changing parameter based on the import parameters.
=====================================================================================
Parameters
The following list contains only the changing parameters that require additional information:
Changing Parameters
CV_ADDRESS CV_LAND
CV_EMAIL CV_POSTALCODE
CV_FAX CV_CITY
CV_PHONE_NO CV_COMP_NAME
CV_COMPANY_ID CV_TAX_REG_NO
CV_BUSS_NAME
=====================================================================================
Parameters
The following list contains only the changing parameters that require additional information:
Changing Parameters
The following parameters allow you to fill the material number for FI invoices:
• CV_MATNR
• CV_MATNR_DESC
=====================================================================================
You use this Business Add-In (BAdI) method to change the discount amount and condition type.
Note that the RPFIEU_SAFT report determines the discount amount based on the condition type
SKTO.
Parameters
The following list contains only the changing parameters that require additional information:
Changing Parameters
The following parameters allow you to change the discount amount and condition type:
• CV_KSCHL
• CV_DISCOUNT_AMT
=====================================================================================
Remarks:
- BADI Method called in ‘extraction’ and ‘generation’ (if any adjust repeat extraction process)
Parameters
The following list contains only the changing parameters that require additional information:
Changing Parameters
• CV_IND: If you want the asset postings to include auto generated lines, update this
changing parameter based on the import parameters.
=====================================================================================
26. BAdI Method: SET_DEL_MOV_DATES
You use this Business Add-In (BAdI) method to change MovementStartTime in Sales and
Distribution (SD) invoices.
Parameters
The following list contains only the changing parameters that require additional information:
Changing Parameters
The following parameters allow you to change the delivery date and movement start date:
• CV_MOV_DATE
=====================================================================================
Parameters
The following list contains only the changing parameters that require additional information:
Changing Parameters
• CV_SOURCEBILLING: If you want to change the invoice source billing, update this
changing parameter based on the import parameters.
By default, the status of the source billing is set to P. However, for external invoices, the
status is set to I.
=====================================================================================
Note
If the invoice status is A (canceled docs/cancellation) or F, then the debit/credit amounts
are not considered at the time of total debit/credit calculation.
For all other status options, the invoices are considered at the time of total debit/credit
calculation.
Parameters
The following list contains only the changing parameters that require additional information:
Changing Parameters
• CV_INV_STATUS: If you want to change the status of an SD invoice, update this
changing parameter based on the import parameters.
=====================================================================================
Note
If the invoice status is A (canceled docs/cancellation) or F, then the debit/credit amounts
are not considered at the time of total debit/credit calculation.
For all other status options, the invoices are considered at the time of total debit/credit
calculation.
Parameters
The following list contains only the changing parameters that require additional information:
Changing Parameters
• CV_INV_STATUS: If you want to change the status of a manual FI invoice, update this
changing parameter based on the import parameters.
Parameters
The following list contains only the changing parameters that require additional information:
Changing Parameters
==================================================================================
Parameters
The following list contains only the changing parameters that require additional information:
Changing Parameters
• CV_INV_LNES: if you want to change the value of the TaxPointDate parameter, update
this changing parameter with the desired value.
• CV_FLAG: if you changed any tax point date please return this parameter with an ‘X’.
==================================================================================
Parameters
The following list contains only the changing parameters that require additional information:
Changing Parameters
• CV_INV_LNES: update with the desired values, if you want to change the value of the
following parameters:
▪ Quantity
▪ Unit Price
▪ Credit Amount
▪ Debit Amount
▪ Tax Code
▪ Tax Amount
• CV_FLAG: if you changed any parameter please return this parameter with an ‘X’.
==================================================================================
Parameters
The following list contains only the changing parameters that require additional information:
Changing Parameters
==================================================================================
Parameters
The following list contains only the changing parameters that require additional information:
Changing Parameters
Parameters
The following list contains the required parameters. All importing parameters are optional. When
considering SD invoices, only the relevant SD fields will have values. When considering FI
invoices only the relevant FI fields will have values.
Importing Parameters
Changing Parameters
o CV_TAX_CODE: This can be used for special cases where the item does not have an
explicit tax code yet it must still be considered as a non-revenue based tax.