Fixes issue with showing the recycle bin menu
This commit is contained in:
@@ -56,8 +56,15 @@ namespace Umbraco.Web.Trees
|
||||
var parentId = queryStrings.GetRequiredString("parentId");
|
||||
var tree = GetTree(queryStrings);
|
||||
|
||||
var rootIds = new[]
|
||||
{
|
||||
Core.Constants.System.Root.ToString(CultureInfo.InvariantCulture),
|
||||
Core.Constants.System.RecycleBinContent.ToString(CultureInfo.InvariantCulture),
|
||||
Core.Constants.System.RecycleBinMedia.ToString(CultureInfo.InvariantCulture)
|
||||
};
|
||||
|
||||
//if the id and the parentId are both -1 then we need to get the menu for the root node
|
||||
if (id == "-1" && parentId == "-1")
|
||||
if (rootIds.Contains(id) && parentId == "-1")
|
||||
{
|
||||
var attempt = tree.TryGetMenuFromLegacyTreeRootNode(queryStrings, Url);
|
||||
if (attempt.Success == false)
|
||||
|
||||
@@ -48,10 +48,10 @@ namespace Umbraco.Web.Trees
|
||||
public string Icon { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// The action to execute when the menu item is clicked. This is generally a route path.
|
||||
/// The view to render when the menu item is clicked. This is generally a route path.
|
||||
/// </summary>
|
||||
[DataMember(Name = "action")]
|
||||
public string Action { get; set; }
|
||||
[DataMember(Name = "view")]
|
||||
public string View { get; set; }
|
||||
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user