mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-04-21 09:34:44 +01:00
denormalize seriesid
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
using MediaBrowser.Controller.Providers;
|
||||
using System;
|
||||
using MediaBrowser.Controller.Providers;
|
||||
using MediaBrowser.Model.Configuration;
|
||||
using System.Linq;
|
||||
using System.Runtime.Serialization;
|
||||
@@ -19,12 +20,18 @@ namespace MediaBrowser.Controller.Entities
|
||||
|
||||
[IgnoreDataMember]
|
||||
public string SeriesName { get; set; }
|
||||
public Guid? SeriesId { get; set; }
|
||||
|
||||
public string FindSeriesName()
|
||||
{
|
||||
return SeriesName;
|
||||
}
|
||||
|
||||
public Guid? FindSeriesId()
|
||||
{
|
||||
return SeriesId;
|
||||
}
|
||||
|
||||
public override bool CanDownload()
|
||||
{
|
||||
var locationType = LocationType;
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
|
||||
using System;
|
||||
|
||||
namespace MediaBrowser.Controller.Entities
|
||||
{
|
||||
public interface IHasSeries
|
||||
@@ -8,7 +10,8 @@ namespace MediaBrowser.Controller.Entities
|
||||
/// </summary>
|
||||
/// <value>The name of the series.</value>
|
||||
string SeriesName { get; set; }
|
||||
|
||||
string FindSeriesName();
|
||||
Guid? SeriesId { get; set; }
|
||||
Guid? FindSeriesId();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -248,7 +248,14 @@ namespace MediaBrowser.Controller.Entities.TV
|
||||
}
|
||||
|
||||
[IgnoreDataMember]
|
||||
public Guid? SeasonId { get; set; }
|
||||
public Guid? SeasonId { get; set; }
|
||||
public Guid? SeriesId { get; set; }
|
||||
|
||||
public Guid? FindSeriesId()
|
||||
{
|
||||
var series = Series;
|
||||
return series == null ? (Guid?)null : series.Id;
|
||||
}
|
||||
|
||||
public override IEnumerable<Guid> GetAncestorIds()
|
||||
{
|
||||
|
||||
@@ -237,12 +237,20 @@ namespace MediaBrowser.Controller.Entities.TV
|
||||
[IgnoreDataMember]
|
||||
public string SeriesName { get; set; }
|
||||
|
||||
public Guid? SeriesId { get; set; }
|
||||
|
||||
public string FindSeriesName()
|
||||
{
|
||||
var series = Series;
|
||||
return series == null ? SeriesName : series.Name;
|
||||
}
|
||||
|
||||
public Guid? FindSeriesId()
|
||||
{
|
||||
var series = Series;
|
||||
return series == null ? (Guid?)null : series.Id;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Gets the lookup information.
|
||||
/// </summary>
|
||||
|
||||
Reference in New Issue
Block a user