protected function DestinationBase::setRollbackAction in Zircon Profile 8
Same name and namespace in other branches
- 8.0 core/modules/migrate/src/Plugin/migrate/destination/DestinationBase.php \Drupal\migrate\Plugin\migrate\destination\DestinationBase::setRollbackAction()
For a destination item being updated, set the appropriate rollback action.
Parameters
array $id_map: The map row data for the item.
2 calls to DestinationBase::setRollbackAction()
- EntityConfigBase::updateEntity in core/
modules/ migrate/ src/ Plugin/ migrate/ destination/ EntityConfigBase.php - Updates an entity with the contents of a row.
- EntityContentBase::updateEntity in core/
modules/ migrate/ src/ Plugin/ migrate/ destination/ EntityContentBase.php - Update an entity with the new values from row.
File
- core/
modules/ migrate/ src/ Plugin/ migrate/ destination/ DestinationBase.php, line 104 - Contains \Drupal\migrate\Plugin\migrate\destination\DestinationBase.
Class
- DestinationBase
- Base class for migrate destination classes.
Namespace
Drupal\migrate\Plugin\migrate\destinationCode
protected function setRollbackAction(array $id_map) {
// If the entity we're updating was previously migrated by us, preserve the
// existing rollback action.
if (isset($id_map['sourceid1'])) {
$this->rollbackAction = $id_map['rollback_action'];
}
else {
$this->rollbackAction = MigrateIdMapInterface::ROLLBACK_PRESERVE;
}
}