I am trying to merging content types while migrating to drupal 8 from drupal 7 and at the same time differentiating them with the taxonomy terms in D8. E.g. The content types from D7 i.e. Article, Page, Blog will merge to a content types called "Media" in D8. But in D8 "Media" content type, there will be a vocabulary "Type of content" with terms as Article, Page and Blog, so that while migrating from D7, the content of Article will be tagged to "Article" term in "Media" content type and same for others.
I am able to merge them to single content type in D8, by giving destination plugin for each content type as -
destination:
plugin: 'entity:node'
default_bundle: media
but not able to figure out how to tagged with "Type of content" vocabulary. This is additional field which is present in D8 but not in D7.
I tried to add
$row->setSourceProperty('field_type_of_content', $type_of_content);
$row->setDestinationProperty('field_type_of_content', $type_of_content);
code in hook_migrate_prepare_row() but not working...
Any suggestion. Thanks in Advance.
Regards Sunil Singh