migrate_plus.migration.d7_node_materiau.yml 3.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163
  1. id: d7_node_materiau
  2. label: Node Materiau
  3. migration_group: d7_materio
  4. audit: true
  5. migration_tags:
  6. - Drupal 7
  7. - Content
  8. - Materio
  9. source:
  10. plugin: d7_node_materiau
  11. node_type: materiau
  12. batch_size: 500
  13. # high_water_property:
  14. # name: changed
  15. # alias: n
  16. destination:
  17. plugin: entity:node
  18. process:
  19. # nid: nid
  20. type:
  21. plugin: default_value
  22. default_value: materiau
  23. title: title
  24. created: created
  25. changed: changed
  26. uid:
  27. plugin: migration_lookup
  28. migration: d7_users
  29. source: uid
  30. field_short_description: field_nature_titre
  31. field_migration:
  32. plugin: default_value
  33. default_value: 'migration_imported'
  34. body:
  35. plugin: iterator
  36. source: field_description
  37. process:
  38. value: value
  39. format:
  40. plugin: default_value
  41. default_value: wysiwyg
  42. langcode: language
  43. field_memo: field_memo
  44. field_workflow:
  45. -
  46. plugin: default_value
  47. source: workflow
  48. default_value: 2
  49. # -
  50. # plugin: debug
  51. # source: workflow
  52. # label: workflow_debug
  53. -
  54. plugin: static_map
  55. default_value: 2
  56. map:
  57. 1: "workflow_creation"
  58. 2: "workflow_hidden"
  59. 3: "workflow_visible"
  60. 4: "workflow_imported"
  61. 5: "workflow_edited"
  62. field_thesaurus:
  63. plugin: migration_lookup
  64. migration: d7_taxonomy_term_thesaurus
  65. source: field_onthologie
  66. no_stub: true
  67. field_tags:
  68. plugin: migration_lookup
  69. migration: d7_taxonomy_term_tags
  70. source: field_tags_libres
  71. no_stub: true
  72. field_manufacturer:
  73. plugin: migration_lookup
  74. migration: d7_taxonomy_term_company
  75. source: field_company_fab
  76. no_stub: true
  77. field_distributor:
  78. plugin: migration_lookup
  79. migration: d7_taxonomy_term_company
  80. source: field_company_distrib
  81. no_stub: true
  82. field_video:
  83. plugin: iterator
  84. source: field_video_filter
  85. process:
  86. value: url
  87. field_linked_materials:
  88. -
  89. plugin: skip_on_empty
  90. method: process
  91. source: linked_materials
  92. -
  93. plugin: migration_lookup
  94. migration: d7_node_materiau
  95. no_stub: true
  96. field_linked_articles:
  97. -
  98. plugin: skip_on_empty
  99. method: process
  100. source: linked_articles
  101. -
  102. plugin: migration_lookup
  103. migration: d7_node_article
  104. # no_stub: true
  105. field_materiau_images:
  106. plugin: iterator
  107. source: field_materiau_image
  108. process:
  109. target_id:
  110. plugin: migration_lookup
  111. migration: d7_allpublicfiles
  112. source: fid
  113. no_stub: true
  114. alt: alt
  115. title: title
  116. height: height
  117. width: width
  118. field_attachments:
  119. plugin: iterator
  120. source: field_attachments
  121. process:
  122. target_id:
  123. plugin: migration_lookup
  124. migration: d7_allpublicfiles
  125. source: fid
  126. no_stub: true
  127. # there is no description field filled
  128. description: description
  129. field_famille: field_famille
  130. field_index: field_identifiant
  131. field_reference: field_reference_materio
  132. # just archives
  133. field_localisation_old: field_localisation
  134. # custom module rebuilded
  135. field_samples:
  136. plugin: iterator
  137. source: field_location
  138. process:
  139. location: location
  140. target_id:
  141. plugin: migration_lookup
  142. migration: d7_taxonomy_term_showroom
  143. source: showroom_tid
  144. no_stub: true
  145. migration_dependencies:
  146. required:
  147. - d7_allpublicfiles
  148. - d7_users
  149. - d7_taxonomy_term_thesaurus
  150. - d7_taxonomy_term_tags
  151. - d7_taxonomy_term_company
  152. - d7_taxonomy_term_showroom
  153. # optional:
  154. # - d7_node_article