Symptom
During the configuration process of Output Parameters and the PDF file, QR Code has missing information in the URL or it has not been fully implemented.
Environment
SAP S/4HANA Cloud, Public Edition.
Reproducing the Issue
- Access eDocument Cockpit app
- Select related document
- display > PDF
- QR Code is missing or has incomplete data in URL.
Cause
Missing Configuration.
Resolution
SAP Help Customizing Your PDF Output contains all base documentation to support you on the steps below to change the URL presented in the QR Code:
- Create a Custom Field to store URL value, to be used on the QR Code field in the PDF file;
- Create/update Cloud BadI implementation for eDocument Colombia Invoice Header (EDOC_CO_ADAPT_PDF_INVOICE)
- Read field QRCode from the XML (input parameter)
Example on how to fill the custom field and read the QRCode field from the XML:
Getting validation date and time (yyyy-mm-ddThh:mm:ssZ)
TRY.
DATA(qrcode) = context-xml[ tagname = 'QRCode' ]-tagvalue.
CATCH cx_sy_itab_line_not_found. "#EC EMPTY_CATCH
ENDTRY. - From the QRCode field, implement ABAP logic to read the URL
Similar logic example for reading the URL from QRCode field:
DATA:
lt_string_table TYPE TABLE OF string,
lv_table_size TYPE i.SPLIT qrcode AT space INTO TABLE lt_string_table.
lv_table_size = lines( lt_string_table ).
qrcodeurl = VALUE #( lt_string_table[ lv_table_size ] DEFAULT VALUE #( ) ).
* Filling the custom field
"header_persistent_extension-yy1_qrcodecustomfield = qrcodeurl. - Create/update Custom Form and bind the custom field to the QR Code tag using Adobe Livecycle;
- Publish Custom Form and configure Specify Output Forms for PDF Generation for using the updated form, as mentioned in SAP Help Specify Output Forms for PDF Generation.
See Also
- SAP Help Customizing Your PDF Output
- SAP Help Specify Output Forms for PDF Generation
- SAP Help App Extensibility: eDocument Cockpit or Manage Electronic Documents
- DIAN's Anexo Tecnico 11.7 Código Bidimensional «QR»
Keywords
PDF, QR CODE, edocument cockpit, Colombia, EDOC_CO_ADAPT_PDF_INVOICE, adobe livecycle, Specify Output Forms for PDF Generation , KBA , CA-GTF-CSC-EDO-CO , Document Compliance Colombia , Problem