public function TransactionTypeListBuilder::buildRow in Transaction 8
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/
TransactionTypeListBuilder.php, line 153
Class
- TransactionTypeListBuilder
- Provides a entity list page for transaction types.
Namespace
Drupal\transactionCode
public function buildRow(EntityInterface $entity) {
/** @var \Drupal\transaction\TransactionTypeInterface $entity */
$row = [];
$row['label'] = [
'data' => $entity
->label(),
'class' => [
'menu-label',
],
];
$row['transactor'] = $this
->getTransactorPlugin($entity);
$row['target_entity_type'] = $this
->getTargetType($entity);
$row['target_entity_bundles'] = $this
->getTargetBundles($entity);
return $row + parent::buildRow($entity);
}