Query notation for the sitecore 'source' field in template builder

╄→гoц情女王★ 提交于 2019-11-27 17:54:42

What you have here should work with the Droplink field. Perhaps you are referring to Droptree?

query:./ancestor::*[@@templatename='CountryHome']/METADATA/Regions/*

As for the TreelistEx, I don't think the default Treelist fields support Sitecore query. However, this article describes how to create a custom TreeList that supports it.

Stephen Pope

Fields that support Sitecore Query

Where you can use the syntax query: or fast: (for FastQuery):

  • Droplist
  • Grouped Droplist
  • DropLink
  • Grouped Droplink
  • Checklist
  • Multilist
  • Droptree

Fields that support Parameterized Datasource

Where you can use enhanced syntax with Parameterized datasource query:

  • Droptree †
  • Treelist
  • TreelistEx

Droptree only supports the Datasource and DatabaseName parameters.

The enhanced query string syntax includes the following parameters:

  • Datasource
  • DatabaseName
  • AllowMultipleSelection
  • IncludeItemsForDisplay
  • ExcludeItemsForDisplay
  • IncludeTemplatesForSelection
  • ExcludeTemplatesForSelection
  • IncludeTemplatesForDisplay
  • ExcludeTemplatesForDisplay

These are used like this: Datasource=/sitecore/content/home/Products/&IncludeTemplatesForDisplay=Product Category&ExcludeTemplatesForSelection=Product Description&IncludeTemplatesForSelection=Product Category

Mark Ursino has a great post on how to use this kind of syntax here.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!