Last active
February 23, 2016 15:11
-
-
Save delta-9/8ab021086704dbaeef0c to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
id: example_content | |
label: Example content | |
migration_group: example | |
source: | |
plugin: example_content | |
target: db_migration | |
destination: | |
plugin: entity:node | |
process: | |
type: | |
plugin: default_value | |
default_value: article | |
title: title | |
uid: | |
plugin: default_value | |
default_value: 1 | |
changed: | |
plugin: example_date | |
source: updated_at | |
created: | |
plugin: example_date | |
source: created_at | |
sticky: | |
plugin: default_value | |
default_value: 0 | |
status: | |
plugin: default_value | |
default_value: 0 | |
'body/value': content | |
'body/summary': excerpt | |
'body/format': | |
plugin: default_value | |
default_value: full_html | |
# Use of the migration process plugin. | |
# That will use the id map of the specified migration | |
# to retrieve the corresponding id ('source' parameter) in the destination database. | |
field_image: | |
plugin: migration | |
migration: example_file | |
source: image_id | |
# Here its a multivalued fields we just pass an array of source ids. Nothing different, | |
# the transform() method wil be called on each value. | |
field_attached_files: | |
plugin: migration | |
migration: example_file | |
source: file_ids | |
# And the category, difference here is that the unique id is a string (the name of the category). | |
field_category: | |
plugin: migration | |
migration: example_category | |
source: category | |
# We define the migration that need to run first. | |
migration_dependencies: | |
required: | |
- example_file | |
- example_category |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment