Enables listview children in dialog trees

By default trees doesnt show children of listview nodes, this enables
them in dialog trees, otherwise content pickers cannot select childrens
of a listview node
This commit is contained in:
perploug
2014-01-27 22:03:52 +01:00
parent e17b32c6e5
commit c2d978a0db
3 changed files with 8 additions and 3 deletions

View File

@@ -78,7 +78,7 @@ namespace Umbraco.Web.Trees
var entity = (UmbracoEntity)e;
//Special check to see if it ia a container, if so then we'll hide children.
var isContainer = entity.IsContainer();
var isContainer = e.IsContainer() && (queryStrings.Get("isDialog") != "true");
var node = CreateTreeNode(
e.Id.ToInvariantString(),
@@ -89,6 +89,8 @@ namespace Umbraco.Web.Trees
entity.HasChildren && (isContainer == false));
node.AdditionalData.Add("contentType", entity.ContentTypeAlias);
if (isContainer)
node.SetContainerStyle();