public function CustomFilterListBuilder::buildRow in Custom filter 2.0.x
Same name and namespace in other branches
- 8 src/CustomFilterListBuilder.php \Drupal\customfilter\CustomFilterListBuilder::buildRow()
Builds a row for an entity in the entity listing.
Parameters
\Drupal\Core\Entity\EntityInterface $entity: The entity for this row of the list.
Return value
array A render array structure of fields for this entity.
Overrides EntityListBuilder::buildRow
See also
\Drupal\Core\Entity\EntityListBuilder::render()
File
- src/
CustomFilterListBuilder.php, line 31
Class
- CustomFilterListBuilder
- Provides a listing of Custom Filters.
Namespace
Drupal\customfilterCode
public function buildRow(EntityInterface $entity) {
$row['label'] = Link::fromTextAndUrl($entity
->label(), Url::fromRoute('customfilter.rules.list', [
'customfilter' => $entity
->id(),
]));
$row['id'] = $entity
->id();
// You probably want a few more properties here...
return $row + parent::buildRow($entity);
}