function NodeComplete::prepareRow
Overrides Node::prepareRow
File
-
core/
modules/ node/ src/ Plugin/ migrate/ source/ d7/ NodeComplete.php, line 67
Class
- NodeComplete
- Drupal 7 all node revisions source, including translation revisions.
Namespace
Drupal\node\Plugin\migrate\source\d7Code
public function prepareRow(Row $row) {
// Override properties when this is an entity translation revision. The tnid
// will be set in d7_node source plugin to the value of 'nid'.
if ($row->getSourceProperty('etr_created')) {
$row->setSourceProperty('vid', $row->getSourceProperty('revision_id'));
$row->setSourceProperty('created', $row->getSourceProperty('etr_created'));
$row->setSourceProperty('timestamp', $row->getSourceProperty('etr_changed'));
$row->setSourceProperty('revision_uid', $row->getSourceProperty('etr_uid'));
$row->setSourceProperty('source_langcode', $row->getSourceProperty('source'));
}
return parent::prepareRow($row);
}