Expose configuration for Relation

Created on 17 June 2016, almost 9 years ago
Updated 25 March 2025, 13 days ago

Problem/Motivation

Users such as site builders cannot configure settings about the relations of taxonomy terms.

Users (e.g. site builders) cannot configure whether taxonomy terms in a vocabulary can have parent-child relations. This means that other users can start nesting taxonomy terms even if the site is not build to deal with. (Example: A list of regions could have relationships such as continent/country/county; but a list of only countries should not.)

The two relation fields (parent term and weight) are hidden in a collapsed field set which cannot be expanded by default. The field set is not shown on Manage form display page, so site builders have no control on whether or where to show this to other users.
Issue #2655328: [PP-1] Relations Form Element static at weight 10 discusses assumptions on whether this should be displayed at the top or the bottom of the page, while in fact this decision is up to the site builder to make for their individual site.

Proposed resolution

Add an option to en-/disable relations for a vocabulary. This could either be a property of the vocabulary (then it should be placed on Edit page); or a configuration on a relations field on the Manage fields page.

Make Relations a field that can be configured on the Manage form display page. As a first step that would allow site builders not to display it for vocabularies without hierarchies.

Remaining tasks

This is a UI change and therefore the hook_help text for the Taxonomy module also needs to be changed.

User interface changes

This is a UI change.

API changes

Data model changes

Feature request
Status

Active

Version

11.0 🔥

Component

taxonomy.module

Created by

🇳🇱Netherlands ifrik

Live updates comments and jobs are added and updated live.
  • Usability

    Makes Drupal easier to use. Preferred over UX, D7UX, etc.

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.

  • First commit to issue fork.
  • 🇮🇳India KumudB Ahmedabad

    Since the Relations tab is available for content editors, site builders already have control over taxonomy term hierarchies. This means the request to "disable parent-child relations" might not be a critical issue but rather a feature request for more granular control.

    still proceed with a Merge Request to introduce the toggle for better flexibility?

Production build 0.71.5 2024