|
|
|
@ -8,8 +8,6 @@ namespace NzbDrone.Core.Tv
|
|
|
|
|
{
|
|
|
|
|
public interface ISeasonRepository : IBasicRepository<Series>
|
|
|
|
|
{
|
|
|
|
|
Season Get(int seriesId, int seasonNumber);
|
|
|
|
|
bool IsMonitored(int seriesId, int seasonNumber);
|
|
|
|
|
List<Season> GetSeasonBySeries(int seriesId);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
@ -20,18 +18,6 @@ namespace NzbDrone.Core.Tv
|
|
|
|
|
{
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public Season Get(int seriesId, int seasonNumber)
|
|
|
|
|
{
|
|
|
|
|
var series = Query.Single(s => s.Id == seriesId);
|
|
|
|
|
return series.Seasons.Single(s => s.SeasonNumber == seasonNumber);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public bool IsMonitored(int seriesId, int seasonNumber)
|
|
|
|
|
{
|
|
|
|
|
var series = Query.Single(s => s.Id == seriesId);
|
|
|
|
|
return series.Seasons.Single(s => s.SeasonNumber == seasonNumber).Monitored;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public List<Season> GetSeasonBySeries(int seriesId)
|
|
|
|
|
{
|
|
|
|
|
return Query.Single(s => s.Id == seriesId).Seasons;
|
|
|
|
|