fixes #715 - Support creating/editing collections (boxsets) in web client #715

This commit is contained in:
Luke Pulverenti
2014-03-07 13:48:55 -05:00
parent e00985d07c
commit 546acf0ebb
11 changed files with 184 additions and 20 deletions

View File

@@ -745,9 +745,9 @@ namespace MediaBrowser.Controller.Entities
var list = new List<BaseItem>();
AddChildrenToList(user, includeLinkedChildren, list, false, null);
var hasLinkedChildren = AddChildrenToList(user, includeLinkedChildren, list, false, null);
return list;
return hasLinkedChildren ? list.DistinctBy(i => i.Id).ToList() : list;
}
/// <summary>

View File

@@ -22,8 +22,8 @@ namespace MediaBrowser.Controller.Entities
public enum LinkedChildType
{
Manual = 1,
Shortcut = 2
Manual = 0,
Shortcut = 1
}
public class LinkedChildComparer : IEqualityComparer<LinkedChild>
@@ -39,7 +39,7 @@ namespace MediaBrowser.Controller.Entities
public int GetHashCode(LinkedChild obj)
{
return (obj.Path + obj.Type.ToString()).GetHashCode();
return (obj.Path + obj.Type).GetHashCode();
}
}
}

View File

@@ -51,9 +51,8 @@ namespace MediaBrowser.Controller.Library
/// Refreshes metadata for each user
/// </summary>
/// <param name="cancellationToken">The cancellation token.</param>
/// <param name="force">if set to <c>true</c> [force].</param>
/// <returns>Task.</returns>
Task RefreshUsersMetadata(CancellationToken cancellationToken, bool force = false);
Task RefreshUsersMetadata(CancellationToken cancellationToken);
/// <summary>
/// Renames the user.