GridFieldExportButton
class GridFieldExportButton implements GridField_HTMLProvider, GridField_ActionProvider, GridField_URLHandler (View source)
Adds an "Export list" button to the bottom of a {@link GridField}.
Properties
static private bool | $xls_export_disabled | Set to true to disable XLS sanitisation [SS-2017-007] Ensure all cells with leading [@=+] have a leading tab |
Methods
No description
export is an action button
Handle an action on the given {@link GridField}.
Handle the export, for both the action button and the URL
No description
No description
No description
No description
No description
No description
No description
No description
Details
__construct(string $targetFragment = "after", array $exportColumns = null)
array
getHTMLFragments(GridField $gridField)
Place the export button in a
tag below the field
array
getActions($gridField)
export is an action button
handleAction(GridField $gridField, string $actionName, array $arguments, array $data)
Handle an action on the given {@link GridField}.
Calls ALL components for every action handled, so the component needs to ensure it only accepts actions it is actually supposed to handle.
array
getURLHandlers(GridField $gridField)
it is also a URL
HTTPResponse
handleExport(GridField $gridField, HTTPRequest $request = null)
Handle the export, for both the action button and the URL
string
generateExportFileData(GridField $gridField)
Generate export fields for CSV.