public function Table::rollback in Migrate Plus 8.3
Same name and namespace in other branches
- 8.5 src/Plugin/migrate/destination/Table.php \Drupal\migrate_plus\Plugin\migrate\destination\Table::rollback()
- 8.4 src/Plugin/migrate/destination/Table.php \Drupal\migrate_plus\Plugin\migrate\destination\Table::rollback()
Delete the specified destination object from the target Drupal.
Parameters
array $destination_identifier: The ID of the destination object to delete.
Overrides DestinationBase::rollback
File
- src/
Plugin/ migrate/ destination/ Table.php, line 121
Class
- Table
- Provides table destination plugin.
Namespace
Drupal\migrate_plus\Plugin\migrate\destinationCode
public function rollback(array $destination_identifier) {
$delete = $this->dbConnection
->delete($this->tableName);
foreach ($destination_identifier as $field => $value) {
$delete
->condition($field, $value);
}
$delete
->execute();
}