You are here

public function CurrencyListBuilder::buildRow in Price 3.x

Same name and namespace in other branches
  1. 8 src/CurrencyListBuilder.php \Drupal\price\CurrencyListBuilder::buildRow()
  2. 2.0.x src/CurrencyListBuilder.php \Drupal\price\CurrencyListBuilder::buildRow()
  3. 2.x src/CurrencyListBuilder.php \Drupal\price\CurrencyListBuilder::buildRow()
  4. 3.0.x src/CurrencyListBuilder.php \Drupal\price\CurrencyListBuilder::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/CurrencyListBuilder.php, line 28

Class

CurrencyListBuilder
Defines the list builder for currencies.

Namespace

Drupal\price

Code

public function buildRow(EntityInterface $entity) {
  $row = [
    'name' => $entity
      ->label(),
    'currencyCode' => $entity
      ->id(),
  ];
  return $row + parent::buildRow($entity);
}