You are here

LogViewsData.php in Log entity 8

Namespace

Drupal\log\Entity

File

src/Entity/LogViewsData.php
View source
<?php

namespace Drupal\log\Entity;

use Drupal\views\EntityViewsData;
use Drupal\views\EntityViewsDataInterface;

/**
 * Provides Views data for Log entities.
 */
class LogViewsData extends EntityViewsData implements EntityViewsDataInterface {

  /**
   * {@inheritdoc}
   */
  public function getViewsData() {
    $data = parent::getViewsData();
    $data['log']['table']['base'] = array(
      'field' => 'id',
      'title' => $this
        ->t('Log'),
      'help' => $this
        ->t('The Log ID.'),
    );
    return $data;
  }

}

Classes

Namesort descending Description
LogViewsData Provides Views data for Log entities.