Model.Title showing Description instead

Oct 3, 2011 at 3:43 PM

I just moved up to 3.1.0 to try and fix my culture switching problem, and now all my Dynamic Nodes are displaying the node Description when I call Model.Title.

Where should I be looking in source to find out when a DynamicNode switches to a SiteMapNodeModel?

Oct 3, 2011 at 5:16 PM
Edited Oct 3, 2011 at 6:21 PM

I think I found it.  This is using latest release code, not current checkin.

DefaultSiteMapProvider.cs (Line 942)
When building mvcNode from a dynamicNode, a bunch of properties are being populated from the dynamicNode.

 

if (!string.IsNullOrEmpty(dynamicNode.Title))
{
     clone.Title = dynamicNode.Title;
}
if (!string.IsNullOrEmpty(dynamicNode.Description))
{
     clone.Title = dynamicNode.Description;
}
if (!string.IsNullOrEmpty(dynamicNode.TargetFrame))
{
     clone.Title = dynamicNode.TargetFrame;
}
if (!string.IsNullOrEmpty(dynamicNode.ImageUrl))
{
     clone.Title = dynamicNode.ImageUrl;
}

They're all setting clone.Title, instead of their respective values.

I've also updated Issue #6331 with this info