53 lines
1.1 KiB
YAML
53 lines
1.1 KiB
YAML
langcode: en
|
|
status: true
|
|
dependencies:
|
|
enforced:
|
|
module:
|
|
- farm_migrate
|
|
- farm_plant
|
|
id: farm_migrate_asset_plant
|
|
label: 'Assets (Plants)'
|
|
migration_group: farm_migrate_asset
|
|
migration_tags:
|
|
- 'Drupal 7'
|
|
- 'farmOS 1.x'
|
|
class: Drupal\migrate\Plugin\Migration
|
|
field_plugin_method: null
|
|
cck_plugin_method: null
|
|
source:
|
|
plugin: d7_farm_asset
|
|
bundle: planting
|
|
destination:
|
|
plugin: 'entity:asset'
|
|
process:
|
|
# Hard-code the bundle.
|
|
type:
|
|
plugin: default_value
|
|
default_value: plant
|
|
# Maintain the asset ID.
|
|
id:
|
|
plugin: get
|
|
source: id
|
|
# Plant specific fields.
|
|
plant_type:
|
|
plugin: sub_process
|
|
source: field_farm_crop
|
|
process:
|
|
target_id:
|
|
plugin: migration_lookup
|
|
migration: farm_migrate_taxonomy_plant_type
|
|
source: tid
|
|
season:
|
|
plugin: sub_process
|
|
source: field_farm_season
|
|
process:
|
|
target_id:
|
|
plugin: migration_lookup
|
|
migration: farm_migrate_taxonomy_season
|
|
source: tid
|
|
migration_dependencies:
|
|
required:
|
|
- farm_migrate_taxonomy_plant_type
|
|
- farm_migrate_taxonomy_season
|
|
optional: { }
|