function ReferenceBase::defineValueProcessPipeline

Same name and namespace in other branches
  1. 10 core/modules/migrate_drupal/src/Plugin/migrate/field/ReferenceBase.php \Drupal\migrate_drupal\Plugin\migrate\field\ReferenceBase::defineValueProcessPipeline()
  2. 11.x core/modules/migrate_drupal/src/Plugin/migrate/field/ReferenceBase.php \Drupal\migrate_drupal\Plugin\migrate\field\ReferenceBase::defineValueProcessPipeline()

Overrides FieldPluginBase::defineValueProcessPipeline

2 methods override ReferenceBase::defineValueProcessPipeline()
UserReference::defineValueProcessPipeline in core/modules/migrate_drupal/src/Plugin/migrate/field/d6/UserReference.php
Apply any custom processing to the field bundle migrations.
UserReference::defineValueProcessPipeline in core/modules/migrate_drupal/src/Plugin/migrate/field/d7/UserReference.php
Apply any custom processing to the field bundle migrations.

File

core/modules/migrate_drupal/src/Plugin/migrate/field/ReferenceBase.php, line 46

Class

ReferenceBase
Base class for Drupal reference fields.

Namespace

Drupal\migrate_drupal\Plugin\migrate\field

Code

public function defineValueProcessPipeline(MigrationInterface $migration, $field_name, $data) {
    $process = [
        'plugin' => 'sub_process',
        'source' => $field_name,
        'process' => [
            'target_id' => $this->entityId(),
        ],
    ];
    $migration->setProcessOfProperty($field_name, $process);
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.