Skip to content
Snippets Groups Projects
Verified Commit 55e5ee43 authored by Alex Pott's avatar Alex Pott
Browse files

Issue #3421020 by godotislate, mohit_aghera, quietone: Convert MigrateField...

Issue #3421020 by godotislate, mohit_aghera, quietone: Convert MigrateField plugin discovery to attributes

(cherry picked from commit 8e51b463)
parent e4cb224d
No related branches found
No related tags found
25 merge requests!11958Issue #3490507 by alexpott, smustgrave: Fix bogus mocking in...,!11769Issue #3517987: Add option to contextual filters to encode slashes in query parameter.,!11185Issue #3477324 by andypost, alexpott: Fix usage of str_getcsv() and fgetcsv() for PHP 8.4,!10602Issue #3438769 by vinmayiswamy, antonnavi, michelle, amateescu: Sub workspace does not clear,!10301Issue #3469309 by mstrelan, smustgrave, moshe weitzman: Use one-time login...,!10187Issue #3487488 by dakwamine: ExtensionMimeTypeGuesser::guessMimeType must support file names with "0" (zero) like foo.0.zip,!9944Issue #3483353: Consider making the createCopy config action optionally fail...,!9929Issue #3445469 by pooja_sharma, smustgrave: Add additional test coverage for...,!9787Resolve issue 3479427 - bootstrap barrio issue under Windows,!9742Issue #3463908 by catch, quietone: Split OptionsFieldUiTest into two,!9526Issue #3458177 by mondrake, catch, quietone, godotislate, longwave, larowlan,...,!8738Issue #3424162 by camilledavis, dineshkumarbollu, smustgrave: Claro...,!8704Make greek characters available in ckeditor5,!8597Draft: Issue #3442259 by catch, quietone, dww: Reduce time of Migrate Upgrade tests...,!8533Issue #3446962 by kim.pepper: Remove incorrectly added...,!8517Issue #3443748 by NexusNovaz, smustgrave: Testcase creates false positive,!8325Update file Sort.php,!8095Expose document root on install,!7930Resolve #3427374 "Taxonomytid viewsargumentdefault plugin",!7627Issue #3439440 by nicxvan, Binoli Lalani, longwave: Remove country support from DateFormatter,!7445Issue #3440169: When using drupalGet(), provide an associative array for $headers,!7384Add constraints to system.advisories,!6502Draft: Resolve #2938524 "Plach testing issue",!38582585169-10.1.x,!3226Issue #2987537: Custom menu link entity type should not declare "bundle" entity key
Pipeline #139416 canceled
Showing
with 190 additions and 189 deletions
......@@ -3,23 +3,22 @@
namespace Drupal\field\Plugin\migrate\field;
use Drupal\migrate\Plugin\MigrationInterface;
use Drupal\migrate_drupal\Attribute\MigrateField;
use Drupal\migrate_drupal\Plugin\migrate\field\FieldPluginBase;
// cspell:ignore spamspan
/**
* MigrateField Plugin for Drupal 6 and 7 email fields.
*
* @MigrateField(
* id = "email",
* core = {6,7},
* type_map = {
* "email" = "email"
* },
* source_module = "email",
* destination_module = "core"
* )
*/
#[MigrateField(
id: 'email',
core: [6, 7],
type_map: [
'email' => 'email',
],
source_module: 'email',
destination_module: 'core',
)]
class Email extends FieldPluginBase {
/**
......
......@@ -2,23 +2,23 @@
namespace Drupal\field\Plugin\migrate\field\d7;
use Drupal\migrate_drupal\Attribute\MigrateField;
use Drupal\migrate_drupal\Plugin\migrate\field\FieldPluginBase;
// cspell:ignore entityreference
/**
* MigrateField plugin for Drupal 7 entity_reference fields.
*
* @MigrateField(
* id = "entityreference",
* type_map = {
* "entityreference" = "entity_reference",
* },
* core = {7},
* source_module = "entityreference",
* destination_module = "core"
* )
*/
#[MigrateField(
id: 'entityreference',
core: [7],
type_map: [
'entityreference' => 'entity_reference',
],
source_module: 'entityreference',
destination_module: 'core',
)]
class EntityReference extends FieldPluginBase {
/**
......
......@@ -2,21 +2,21 @@
namespace Drupal\field\Plugin\migrate\field\d7;
use Drupal\migrate_drupal\Attribute\MigrateField;
use Drupal\migrate_drupal\Plugin\migrate\field\FieldPluginBase;
/**
* MigrateField plugin for Drupal 7 number fields.
*
* @MigrateField(
* id = "number_default",
* type_map = {
* "number_integer" = "integer",
* "number_decimal" = "decimal",
* "number_float" = "float",
* },
* core = {7},
* source_module = "number",
* destination_module = "core"
* )
*/
#[MigrateField(
id: 'number_default',
core: [7],
type_map: [
'number_integer' => 'integer',
'number_decimal' => 'decimal',
'number_float' => 'float',
],
source_module: 'number',
destination_module: 'core',
)]
class NumberField extends FieldPluginBase {}
......@@ -4,18 +4,19 @@
use Drupal\migrate\Plugin\MigrationInterface;
use Drupal\migrate\Row;
use Drupal\migrate_drupal\Attribute\MigrateField;
use Drupal\migrate_drupal\Plugin\migrate\field\FieldPluginBase;
// cspell:ignore filefield imagefield imagelink nodelink
/**
* @MigrateField(
* id = "filefield",
* core = {6},
* source_module = "filefield",
* destination_module = "file"
* )
* MigrateField Plugin for Drupal 6 file fields.
*/
#[MigrateField(
id: 'filefield',
core: [6],
source_module: 'filefield',
destination_module: 'file',
)]
class FileField extends FieldPluginBase {
/**
......
......@@ -4,17 +4,18 @@
use Drupal\file\Plugin\migrate\field\d6\FileField as D6FileField;
use Drupal\migrate\Plugin\MigrationInterface;
use Drupal\migrate_drupal\Attribute\MigrateField;
// cspell:ignore filefield
/**
* @MigrateField(
* id = "file",
* core = {7},
* source_module = "file",
* destination_module = "file"
* )
* MigrateField Plugin for Drupal 7 file fields.
*/
#[MigrateField(
id: 'file',
core: [7],
source_module: 'file',
destination_module: 'file',
)]
class FileField extends D6FileField {
/**
......
......@@ -3,15 +3,16 @@
namespace Drupal\image\Plugin\migrate\field\d6;
use Drupal\file\Plugin\migrate\field\d6\FileField;
use Drupal\migrate_drupal\Attribute\MigrateField;
// cspell:ignore imagefield
/**
* @MigrateField(
* id = "imagefield",
* core = {6},
* source_module = "imagefield",
* destination_module = "image"
* )
* MigrateField Plugin for Drupal 6 image fields.
*/
#[MigrateField(
id: 'imagefield',
core: [6],
source_module: 'imagefield',
destination_module: 'image',
)]
class ImageField extends FileField {}
......@@ -3,16 +3,15 @@
namespace Drupal\image\Plugin\migrate\field\d7;
use Drupal\migrate\Plugin\MigrationInterface;
use Drupal\migrate_drupal\Attribute\MigrateField;
use Drupal\migrate_drupal\Plugin\migrate\field\FieldPluginBase;
/**
* @MigrateField(
* id = "image",
* core = {7},
* source_module = "image",
* destination_module = "image"
* )
*/
#[MigrateField(
id: 'image',
core: [7],
source_module: 'image',
destination_module: 'image',
)]
class ImageField extends FieldPluginBase {
/**
......
......@@ -3,19 +3,18 @@
namespace Drupal\link\Plugin\migrate\field\d6;
use Drupal\migrate\Plugin\MigrationInterface;
use Drupal\migrate_drupal\Attribute\MigrateField;
use Drupal\migrate_drupal\Plugin\migrate\field\FieldPluginBase;
/**
* @MigrateField(
* id = "link",
* core = {6},
* type_map = {
* "link" = "link",
* },
* source_module = "link",
* destination_module = "link"
* )
*/
#[MigrateField(
id: 'link',
core: [6],
type_map: [
'link' => 'link',
],
source_module: 'link',
destination_module: 'link',
)]
class LinkField extends FieldPluginBase {
/**
......
......@@ -4,22 +4,24 @@
use Drupal\link\Plugin\migrate\field\d6\LinkField as D6LinkField;
use Drupal\migrate\Plugin\MigrationInterface;
use Drupal\migrate_drupal\Attribute\MigrateField;
/**
* @MigrateField(
* id = "link_field",
* core = {7},
* type_map = {
* "link_field" = "link"
* },
* source_module = "link",
* destination_module = "link"
* )
* MigrateField Plugin for Drupal 7 link fields.
*
* This plugin provides the exact same functionality as the Drupal 6 "link"
* plugin with the exception that the plugin ID "link_field" is used in the
* field type map.
*/
#[MigrateField(
id: 'link_field',
core: [7],
type_map: [
'link_field' => 'link',
],
source_module: 'link',
destination_module: 'link',
)]
class LinkField extends D6LinkField {
/**
......
......@@ -4,23 +4,23 @@
// cspell:ignore nodereference
use Drupal\migrate_drupal\Attribute\MigrateField;
use Drupal\migrate_drupal\Plugin\migrate\field\ReferenceBase;
/**
* MigrateField Plugin for Drupal 6 node reference fields.
*
* @MigrateField(
* id = "nodereference",
* core = {6},
* type_map = {
* "nodereference" = "entity_reference",
* },
* source_module = "nodereference",
* destination_module = "core",
* )
*
* @internal
*/
#[MigrateField(
id: 'nodereference',
core: [6],
type_map: [
'nodereference' => 'entity_reference',
],
source_module: 'nodereference',
destination_module: 'core',
)]
class NodeReference extends ReferenceBase {
/**
......
......@@ -5,23 +5,22 @@
// cspell:ignore userreference
use Drupal\migrate\Plugin\MigrationInterface;
use Drupal\migrate_drupal\Attribute\MigrateField;
use Drupal\migrate_drupal\Plugin\migrate\field\ReferenceBase;
/**
* MigrateField Plugin for Drupal 6 user reference fields.
*
* @MigrateField(
* id = "userreference",
* core = {6},
* type_map = {
* "userreference" = "entity_reference",
* },
* source_module = "userreference",
* destination_module = "core",
* )
*
* @internal
*/
#[MigrateField(
id: 'userreference',
core: [6],
type_map: [
'userreference' => 'entity_reference',
],
source_module: 'userreference',
destination_module: 'core',
)]
class UserReference extends ReferenceBase {
/**
......
......@@ -2,21 +2,21 @@
namespace Drupal\migrate_drupal\Plugin\migrate\field\d7;
use Drupal\migrate_drupal\Attribute\MigrateField;
use Drupal\migrate_drupal\Plugin\migrate\field\ReferenceBase;
/**
* MigrateField plugin for Drupal 7 node_reference fields.
*
* @MigrateField(
* id = "node_reference",
* type_map = {
* "node_reference" = "entity_reference",
* },
* core = {7},
* source_module = "node_reference",
* destination_module = "core"
* )
*/
#[MigrateField(
id: 'node_reference',
core: [7],
type_map: [
'node_reference' => 'entity_reference',
],
source_module: 'node_reference',
destination_module: 'core',
)]
class NodeReference extends ReferenceBase {
/**
......
......@@ -3,21 +3,21 @@
namespace Drupal\migrate_drupal\Plugin\migrate\field\d7;
use Drupal\migrate\Plugin\MigrationInterface;
use Drupal\migrate_drupal\Attribute\MigrateField;
use Drupal\migrate_drupal\Plugin\migrate\field\ReferenceBase;
/**
* MigrateField plugin for Drupal 7 user_reference fields.
*
* @MigrateField(
* id = "user_reference",
* type_map = {
* "user_reference" = "entity_reference",
* },
* core = {7},
* source_module = "user_reference",
* destination_module = "core"
* )
*/
#[MigrateField(
id: 'user_reference',
core: [7],
type_map: [
'user_reference' => 'entity_reference',
],
source_module: 'user_reference',
destination_module: 'core',
)]
class UserReference extends ReferenceBase {
/**
......
......@@ -2,17 +2,19 @@
namespace Drupal\migrate_field_plugin_manager_test\Plugin\migrate\field;
use Drupal\migrate_drupal\Attribute\MigrateField;
use Drupal\migrate_drupal\Plugin\migrate\field\FieldPluginBase;
/**
* @MigrateField(
* id = "d6_file",
* core = {6},
* type_map = {
* "file" = "file"
* },
* source_module = "foo",
* destination_module = "bar"
* )
* MigrateField Plugin for Drupal 6 file fields.
*/
#[MigrateField(
id: 'd6_file',
core: [6],
type_map: [
'file' => 'file',
],
source_module: 'foo',
destination_module: 'bar',
)]
class D6FileField extends FieldPluginBase {}
......@@ -2,13 +2,12 @@
namespace Drupal\migrate_field_plugin_manager_test\Plugin\migrate\field;
use Drupal\migrate_drupal\Attribute\MigrateField;
use Drupal\migrate_drupal\Plugin\migrate\field\FieldPluginBase;
/**
* @MigrateField(
* id = "d6_no_core_version_specified",
* source_module = "foo",
* destination_module = "bar",
* )
*/
#[MigrateField(
id: 'd6_no_core_version_specified',
source_module: 'foo',
destination_module: 'bar',
)]
class D6NoCoreVersionSpecified extends FieldPluginBase {}
......@@ -2,16 +2,17 @@
namespace Drupal\options\Plugin\migrate\field\d6;
use Drupal\migrate_drupal\Attribute\MigrateField;
use Drupal\migrate_drupal\Plugin\migrate\field\FieldPluginBase;
// cspell:ignore optionwidgets
/**
* @MigrateField(
* id = "optionwidgets",
* core = {6},
* source_module = "optionwidgets",
* destination_module = "options"
* )
* MigrateField Plugin for Drupal 6 options fields.
*/
#[MigrateField(
id: 'optionwidgets',
core: [6],
source_module: 'optionwidgets',
destination_module: 'options',
)]
class OptionWidgetsField extends FieldPluginBase {}
......@@ -2,20 +2,19 @@
namespace Drupal\options\Plugin\migrate\field\d7;
use Drupal\migrate_drupal\Attribute\MigrateField;
use Drupal\migrate_drupal\Plugin\migrate\field\FieldPluginBase;
/**
* @MigrateField(
* id = "list",
* type_map = {
* "list_boolean" = "boolean",
* "list_integer" = "list_integer",
* "list_text" = "list_string",
* "list_float" = "list_float",
* },
* core = {7},
* source_module = "list",
* destination_module = "options"
* )
*/
#[MigrateField(
id: 'list',
core: [7],
type_map: [
'list_boolean' => 'boolean',
'list_integer' => 'list_integer',
'list_text' => 'list_string',
'list_float' => 'list_float',
],
source_module: 'list',
destination_module: 'options',
)]
class ListField extends FieldPluginBase {}
......@@ -2,14 +2,13 @@
namespace Drupal\options\Plugin\migrate\field\d7;
use Drupal\migrate_drupal\Attribute\MigrateField;
use Drupal\migrate_drupal\Plugin\migrate\field\FieldPluginBase;
/**
* @MigrateField(
* id = "options",
* core = {7},
* source_module = "options",
* destination_module = "options"
* )
*/
#[MigrateField(
id: 'options',
core: [7],
source_module: 'options',
destination_module: 'options',
)]
class OptionsField extends FieldPluginBase {}
......@@ -3,21 +3,22 @@
namespace Drupal\taxonomy\Plugin\migrate\field;
use Drupal\migrate\Plugin\MigrationInterface;
use Drupal\migrate_drupal\Attribute\MigrateField;
use Drupal\migrate_drupal\Plugin\migrate\field\FieldPluginBase;
// cspeLL:ignore entityreference
/**
* @MigrateField(
* id = "taxonomy_term_reference",
* type_map = {
* "taxonomy_term_reference" = "entity_reference"
* },
* core = {6,7},
* source_module = "taxonomy",
* destination_module = "core",
* )
* MigrateField Plugin for Drupal 6 & Drupal 7 taxonomy term reference fields.
*/
#[MigrateField(
id: 'taxonomy_term_reference',
core: [6, 7],
type_map: [
'taxonomy_term_reference' => 'entity_reference',
],
source_module: 'taxonomy',
destination_module: 'core',
)]
class TaxonomyTermReference extends FieldPluginBase {
/**
......
......@@ -2,19 +2,18 @@
namespace Drupal\telephone\Plugin\migrate\field\d7;
use Drupal\migrate_drupal\Attribute\MigrateField;
use Drupal\migrate_drupal\Plugin\migrate\field\FieldPluginBase;
/**
* @MigrateField(
* id = "phone",
* type_map = {
* "phone" = "telephone",
* },
* core = {7},
* source_module = "phone",
* destination_module = "telephone"
* )
*/
#[MigrateField(
id: 'phone',
core: [7],
type_map: [
'phone' => 'telephone',
],
source_module: 'phone',
destination_module: 'telephone',
)]
class PhoneField extends FieldPluginBase {
/**
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment