You are here

public function ConfigNamesMapper::getOperations in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 core/modules/config_translation/src/ConfigNamesMapper.php \Drupal\config_translation\ConfigNamesMapper::getOperations()

Provides an array of information to build a list of operation links.

Return value

array An associative array of operation link data for this list, keyed by operation name, containing the following key-value pairs:

  • title: The localized title of the operation.
  • href: The path for the operation.
  • options: An array of URL options for the path.
  • weight: The weight of this operation.

Overrides ConfigMapperInterface::getOperations

1 method overrides ConfigNamesMapper::getOperations()
ConfigEntityMapper::getOperations in core/modules/config_translation/src/ConfigEntityMapper.php
Provides an array of information to build a list of operation links.

File

core/modules/config_translation/src/ConfigNamesMapper.php, line 469
Contains \Drupal\config_translation\ConfigNamesMapper.

Class

ConfigNamesMapper
Configuration mapper base implementation.

Namespace

Drupal\config_translation

Code

public function getOperations() {
  return array(
    'translate' => array(
      'title' => $this
        ->t('Translate'),
      'url' => Url::fromRoute($this
        ->getOverviewRouteName(), $this
        ->getOverviewRouteParameters()),
    ),
  );
}