You are here

commerce1_product_attribute.yml in Commerce Migrate 8.2

modules/commerce/migrations/commerce1_product_attribute.yml

File

modules/commerce/migrations/commerce1_product_attribute.yml
View source
  1. id: commerce1_product_attribute
  2. label: Commerce attribute
  3. migration_tags:
  4. - Drupal 7
  5. - Commerce
  6. - Configuration
  7. source:
  8. plugin: commerce1_attribute
  9. process:
  10. # Set to true if row has an attribute.
  11. attribute:
  12. plugin: skip_on_empty
  13. method: row
  14. source: attribute
  15. # Use 29 characters so there are 3 spaces for the unique suffix.
  16. id:
  17. plugin: make_unique_entity_field
  18. entity_type: commerce_product_attribute
  19. field: id
  20. source: machine_name
  21. length: 29
  22. label: name
  23. elementType:
  24. plugin: static_map
  25. bypass: true
  26. source: display
  27. map:
  28. # Text field
  29. 0: text
  30. # Select box
  31. 1: select
  32. # Radio buttons
  33. 2: radios
  34. # Checkboxes
  35. 3: checkbox
  36. destination:
  37. plugin: entity:commerce_product_attribute
  38. destination_module: commerce_product
  39. migration_dependencies:
  40. required:
  41. - d7_field