NewsletterListBuilder.php in Simplenews 8
File
src/NewsletterListBuilder.php
View source
<?php
namespace Drupal\simplenews;
use Drupal\Core\Config\Entity\ConfigEntityListBuilder;
use Drupal\Core\Entity\EntityInterface;
class NewsletterListBuilder extends ConfigEntityListBuilder {
public function buildHeader() {
$header['name'] = t('Newsletter name');
return $header + parent::buildHeader();
}
public function buildRow(EntityInterface $entity) {
$row['name'] = $entity
->label();
return $row + parent::buildRow($entity);
}
}