Redefine method GET_ATTCHMENT_CONTENT
This method is executed in the implementation class to retrieve the attachment content from the SAP object and return it back to OneList, allowing the user to see a list of attachments and to preview their content.
Method Parameters
Type | Name | Description |
---|---|---|
Importing | ID_DOC_ID | IQX - OneList Document ID structure |
Returning | RD_DOC_CONTENT | IQX - OneList Document content structure |
/IQX/ONELIST_DOCUMENT_ST (used for ID_DOC_ID)
Component | Type | Length | Description |
---|---|---|---|
DOC_ID | CHAR | 50 | IQX - OneList Attachment ID |
SOURCE | CHAR | 3 | IQX - OneList Document source |
Structure /IQX/ONELIST_DOC_CONTENT_ST (used for RD_DOC_CONTENT)
Component | Type | Length | Description |
---|---|---|---|
DOC_ID | CHAR | 50 | IQX - OneList Attachment ID |
CONTENT | STRING | Plain text for Binary in BASE64 format | |
ERROR_MESSAGE | STRING | Error message - if any |
Method Implementation
Custom ABAP logic can be implemented to retrieve the attachment content for the SAP document.
The default method GET_BDS_DOCUMENT_CONTENT from the base class can be called in the implementation:
METHOD get_attchment_content. rd_doc_content = me->get_bds_document_content( id_doc_id = id_doc_id ). ENDMETHOD.