Event data
The plug-in events have access to this.data referencing the plug-in data for the interactive grid, file, and plug-in methods.
Properties of this.data are listed in the table below:
Property | Description |
---|---|
this.data.element | jQuery reference to the triggering element. |
this.data.file | An object describing a downloaded file. See the property description in the table below. Available only for File Download - file is ready and File Download - file downloaded events. |
this.data.fn | An object containing references to the plug-in methods. See the property description in the table below. Available only for File Download - file is ready and File Download - file downloaded events. |
this.data.grid | The interactiveGridView interface returned from the getViews interactiveGrid widget method. |
this.data.record | The result of the grids widget method getContextRecord. |
this.data.recordId | Record id returned by the model interface using the getRecordId method. |
this.data.region | The region interface returned from the execution of apex.region. |
Properties of this.data.file are listed in the table below.
Property | Description |
---|---|
this.data.file.content | Fetched file contents (base64 clob). Result of apex_web_service.blob2clobbase64. |
this.data.file.id | BLOB file id. |
this.data.file.name | Fetched file name with extension. |
this.data.file.size | Fetched file size in bytes. |
this.data.file.type | Fetched file mime type. |
Properties of this.data.fn are listed in the table below.
Property | Description | Returns | Arguments |
---|---|---|---|
this.data.fn.download | Function initializing the transfer of the file to the end-user’s browser using an AJAX request. When the file is transferred (AJAX call ends) the callback function is executed. The callback function is executed with changed context (this) to an object similar to this.data variable. Additionally, you can reference a file’s contents using this.data.file.content. | Promise | Callback Function |
this.data.fn.downloadandsave | Function initializing the transfer of the file to the end-user’s browser using an AJAX request. When the file is transferred (AJAX call ends) it automatically downloads the file. | Promise | None |
this.data.fn.newtab | Function opening the file contents in a new browser tab. | Promise | None |
this.data.fn.preview | Function opening an image or file preview in an inline popup. | Promise | None |
this.data.fn.savefile | Function initializing the download of the file in the end-user’s browser. If the file is not yet available the plug-in raises an error. | An object describing the downloaded file (name, size, type, and content) | None |