mirror of
https://github.com/colymba/GridFieldBulkEditingTools.git
synced 2024-10-22 09:05:57 +00:00
Merge pull request #13 from s-m/create-callback
NEW: Added a callback before writing the record for the first time
This commit is contained in:
commit
381d6a28ad
@ -284,6 +284,9 @@ class GridFieldBulkImageUpload_Request extends RequestHandler {
|
|||||||
|
|
||||||
$record = Object::create($recordClass);
|
$record = Object::create($recordClass);
|
||||||
$record->setField($recordForeignKey, $recordForeignID);
|
$record->setField($recordForeignKey, $recordForeignID);
|
||||||
|
// passes the current gridfield-instance to a call-back method on the new object
|
||||||
|
$record->extend("onBulkImageUpload", $this->gridField);
|
||||||
|
|
||||||
$record->write();
|
$record->write();
|
||||||
|
|
||||||
$upload = new Upload();
|
$upload = new Upload();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user