Update DefaultLayerEvaluationService.cs

This commit is contained in:
jtkech
2015-12-17 03:22:26 +01:00
parent 765f8f74a5
commit 3e9259ab68

View File

@@ -42,7 +42,7 @@ namespace Orchard.Widgets.Services{
// Once the Condition Engine is done: // Once the Condition Engine is done:
// Get Layers and filter by zone and rule // Get Layers and filter by zone and rule
// NOTE: .ForType("Layer") is faster than .Query<LayerPart, LayerPartRecord>() // NOTE: .ForType("Layer") is faster than .Query<LayerPart, LayerPartRecord>()
var activeLayers = _orchardServices.ContentManager.Query<LayerPart>().WithQueryHints(new QueryHints().ExpandParts<LayerPart>()).ForType("Layer").List(); var activeLayers = _orchardServices.ContentManager.Query<LayerPart>().ForType("Layer").List();
var activeLayerIds = new List<int>(); var activeLayerIds = new List<int>();
foreach (var activeLayer in activeLayers) { foreach (var activeLayer in activeLayers) {