从字段值创建视图 Drupal-7
因此,如果我理解正确,我将有一些内容类型“类别”、“子类别”、“产品”、“图像”,我只是不确定如何将内容类型相互关联以构建视图。因此,根据下面的结构:我将创建一个类别名称为“Home”且类型为“Category”的类别。该类别将有一个视图,显示与该视图“类别”关联的所有子类别。这是我的问题:当我创建新的子类别“家具”时,如何将其与“主页”类别页面上的视图关联起来?依此类推,所有产品都属于子类别,并且图像都属于产品。我可以使用用户添加字符串的自定义字段吗?
Home (category)
-Furniture (sub category)
-Sofa(product)
-images
-Lamp(product)
-images
Outdoors(category)
-Deck Furniture(sub category)
-Table(product)
-images
-Fire-pit(product)
-images
我确信这很令人困惑,所以如果有人有疑问,请询问。任何帮助都会很棒。提前致谢。
So if I understand correctly I have will a few content types "Category", "Sub Category", "Product", "Images" I am just not sure how I will associate the content types with each other to build views. So based on my structure below: I would create a Category name "Home" with the "Category" type. The category would have a view that shows all Sub Categories that are associated with this view "Category". This is my question: When I go to create my new Sub Category "Furniture" how do I associate it with the view that is on my "Home" Category page? And so on with the Products which will all belong to sub category and the images will all belong to a product. Can I use a custom field that the user adds a string?
Home (category)
-Furniture (sub category)
-Sofa(product)
-images
-Lamp(product)
-images
Outdoors(category)
-Deck Furniture(sub category)
-Table(product)
-images
-Fire-pit(product)
-images
I am sure this was confusing so if anyone has questions please ask. Any help would be amazing. Thanks in advance.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
你的问题有点令人困惑,因为它似乎有两个部分没有明确定义。
如果您希望将内容相互关联,请查看参考模块。
至于创建您正在寻找的显示,视图模块可能就是您正在寻找的。还有一个视图层次结构模块,您可能需要它,但目前在 Drupal 7 中不可用。
Your question is a little confusing because it seems that there are two parts to it that aren't clearly defined.
If you're looking to relate content to each other, check out the References module.
As for creating the display you're looking for, the Views module is likely what you're looking for. There is also a Views Hierarchy module which you may need but is currently unavailable for Drupal 7.