Symptom
Show ATF License on Form Template Item of Billing Document.
Environment
SAP S/4HANA Cloud Public Edition
Resolution
- Creation of an extension field at Billing Document Item
Use app Custom Fields and Logic, tab Custom Fields, in the Extensibility business catalog. Create a new extension field in Business Context ‘Billing Document Item’ with an appropriate length.
This extension field is intended to store the ATF License with the billing document item.
Remark: The extension field will only be filled when triggering the output request. -
Extend the Form Template with the Extension Field
Within the same App (Custom Fields and Logic) and tab (Custom Field) extend the Form Templates for the billing document with the extension field.
Save and publish the extension field.
-
Creation of an extension logic
Use app Custom Fields and Logic, tab Custom Logic, in the Extensibility business catalog. Create a new Enhancement Implementation in Business Context ‘Billing Document Item’ with Definition Description ‘Billing Standard Output Item Adaption’ and an appropriate Implementation Description.
Please Note: If you are using the FormTemplate for Standard please use Enhancement Implementation ‘Billing Standard Output Item Adaption’
Add the following example code to the Draft:
* First of all assign existing extension field values to output parameter:
billingdocitem_ext_out = billingdocitem_ext_in.
billingdocitemdescr_ext_out = billingdocitemdescr_ext_in.
* select the ATF License
select single ExtTrdCmplncLicense
from C_TrdCmplncDocItmLicAssgmt
where referencedocument = @billingdocitem-referencesddocument
and referencedocumentitem = @billingdocitem-referencesddocumentitem
into @billingdocitem_ext_out-yy1_atf_license_bdi.
Save and publish the extension Logic.
Remark: To see the new created extension field in the Billing Document Printout, it is necessary to create a new Form Template.
Remark2: The user who print the invoice / display the pdf need the following authorizations:
- ITM_LMGM: legal regulation and license type
- ITM_BURKS: license owner of the license
- ITM_BUKRS: company code for current compliance document
Keywords
ATF License, ATF, License, Output, Extensibility Fields, Extensibility, Billing, Billing Document , KBA , SD-BIL-GF-OC , Output Control Billing , SD-BF-OC , Output Determination , SD-BIL-GF-OC-2CL , Output Control Billing (Public Cloud) , Problem