You are here

public function PushNotificationsTokenListBuilder::render in Push Notifications 8

Add token-specific messaging to table header.

Overrides EntityListBuilder::render

File

src/Entity/Controller/PushNotificationsTokenListBuilder.php, line 28
Contains Drupal\push_notifications\Entity\Controller\PushNotificationsTokenListBuilder.

Class

PushNotificationsTokenListBuilder
Provides a list controller for push_notifications_token entity.

Namespace

Drupal\push_notifications\Entity\Controller

Code

public function render() {
  $build['description'] = array(
    '#markup' => $this
      ->t('List of all tokens in the database.'),
  );
  $build['table'] = parent::render();
  $build['table']['table']['#empty'] = $this
    ->t('There are no device tokens registered yet.');
  return $build;
}