mirror of
https://github.com/lidarr/lidarr.git
synced 2025-07-12 08:07:10 -07:00
MediaFileProvider moved to PetaPoco.
Season Grid now shows episodeFile quality.
This commit is contained in:
parent
a151c9cd0f
commit
3dbb38b54f
5 changed files with 74 additions and 56 deletions
|
@ -235,14 +235,19 @@ namespace NzbDrone.Web.Controllers
|
|||
|
||||
foreach (var e in episodesInDb)
|
||||
{
|
||||
var episodeFile = e.EpisodeFile;
|
||||
var episodePath = String.Empty;
|
||||
var episodeFileId = 0;
|
||||
var episodePath = String.Empty;
|
||||
var episodeQuality = String.Empty;
|
||||
EpisodeFile episodeFile = null;
|
||||
|
||||
if (e.EpisodeFileId > 0)
|
||||
episodeFile = _mediaFileProvider.GetEpisodeFile(e.EpisodeFileId);
|
||||
|
||||
if (episodeFile != null)
|
||||
{
|
||||
episodePath = episodeFile.Path;
|
||||
episodeFileId = episodeFile.EpisodeFileId;
|
||||
episodeQuality = episodeFile.Quality.ToString();
|
||||
}
|
||||
|
||||
episodes.Add(new EpisodeModel
|
||||
|
@ -256,9 +261,7 @@ namespace NzbDrone.Web.Controllers
|
|||
Path = episodePath,
|
||||
EpisodeFileId = episodeFileId,
|
||||
Status = e.Status.ToString(),
|
||||
Quality = e.EpisodeFile == null
|
||||
? String.Empty
|
||||
: e.EpisodeFile.Quality.ToString()
|
||||
Quality = episodeQuality
|
||||
});
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue