You are here

public function KeywordListBuilder::buildRow in Bibliography & Citation 8

Same name and namespace in other branches
  1. 2.0.x modules/bibcite_entity/src/KeywordListBuilder.php \Drupal\bibcite_entity\KeywordListBuilder::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

modules/bibcite_entity/src/KeywordListBuilder.php, line 27

Class

KeywordListBuilder
Defines a class to build a listing of Keyword entities.

Namespace

Drupal\bibcite_entity

Code

public function buildRow(EntityInterface $entity) {

  /* @var $entity \Drupal\bibcite_entity\Entity\Keyword */
  $row['name'] = Link::createFromRoute($entity
    ->label(), 'entity.bibcite_keyword.canonical', [
    'bibcite_keyword' => $entity
      ->id(),
  ]);
  return $row + parent::buildRow($entity);
}