You are here

public function Taxonomy::applies in Workbench Access 8

Check if this access scheme applies to the given entity.

Parameters

string $entity_type_id: Entity type ID.

string $bundle: Bundle ID.

Return value

bool TRUE if this access scheme applies to the entity.

Overrides AccessControlHierarchyInterface::applies

File

src/Plugin/AccessControlHierarchy/Taxonomy.php, line 255

Class

Taxonomy
Defines a hierarchy based on a Vocabulary.

Namespace

Drupal\workbench_access\Plugin\AccessControlHierarchy

Code

public function applies($entity_type_id, $bundle) {
  return (bool) $this
    ->getApplicableFields($entity_type_id, $bundle);
}