Reflect depth by grouping result in view when using has taxonomy with depth

Created on 5 December 2023, 7 months ago
Updated 19 December 2023, 6 months ago

Problem/Motivation

I want to use a taxonomy to order multiple pages of links.

Taxonomy is used as the architecture of these pages. Here is the structure (N is the depth for terms), all in the same vocabulary.

Title 1 (N)
- Subcategory 1 (N-1)
- Subcategory 2 (N-1)
-- Sub subcategory (N-2)
- Subcategory 3 (N-1)

Title 2 (N)
- Subcategory 4 (N-1)
...

For All those categories (N to N-2) I want to attach nodes:

Title 1 (N)
node 1
- Subcategory 1 (N-1)
- node 2
- Subcategory 2 (N-1)
- node 3
-- Sub subcategory (N-2)
-- node 4
-- node 5
- Subcategory 3 (N-1)
- node 6

When I display the result of the view with the term ID of "Title 1 (N)" I am able to display all child terms and their attached nodes. But N-2 category is not attached to his parent term (N-1), his depth is flattened as if it a N-1 term. Resulting with this following architecture :

Contextual filter = Title 1 term ID

Title 1 (N)
node 1
- Subcategory 1 (N-1)
- node 2
- Subcategory 2 (N-1)
- node 3
- Sub subcategory (N-2)
- node 4
- node 5
- Subcategory 3 (N-1)
- node 6

Steps to reproduce

Content view
Relationship : term, parent Term
contextual filter : Has taxonomy term ID (with depth)
Content title
Group by term name (will display term name as title for attached node and will group them)

Proposed resolution

-

Remaining tasks

Find a way to group N-2 terms and attached nodes in the N-1 term group.

User interface changes

-

API changes

-

Data model changes

-

πŸ’¬ Support request
Status

Closed: works as designed

Version

10.1 ✨

Component
ViewsΒ  β†’

Last updated 1 minute ago

Created by

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

Comments & Activities

Production build 0.69.0 2024