Colymba\BulkUpload\BulkUploader
GridField component for uploading images in bulk.
- Author: colymba
Synopsis
class BulkUploader
implements
GridField_HTMLProvider,GridField_URLHandler
{
- // members
- protected array $config = ;
- protected boolean $autoPublishDataObject = false;
- protected array $ufSetup = ;
- // methods
- public void __construct()
- public void setConfig()
- public void setAutoPublishDataObject()
- public boolean getAutoPublishDataObject()
- public void setUfSetup()
- public mixed getConfig()
- public mixed getUfSetup()
- public string getRecordClassName()
- public string getDefaultFileRelationName()
- public string getFileRelationName()
- public string getFileRelationClassName()
- public UploadField bulkUploadField()
- public array getHTMLFragments()
- public array getURLHandlers()
- public mixed handleBulkUpload()
Hierarchy
Implements
- SilverStripe\Forms\GridField\GridField_HTMLProvider
- SilverStripe\Forms\GridField\GridField_URLHandler
Members
protected
- $autoPublishDataObject
—
boolean
If true, the component will Publish Versioned DataObject if fasle they will be left as draft. - $config
—
array
Component configuration. - $ufSetup
—
array
UploadField setup function calls.
Methods
public
- __construct() — Component constructor.
- bulkUploadField() — Returned a configured UploadField instance embedded in the gridfield heard.
- getAutoPublishDataObject() — Get Versioned DataObject auto publish config
- getConfig() — Returns one $config reference or the full $config.
- getDefaultFileRelationName() — Get the first has_one Image/File relation from the GridField managed DataObject i.e. 'MyImage' => 'Image' will return 'MyImage'.
- getFileRelationClassName() — Return the ClassName of the fileRelation i.e. 'MyImage' => 'Image' will return 'Image' i.e. 'MyImage' => 'File' will return 'File'.
- getFileRelationName() — Returns the name of the Image/File field name from the managed record Either as set in the component config or the default one.
- getHTMLFragments() — HTML to be embedded into the GridField.
- getRecordClassName() — Returns the class name of container `DataObject` record.
- getURLHandlers() — Component URL handlers.
- getUfSetup() — Returns one $ufSetup reference or the full config.
- handleBulkUpload() — Pass control over to the RequestHandler.
- setAutoPublishDataObject() — Set Versioned DataObject auto publish config
- setConfig() — Set a component configuration parameter.
- setUfSetup() — Set an UploadField setup function call.