Commit deferred data when creating/updating a pivot table.
This commit is contained in:
parent
1643cf69b9
commit
55bceba32c
|
|
@ -1176,7 +1176,7 @@ class RelationController extends ControllerBehavior
|
|||
foreach ($hyrdatedModels as $hydratedModel) {
|
||||
$modelsToSave = $this->prepareModelsToSave($hydratedModel, $saveData);
|
||||
foreach ($modelsToSave as $modelToSave) {
|
||||
$modelToSave->save();
|
||||
$modelToSave->save(null, $this->pivotWidget->getSessionKey());
|
||||
}
|
||||
}
|
||||
});
|
||||
|
|
@ -1194,7 +1194,7 @@ class RelationController extends ControllerBehavior
|
|||
|
||||
$modelsToSave = $this->prepareModelsToSave($hydratedModel, $saveData);
|
||||
foreach ($modelsToSave as $modelToSave) {
|
||||
$modelToSave->save();
|
||||
$modelToSave->save(null, $this->pivotWidget->getSessionKey());
|
||||
}
|
||||
|
||||
return ['#'.$this->relationGetId('view') => $this->relationRenderView()];
|
||||
|
|
|
|||
Loading…
Reference in New Issue