Added VideoType.ISO and trimmed Person output size

This commit is contained in:
LukePulverenti Luke Pulverenti luke pulverenti 2012-08-23 08:59:40 -04:00
parent 4527a18738
commit 977f8e970a
4 changed files with 12 additions and 5 deletions

View File

@ -206,7 +206,9 @@ namespace MediaBrowser.Api
{
BaseItemPerson baseItemPerson = new BaseItemPerson();
baseItemPerson.PersonInfo = p;
baseItemPerson.Name = p.Name;
baseItemPerson.Overview = p.Overview;
baseItemPerson.Type = p.Type;
Person ibnObject = entities.First(i => i.Name.Equals(p.Name, StringComparison.OrdinalIgnoreCase));
@ -263,7 +265,7 @@ namespace MediaBrowser.Api
{
Id = entity.Id,
BaseItemCount = itemCount,
HasPrimaryImage = !string.IsNullOrEmpty(entity.PrimaryImagePath),
HasImage = !string.IsNullOrEmpty(entity.PrimaryImagePath),
Name = entity.Name
};
}

View File

@ -30,9 +30,11 @@ namespace MediaBrowser.Controller.Resolvers
{
if (IsVideoFile(args.Path))
{
VideoType type = Path.GetExtension(args.Path).EndsWith("", System.StringComparison.OrdinalIgnoreCase) ? VideoType.Iso : VideoType.VideoFile;
return new T()
{
VideoType = VideoType.VideoFile,
VideoType = type,
Path = args.Path
};
}

View File

@ -18,7 +18,7 @@ namespace MediaBrowser.Model.DTO
/// </summary>
public Guid Id { get; set; }
public bool HasPrimaryImage { get; set; }
public bool HasImage { get; set; }
/// <summary>
/// The number of items that have the genre, year, studio, etc
@ -31,7 +31,9 @@ namespace MediaBrowser.Model.DTO
/// </summary>
public class BaseItemPerson
{
public PersonInfo PersonInfo { get; set; }
public string Name { get; set; }
public string Overview { get; set; }
public string Type { get; set; }
public bool HasImage { get; set; }
}

View File

@ -37,6 +37,7 @@ namespace MediaBrowser.Model.Entities
public enum VideoType
{
VideoFile,
Iso,
DVD,
BluRay
}