You are here

public function CommentType::fields in Drupal 8

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

core/modules/comment/src/Plugin/migrate/source/d7/CommentType.php, line 78

Class

CommentType
Drupal 7 comment type source from database.

Namespace

Drupal\comment\Plugin\migrate\source\d7

Code

public function fields() {
  return [
    'label' => $this
      ->t('The label of the comment type.'),
    'bundle' => $this
      ->t('Bundle ID of the comment type.'),
    'node_type' => $this
      ->t('The node type to which this comment type is attached.'),
    'default_mode' => $this
      ->t('Default comment mode.'),
    'per_page' => $this
      ->t('Number of comments visible per page.'),
    'anonymous' => $this
      ->t('Whether anonymous comments are allowed.'),
    'form_location' => $this
      ->t('Location of the comment form.'),
    'preview' => $this
      ->t('Whether previews are enabled for the comment type.'),
    'subject' => $this
      ->t('Whether a subject field is enabled for the comment type.'),
  ];
}