FilterConditionListBuilder.php in Tooltip Taxonomy 8
File
src/Controller/FilterConditionListBuilder.php
View source
<?php
namespace Drupal\tooltip_taxonomy\Controller;
use Drupal\Core\Config\Entity\DraggableListBuilder;
use Drupal\Core\Entity\EntityInterface;
class FilterConditionListBuilder extends DraggableListBuilder {
protected $entitiesKey = 'conditions';
public function getFormId() {
return 'tooltip_taxonomy_filter_condition_list';
}
public function buildHeader() {
$header = [];
$header['label'] = $this
->t('Filter conditions');
return $header + parent::buildHeader();
}
public function buildRow(EntityInterface $entity) {
$row = [];
$row['label'] = $entity
->label();
return $row + parent::buildRow($entity);
}
}