From 65443d9058b8abb985db88a796c9405c730622d9 Mon Sep 17 00:00:00 2001 From: Bertrand Le Roy Date: Thu, 21 Feb 2013 22:29:31 -0800 Subject: [PATCH] Updated comment for better accuracy about shape and template names. --HG-- branch : 1.x --- src/Orchard.Web/Core/Contents/Shapes.cs | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/Orchard.Web/Core/Contents/Shapes.cs b/src/Orchard.Web/Core/Contents/Shapes.cs index 741444b2a..6d48a4c91 100644 --- a/src/Orchard.Web/Core/Contents/Shapes.cs +++ b/src/Orchard.Web/Core/Contents/Shapes.cs @@ -14,14 +14,17 @@ namespace Orchard.Core.Contents { if (contentItem != null) { // Alternates in order of specificity. // Display type > content type > specific content > display type for a content type > display type for specific content + // BasicShapeTemplateHarvester.Adjust will then adjust the template name // Content__[DisplayType] e.g. Content-Summary displaying.ShapeMetadata.Alternates.Add("Content_" + EncodeAlternateElement(displaying.ShapeMetadata.DisplayType)); - // Content__[ContentType] e.g. Content-BlogPost + // Content__[ContentType] e.g. Content-BlogPost, + // adjusted to Content_[DisplayType]__[ContentType], e.g. Content.Summary-BlogPost displaying.ShapeMetadata.Alternates.Add("Content__" + EncodeAlternateElement(contentItem.ContentType)); - // Content__[Id] e.g. Content-42 + // Content__[Id] e.g. Content-42, + // adjusted to Content_[DisplayType]__[Id], e.g. Content.Summary-42 displaying.ShapeMetadata.Alternates.Add("Content__" + contentItem.Id); // Content_[DisplayType]__[ContentType] e.g. Content.Summary-BlogPost