Merging feature/db into feature/trackParse

This commit is contained in:
Joseph Milazzo
2017-06-19 07:56:42 -05:00
168 changed files with 5696 additions and 673 deletions
+1 -9
View File
@@ -19,20 +19,12 @@ namespace NzbDrone.Core.Parser.Model
public long Size { get; set; }
public ParsedTrackInfo ParsedTrackInfo { get; set; }
public Artist Artist { get; set; }
public Album Album { get; set; }
public List<Track> Tracks { get; set; }
public QualityModel Quality { get; set; }
public MediaInfoModel MediaInfo { get; set; }
public bool ExistingFile { get; set; }
public string Album
{
get
{
return Tracks.Select(c => c.AlbumId).Distinct().Single();
}
}
public bool IsSpecial => Album != "";
public override string ToString()
{
@@ -0,0 +1,26 @@
using System;
using System.Collections.Generic;
using System.Linq;
using NzbDrone.Core.Music;
namespace NzbDrone.Core.Parser.Model
{
public class RemoteAlbum
{
public ReleaseInfo Release { get; set; }
public ParsedTrackInfo ParsedTrackInfo { get; set; }
public Artist Artist { get; set; }
public List<Album> Albums { get; set; }
public bool DownloadAllowed { get; set; }
public bool IsRecentAlbum()
{
return Albums.Any(e => e.ReleaseDate >= DateTime.UtcNow.Date.AddDays(-14));
}
public override string ToString()
{
return Release.Title;
}
}
}