Gets the content tree controller to return the names for items per language (with mock data), wires up the navigation.controller to re-build the tree for the new language

This commit is contained in:
Shannon
2018-04-17 01:37:35 +10:00
parent f7719773f2
commit d45112f2ab
6 changed files with 186 additions and 82 deletions

View File

@@ -47,10 +47,11 @@ namespace Umbraco.Web.Trees
/// <inheritdoc />
protected override TreeNode GetSingleTreeNode(IEntitySlim entity, string parentId, FormDataCollection queryStrings)
{
var langId = queryStrings["languageId"].TryConvertTo<int?>();
var allowedUserOptions = GetAllowedUserMenuItemsForNode(entity);
if (CanUserAccessNode(entity, allowedUserOptions))
if (CanUserAccessNode(entity, allowedUserOptions, langId.Success ? langId.Result : null))
{
//Special check to see if it ia a container, if so then we'll hide children.
var isContainer = entity.IsContainer; // && (queryStrings.Get("isDialog") != "true");