Add permissions to view vocabulary names

Created on 26 July 2020, over 4 years ago
Updated 13 August 2024, 3 months ago

The simple requirement

I am still falling foul of the fact that with out-of-the-box core a user without administrative rights to a taxonomy cannot view a vocabulary name.

Mine (and I'm sure many others') use case is that I have a bunch of terms spread across several vocabularies and I want to be able to use Views to present a nice overview page grouped by vocabulary but which is visible to users who have no administrative rights to terms withing those vocabularies.

This seems to be impossible to do in core but I'm sure I read some issue replies correctly that say that 'Taxonomy access fix' might sort that out.

Solution tried

I have installed 8.28 - 8.30 is quite broken and only appears to create two new 'View' perms per vocab rather than the intended 'Reorder terms in...' and 'View terms in...' but 2.8 is good.

HOWEVER, in order to allow basic users to view the vocabularies' names, I still have to apply the 'Reorder' permission to every vocab.

Negative effects of this solution

While doing so enables them to see the Vocab-grouped view as I want it also grants them access to...
/admin/structure/taxonomy

...and in turn they can attempt the 'List terms' therein and re-order them.
Fortunately any attempt by them to actually 'List terms' results in...

The website encountered an unexpected error. Please try again later.
Error: Call to a member function access() on null in taxonomy_access_fix_form_taxonomy_overview_terms_alter() (line 48 of modules/taxonomy_access_fix/taxonomy_access_fix.module).

taxonomy_access_fix_form_taxonomy_overview_terms_alter(Array, Object, 'taxonomy_overview_terms') (Line: 539)
Drupal\Core\Extension\ModuleHandler->alter('form', Array, Object, 'taxonomy_overview_terms') (Line: 838)
Drupal\Core\Form\FormBuilder->prepareForm('taxonomy_overview_terms', Array, Object) (Line: 279)
Drupal\Core\Form\FormBuilder->buildForm(Object, Object) (Line: 91)
Drupal\Core\Controller\FormController->getContentResult(Object, Object)

So they can't actually do any damage but it all seems a bit of an uncomfortable route to allow every simply to view the names of vocabularies to me!

Anyone got any brighter ideas?

Brighter than me ;-)

Thanks all.

✨ Feature request
Status

Fixed

Version

4.0

Component

Code

Created by

πŸ‡¬πŸ‡§United Kingdom SirClickALot Somerset

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • πŸ‡ΊπŸ‡ΈUnited States j. ayen green

    The new permission doesn't seem to be present in D10.

  • πŸ‡©πŸ‡ͺGermany FeyP

    @j. ayen green Thanks for letting us know. This is kind of an old issue that has already been fixed. I can see the permissions added in this issue just fine on Drupal 10.2.7 with the latest stable 4.0.1 release. If you don't see them, I'd consider this a bug. In that case, I'd ask you to please open a new issue, so that we can look into the problem. Please make sure to include your core version in the issue summary, in case there was a recent regression. Thanks.

  • πŸ‡ΊπŸ‡ΈUnited States j. ayen green

    @FeyP thanks! I was looking in the wrong place!

Production build 0.71.5 2024