mirror of
https://github.com/colymba/GridFieldBulkEditingTools.git
synced 2024-10-22 09:05:57 +00:00
Force write record's file relation
This commit is contained in:
parent
0e6f2e6efb
commit
3aad957a69
@ -107,6 +107,7 @@ class GridFieldBulkUpload_Request extends RequestHandler
|
|||||||
|
|
||||||
// Attach the file to record.
|
// Attach the file to record.
|
||||||
$record->{"{$fileRelationName}ID"} = $uploadResponse['id'];
|
$record->{"{$fileRelationName}ID"} = $uploadResponse['id'];
|
||||||
|
$record->write();
|
||||||
|
|
||||||
// attached record to gridField relation
|
// attached record to gridField relation
|
||||||
$this->gridField->list->add($record);
|
$this->gridField->list->add($record);
|
||||||
@ -220,6 +221,7 @@ class GridFieldBulkUpload_Request extends RequestHandler
|
|||||||
|
|
||||||
// attach file
|
// attach file
|
||||||
$record->{"{$fileRelationName}ID"} = $attachResponse['id'];
|
$record->{"{$fileRelationName}ID"} = $attachResponse['id'];
|
||||||
|
$record->write();
|
||||||
|
|
||||||
// attached record to gridField relation
|
// attached record to gridField relation
|
||||||
$this->gridField->list->add($record);
|
$this->gridField->list->add($record);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user