Explorar o código

Added IsRoot and IsVirtualFolder to DTOBaseItem

LukePulverenti Luke Pulverenti luke pulverenti %!s(int64=13) %!d(string=hai) anos
pai
achega
6d7c29f6c8
Modificáronse 2 ficheiros con 13 adicións e 0 borrados
  1. 3 0
      MediaBrowser.Api/ApiService.cs
  2. 10 0
      MediaBrowser.Model/DTO/DTOBaseItem.cs

+ 3 - 0
MediaBrowser.Api/ApiService.cs

@@ -95,6 +95,9 @@ namespace MediaBrowser.Api
             if (folder != null)
             if (folder != null)
             {
             {
                 dto.SpecialCounts = folder.GetSpecialCounts(user);
                 dto.SpecialCounts = folder.GetSpecialCounts(user);
+
+                dto.IsRoot = folder.IsRoot;
+                dto.IsVirtualFolder = folder.IsVirtualFolder;
             }
             }
             
             
             return dto;
             return dto;

+ 10 - 0
MediaBrowser.Model/DTO/DTOBaseItem.cs

@@ -49,6 +49,16 @@ namespace MediaBrowser.Model.DTO
 
 
         public bool IsFolder { get; set; }
         public bool IsFolder { get; set; }
 
 
+        /// <summary>
+        /// If the item is a Folder this will determine if it's the Root or not
+        /// </summary>
+        public bool? IsRoot { get; set; }
+
+        /// <summary>
+        /// If the item is a Folder this will determine if it's a VF or not
+        /// </summary>
+        public bool? IsVirtualFolder { get; set; }
+        
         public Guid? ParentId { get; set; }
         public Guid? ParentId { get; set; }
 
 
         public string Type { get; set; }
         public string Type { get; set; }