Merge remote-tracking branch 'origin/temp8' into bugfix/temp8-media-could-not-be-moved-to-root
# Conflicts: # src/Umbraco.Web.UI.Client/src/views/content/move.html # src/Umbraco.Web.UI.Client/src/views/media/restore.html
This commit is contained in:
@@ -10,7 +10,6 @@ using System.Web.Http;
|
||||
using Umbraco.Core;
|
||||
using Umbraco.Core.Models;
|
||||
using Umbraco.Core.Services;
|
||||
using Umbraco.Web.Composing;
|
||||
using Umbraco.Web.Models.Trees;
|
||||
using Umbraco.Web.Mvc;
|
||||
using Umbraco.Web.WebApi;
|
||||
@@ -79,10 +78,20 @@ namespace Umbraco.Web.Trees
|
||||
}
|
||||
}
|
||||
|
||||
var multiTree = TreeRootNode.CreateMultiTreeRoot(collection);
|
||||
multiTree.Name = Services.TextService.Localize("sections/" + application);
|
||||
if(collection.Count > 0)
|
||||
{
|
||||
var multiTree = TreeRootNode.CreateMultiTreeRoot(collection);
|
||||
multiTree.Name = Services.TextService.Localize("sections/" + application);
|
||||
|
||||
return multiTree;
|
||||
return multiTree;
|
||||
}
|
||||
|
||||
//Otherwise its a application/section with no trees (aka a full screen app)
|
||||
//For example we do not have a Forms tree definied in C# & can not attribute with [Tree(isSingleNodeTree:true0]
|
||||
var rootId = Constants.System.Root.ToString(CultureInfo.InvariantCulture);
|
||||
var section = Services.TextService.Localize("sections/" + application);
|
||||
|
||||
return TreeRootNode.CreateSingleTreeRoot(rootId, null, null, section, TreeNodeCollection.Empty, true);
|
||||
}
|
||||
|
||||
var rootNodeGroups = new List<TreeRootNode>();
|
||||
|
||||
Reference in New Issue
Block a user