d7_field_instance.yml

Same filename in other branches
  1. 9 core/modules/field/migrations/d7_field_instance.yml
  2. 10 core/modules/field/migrations/d7_field_instance.yml
  3. 11.x core/modules/field/migrations/d7_field_instance.yml
core/modules/field/migrations/d7_field_instance.yml

File

core/modules/field/migrations/d7_field_instance.yml

View source
  1. id: d7_field_instance
  2. label: Field instance configuration
  3. migration_tags:
  4. - Drupal 7
  5. - Configuration
  6. class: Drupal\migrate_drupal\Plugin\migrate\FieldMigration
  7. field_plugin_method: alterFieldInstanceMigration
  8. source:
  9. plugin: d7_field_instance
  10. constants:
  11. status: true
  12. process:
  13. type:
  14. plugin: process_field
  15. source: type
  16. method: getFieldType
  17. entity_type: entity_type
  18. field_name: field_name
  19. # The bundle needs to be statically mapped in order to support comment types
  20. # that might already exist before this migration is run. See
  21. # d7_comment_type.yml for more information.
  22. bundle:
  23. plugin: static_map
  24. source: bundle
  25. bypass: true
  26. map:
  27. comment_node_forum: comment_forum
  28. label: label
  29. description: description
  30. required: required
  31. status: 'constants/status'
  32. allowed_values:
  33. -
  34. plugin: sub_process
  35. source: allowed_vid
  36. process:
  37. -
  38. plugin: migration_lookup
  39. migration: d7_taxonomy_vocabulary
  40. source: vid
  41. settings:
  42. plugin: d7_field_instance_settings
  43. source:
  44. - settings
  45. - widget
  46. - field_definition
  47. default_value_function: ''
  48. default_value:
  49. plugin: d7_field_instance_defaults
  50. source:
  51. - default_value
  52. - widget
  53. translatable: translatable
  54. destination:
  55. plugin: entity:field_config
  56. migration_dependencies:
  57. required:
  58. - d7_field
  59. optional:
  60. - d7_node_type
  61. - d7_comment_type
  62. - d7_taxonomy_vocabulary

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