Drupal 节点按分类层次结构递归显示
我有一组按受众分类的节点,然后按内容类型进一步分类(所有节点都在相同的词汇表中并存储完整的分类层次结构)。
我想将它们显示在一个页面上,如下所示。
AUDIENCE (PARENT TERM)
Category1 (Child Term)
- node1 (title,teaser,whatever)
Category2 (Child Term)
- node2
- node3
Category3 (Child Term)
- Sub-Category1 (Child1 of Category3)
-- node4
-- node5
- Sub-Category2 (Child2 of Category3)
-- node4
-- node5
etc.
似乎应该有一个模块用于此目的,但我已经尝试了一些。分类谱系似乎最接近,但我还没有让它发挥作用。
非常感谢。
I've got a set of nodes categorized by audience and then further categorized by content type (all in the same vocabulary and storing the full taxonomy hierarchy).
I'd like to display these on a single page as follows.
AUDIENCE (PARENT TERM)
Category1 (Child Term)
- node1 (title,teaser,whatever)
Category2 (Child Term)
- node2
- node3
Category3 (Child Term)
- Sub-Category1 (Child1 of Category3)
-- node4
-- node5
- Sub-Category2 (Child2 of Category3)
-- node4
-- node5
etc.
It seems like there should be a module for this, but I've tried a few. Taxonomy Lineage seems to get closest, but I haven't gotten it to work.
Thanks much.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
视图可能(当然)可以以某种方式做到这一点,但它可能需要一些主题/模板才能按照您的意愿排列。
我确信您可以制作按分类术语分割的节点标题的链接列表。如果视图 1 或 2 中没有,则视图 3 应该启用它。
Views probably (Most certainly) can do this somehow, but it may require some theming/templating to get it lined up as you wish.
I'm sure you can make a linked list of node titles split by taxonomy term. If not in views 1 or 2, 3 should enable it.
@j-oh-n - 非常感谢你!我一直在研究类似的问题,终于找到了答案!
让我解释一下如何找到这样的选项。
样式设置->
样式:谱系嵌套列表 ->
嵌套字段:
分类法:层次结构
只是不要忘记将分类法:层次结构添加为字段!
@j-oh-n - thank you very much! I've been investigating similar problem and finally I've found the answer!
Let me just explain how to find such option.
Style settings ->
Style: Lineage nested list ->
Nesting Field:
Taxonomy: Hierarchy
Just don't foget to add Taxonomy: Hierarchy as a field!