function BlockContentSelection::buildEntityQuery
File
-
core/
modules/ block_content/ src/ Plugin/ EntityReferenceSelection/ BlockContentSelection.php, line 27
Class
- BlockContentSelection
- Provides specific selection control for the block_content entity type.
Namespace
Drupal\block_content\Plugin\EntityReferenceSelectionCode
protected function buildEntityQuery($match = NULL, $match_operator = 'CONTAINS') {
$query = parent::buildEntityQuery($match, $match_operator);
// Only reusable blocks should be able to be referenced.
$query->condition('reusable', TRUE);
return $query;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.