Download & Extend

Multiple select multiple level hierarchy causes incorrect term tree to be displayed

Project:Taxonomy context
Version:5.x-1.x-dev
Component:Code
Category:bug report
Priority:normal
Assigned:Unassigned
Status:active

Issue Summary

It seems that PathAuto and Taxonomy_context handle multiple select, multiple level hierarchies in taxonomy differently. In PathAuto, if a node is associated with two different terms the URL alias that is created for nodes in that hierarchy will follow the term with the lowest weight, or, if both nodes are the same weight, the node with the lowest parent weight. In taxonomy_context it seems to work the opposite way, although this might just have been luck as I can't see where any sorting is done.

In my case, I had a multi-level multiple select hierarchy with my node pathauto settings as "[vocab-raw]/[termpath-raw]/[nid]". When I create a node that I have selected two or more terms from the hierarchy for, only one URL alias is created, that being the path to the node with the lowest weight. Once I select this node, I would expect that taxonomy_context would expand the menu tree following the same path set up by pathauto, but this doesn't seem to be the case. In all cases I've seen so far it expands the menu tree out to the un-aliased entry.

Sorry if this is less than understandable... if you need more information I'll do my best to help.

Comments

#1

It occurred to me that a visual might be a better idea...

Say I create a node and associate it with both the terms "Calgary Office" and "New Employees" from the following vocabulary:

News
--Office Updates <-- weight -9
----Calgary Office
----Regina Office
----Seattle Office
--News Releases <-- weight 0
----New Employees

With PathAuto, only one path would be created, using the terms with the lowest overall weight. In this case, the path would be similar to "news/office-updates/calgary-office/[nid]" where [nid] is the node id of the new item.
With taxonomy_context, the new item does show up in content listings in both locations, but when I actually visit the node, the tree output would look like this:

News
--Office Updates
--News Releases
----New Employees

instead of this:
News
--Office Updates
----Calgary Office <--this item should be set as active
----Regina Office
----Seattle Office
--News Releases
nobody click here