public function ConfigFieldMapper::getBaseRouteParameters in Drupal 8
Same name and namespace in other branches
- 9 core/modules/config_translation/src/ConfigFieldMapper.php \Drupal\config_translation\ConfigFieldMapper::getBaseRouteParameters()
Returns the route parameters for the base route the mapper is attached to.
Return value
array
Overrides ConfigEntityMapper::getBaseRouteParameters
File
- core/
modules/ config_translation/ src/ ConfigFieldMapper.php, line 27
Class
- ConfigFieldMapper
- Configuration mapper for fields.
Namespace
Drupal\config_translationCode
public function getBaseRouteParameters() {
$parameters = parent::getBaseRouteParameters();
$base_entity_info = $this->entityTypeManager
->getDefinition($this->pluginDefinition['base_entity_type']);
$bundle_parameter_key = $base_entity_info
->getBundleEntityType() ?: 'bundle';
$parameters[$bundle_parameter_key] = $this->entity
->getTargetBundle();
return $parameters;
}