mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-01-15 23:58:57 +00:00
update data queries
This commit is contained in:
@@ -23,17 +23,28 @@ namespace MediaBrowser.Controller.Dto
|
||||
public bool AddCurrentProgram { get; set; }
|
||||
|
||||
public DtoOptions()
|
||||
: this(true)
|
||||
{
|
||||
}
|
||||
|
||||
public DtoOptions(bool allFields)
|
||||
{
|
||||
Fields = new List<ItemFields>();
|
||||
ImageTypeLimit = int.MaxValue;
|
||||
EnableImages = true;
|
||||
EnableUserData = true;
|
||||
AddCurrentProgram = true;
|
||||
|
||||
Fields = Enum.GetNames(typeof (ItemFields))
|
||||
.Select(i => (ItemFields) Enum.Parse(typeof (ItemFields), i, true))
|
||||
.Except(DefaultExcludedFields)
|
||||
.ToList();
|
||||
if (allFields)
|
||||
{
|
||||
Fields = Enum.GetNames(typeof(ItemFields))
|
||||
.Select(i => (ItemFields)Enum.Parse(typeof(ItemFields), i, true))
|
||||
.Except(DefaultExcludedFields)
|
||||
.ToList();
|
||||
}
|
||||
else
|
||||
{
|
||||
Fields = new List<ItemFields>();
|
||||
}
|
||||
|
||||
ImageTypes = Enum.GetNames(typeof(ImageType))
|
||||
.Select(i => (ImageType)Enum.Parse(typeof(ImageType), i, true))
|
||||
|
||||
Reference in New Issue
Block a user