public function MigrateExecutable::onPreRowSave in Migrate Tools 8.5
Same name and namespace in other branches
- 8 src/MigrateExecutable.php \Drupal\migrate_tools\MigrateExecutable::onPreRowSave()
- 8.2 src/MigrateExecutable.php \Drupal\migrate_tools\MigrateExecutable::onPreRowSave()
- 8.3 src/MigrateExecutable.php \Drupal\migrate_tools\MigrateExecutable::onPreRowSave()
- 8.4 src/MigrateExecutable.php \Drupal\migrate_tools\MigrateExecutable::onPreRowSave()
React to an item about to be imported.
Parameters
\Drupal\migrate\Event\MigratePreRowSaveEvent $event: The pre-save event.
File
- src/
MigrateExecutable.php, line 339
Class
- MigrateExecutable
- Defines a migrate executable class for drush.
Namespace
Drupal\migrate_toolsCode
public function onPreRowSave(MigratePreRowSaveEvent $event) {
$id_map = $event
->getRow()
->getIdMap();
if (!empty($id_map['destid1'])) {
$this->preExistingItem = TRUE;
}
else {
$this->preExistingItem = FALSE;
}
}