WorkflowDefinitionExporter
class WorkflowDefinitionExporter (View source)
Allows workflow definitions to be exported from one SilverStripe install, ready for import into another.
YAML is used for export as it's native to SilverStripe's config system and we're using WorkflowTemplate for some of the import-specific heavy lifting, which is already heavily predicated on YAML.
Properties
public static | string | $export_filename_prefix | The base filename of the file to the exported |
|
protected | Member | $member | ||
protected | WorkflowDefinition | $workflowDefinition |
Methods
Details
void
__construct(number $definitionID)
No description
setMember(Member $member)
No description
WorkflowDefinition
getDefinition()
No description
string
export()
Runs the export
void
format(ArrayData $templateData)
Format the exported data as YAML.
number
getExportSize(string $str)
Returns the size of the current export in bytes.
Used for pushing data to the browser to prompt for download
ArrayData
ExportMetaData()
Generate template vars for metadata
SS_HTTPResponse
sendFile(array $filedata)
Prompt the client for file download.
We're "overriding" SS_HTTPRequest::send_file() for more robust cross-browser support