function ConfigTranslationFieldListBuilder::buildRow

Same name in other branches
  1. 9 core/modules/config_translation/src/Controller/ConfigTranslationFieldListBuilder.php \Drupal\config_translation\Controller\ConfigTranslationFieldListBuilder::buildRow()
  2. 8.9.x core/modules/config_translation/src/Controller/ConfigTranslationFieldListBuilder.php \Drupal\config_translation\Controller\ConfigTranslationFieldListBuilder::buildRow()
  3. 11.x core/modules/config_translation/src/Controller/ConfigTranslationFieldListBuilder.php \Drupal\config_translation\Controller\ConfigTranslationFieldListBuilder::buildRow()

Overrides ConfigTranslationEntityListBuilder::buildRow

File

core/modules/config_translation/src/Controller/ConfigTranslationFieldListBuilder.php, line 123

Class

ConfigTranslationFieldListBuilder
Defines the config translation list builder for field entities.

Namespace

Drupal\config_translation\Controller

Code

public function buildRow(EntityInterface $entity) {
    $row['label'] = [
        'data' => $entity->label(),
        'class' => 'table-filter-text-source',
    ];
    if ($this->displayBundle()) {
        $bundle = $entity->get('bundle');
        $row['bundle'] = [
            'data' => $this->baseEntityBundles[$bundle]['label'],
            'class' => 'table-filter-text-source',
        ];
    }
    return $row + parent::buildRow($entity);
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.