function FieldTestHooks::entityQueryEntityTestMulrevAlter

Same name and namespace in other branches
  1. 11.x core/modules/field/tests/modules/field_test/src/Hook/FieldTestHooks.php \Drupal\field_test\Hook\FieldTestHooks::entityQueryEntityTestMulrevAlter()

Implements hook_entity_query_ENTITY_TYPE_alter() for 'entity_test_mulrev'.

Attributes

#[Hook('entity_query_entity_test_mulrev_alter')]

See also

Drupal\KernelTests\Core\Entity\EntityQueryTest::testAlterHook

File

core/modules/field/tests/modules/field_test/src/Hook/FieldTestHooks.php, line 159

Class

FieldTestHooks
Hook implementations for field_test.

Namespace

Drupal\field_test\Hook

Code

public function entityQueryEntityTestMulrevAlter(QueryInterface $query) : void {
  if ($query->hasTag('entity_query_entity_test_mulrev_alter_hook_test')) {
    $query->condition('id', '7', '<>');
  }
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.