Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. Action.php

function Action::fields

Overrides MigrateSourceInterface::fields

File

core/modules/system/src/Plugin/migrate/source/Action.php, line 29

Class

Action
Drupal action source from database.

Namespace

Drupal\system\Plugin\migrate\source

Code

public function fields() {
    $fields = [
        'aid' => $this->t('Action ID'),
        'type' => $this->t('Module'),
        'callback' => $this->t('Callback function'),
        'parameters' => $this->t('Action configuration'),
    ];
    if ($this->getModuleSchemaVersion('system') >= 7000) {
        $fields['label'] = $this->t('Label of the action');
    }
    else {
        $fields['description'] = $this->t('Action description');
    }
    return $fields;
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal