EntityTestViewsHooks.php
Namespace
Drupal\entity_test\HookFile
-
core/
modules/ system/ tests/ modules/ entity_test/ src/ Hook/ EntityTestViewsHooks.php
View source
<?php
declare (strict_types=1);
namespace Drupal\entity_test\Hook;
use Drupal\Core\Hook\Attribute\Hook;
/**
* Hook implementations for entity_test.
*/
class EntityTestViewsHooks {
/**
* Implements hook_views_data_alter().
*/
public function viewsDataAlter(&$data) {
$data['entity_test']['name_alias'] = $data['entity_test']['name'];
$data['entity_test']['name_alias']['field']['real field'] = 'name';
}
}
Classes
Title | Deprecated | Summary |
---|---|---|
EntityTestViewsHooks | Hook implementations for entity_test. |
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.