function entity_test_operation_entity_operation in Zircon Profile 8
Same name and namespace in other branches
- 8.0 core/modules/system/tests/modules/entity_test_operation/entity_test_operation.module \entity_test_operation_entity_operation()
Implements hook_entity_operation().
File
- core/
modules/ system/ tests/ modules/ entity_test_operation/ entity_test_operation.module, line 13 - Contains hook implementations for Entity Operation Test Module.
Code
function entity_test_operation_entity_operation(\Drupal\Core\Entity\EntityInterface $entity) {
return [
'test' => [
'title' => t('Front page'),
'url' => Url::fromRoute('<front>'),
'weight' => 0,
],
];
}