@@ -59,6 +59,8 @@ To access the vocabulary overview page for a vocabulary, users must have permiss
* create, edit, delete or reorder terms in that vocabulary in addition to the Taxonomy module's permission to "Access the taxonomy vocabulary overview page".
* to "Administer vocabularies and terms".
The module will replace the default entity reference selection plugin for Taxonomy Terms with an extended version that checks for a separate per-vocabulary permission to "select" terms. Note: Users with permission to select terms will be able to see the term labels of those terms in the results of the autocomplete widget, even if they don't have permission to "view" those terms. Only Entity Reference fields referencing Taxonomy terms using the "Default" reference method will honor this permission.
@@ -50,6 +50,14 @@ class TaxonomyAccessFixPermissions implements ContainerInjectionInterface {
'view any unpublished term'=>$this->t('View any unpublished term'),
'view any term name'=>$this->t('View any published term name'),
'view any unpublished term name'=>$this->t('View any unpublished term name'),
'select any term'=>[
'title'=>$this->t('Select any published term'),
'description'=>$this->t('Select published terms for Entity Reference fields referencing Taxonomy terms in any vocabulary using the "Default" reference method.'),
],
'select any unpublished term'=>[
'title'=>$this->t('Select any unpublished term'),
'description'=>$this->t('Select unpublished terms for Entity Reference fields referencing Taxonomy terms in any vocabulary using the "Default" reference method.'),
@@ -80,6 +88,18 @@ class TaxonomyAccessFixPermissions implements ContainerInjectionInterface {
'%vocabulary'=>$vocabulary->label(),
]),
];
$permissions['select terms in '.$vocabulary->id()]=[
'title'=>$this->t('Select published terms in %vocabulary',[
'%vocabulary'=>$vocabulary->label(),
]),
'description'=>$this->t('Select published terms for Entity Reference fields referencing Taxonomy terms in the specified vocabulary using the "Default" reference method.'),
];
$permissions['select unpublished terms in '.$vocabulary->id()]=[
'title'=>$this->t('Select unpublished terms in %vocabulary',[
'%vocabulary'=>$vocabulary->label(),
]),
'description'=>$this->t('Select unpublished terms for Entity Reference fields referencing Taxonomy terms in the specified vocabulary using the "Default" reference method.'),