You are here

public function ProductVariations::fields in Commerce Migrate 3.1.x

Same name and namespace in other branches
  1. 8.2 modules/commerce/src/Plugin/migrate/source/commerce1/ProductVariations.php \Drupal\commerce_migrate_commerce\Plugin\migrate\source\commerce1\ProductVariations::fields()
  2. 3.0.x modules/commerce/src/Plugin/migrate/source/commerce1/ProductVariations.php \Drupal\commerce_migrate_commerce\Plugin\migrate\source\commerce1\ProductVariations::fields()

Returns available fields on the source.

Return value

array Available fields in the source, keys are the field machine names as used in field mappings, values are descriptions.

Overrides MigrateSourceInterface::fields

File

modules/commerce/src/Plugin/migrate/source/commerce1/ProductVariations.php, line 22

Class

ProductVariations
Gets Commerce 1 commerce_product data from database.

Namespace

Drupal\commerce_migrate_commerce\Plugin\migrate\source\commerce1

Code

public function fields() {
  return [
    'product_id' => $this
      ->t('Product variation ID'),
    'sku' => $this
      ->t('SKU'),
    'title' => $this
      ->t('Title'),
    'type' => $this
      ->t('Type'),
    'language' => $this
      ->t('Language'),
    'status' => $this
      ->t('Status'),
    'created' => $this
      ->t('Created'),
    'changed' => $this
      ->t('Changes'),
    'data' => $this
      ->t('Data'),
    'commerce_price' => $this
      ->t('Price with amount, currency_code and fraction_digits'),
  ];
}