【发布时间】:2012-11-22 14:10:05
【问题描述】:
我正在尝试在 Sitecore 的父页面上列出具有设置模板的项目。到目前为止,我可以为孩子们做这件事,但我也想包括孩子们的孩子,即父母下的任何东西,如果它有选择的模板,它将起作用,这是我在 c# 文件中的代码:
lvThing.DataSource = context.Children.Where(x => x.TemplateName == "cool template").ToList<Item>();
lvThing.DataBind();
【问题讨论】: