mirror of
https://github.com/lidarr/lidarr.git
synced 2025-08-14 02:37:08 -07:00
Replaced Telerik SeasonGrid with simple table.
This commit is contained in:
parent
02a3b38210
commit
f065d345a5
8 changed files with 310 additions and 48 deletions
|
@ -138,7 +138,7 @@ namespace NzbDrone.Web.Controllers
|
|||
return new EmptyResult();
|
||||
}
|
||||
|
||||
public ActionResult Details(int seriesId)
|
||||
public ActionResult Details2(int seriesId)
|
||||
{
|
||||
var series = _seriesProvider.GetSeries(seriesId);
|
||||
|
||||
|
@ -161,6 +161,42 @@ namespace NzbDrone.Web.Controllers
|
|||
return View(model);
|
||||
}
|
||||
|
||||
public ActionResult Details(int seriesId)
|
||||
{
|
||||
var series = _seriesProvider.GetSeries(seriesId);
|
||||
|
||||
var model = new SeriesDetailsModel();
|
||||
|
||||
if (series.AirsDayOfWeek != null)
|
||||
{
|
||||
model.AirsDayOfWeek = series.AirsDayOfWeek.Value.ToString();
|
||||
}
|
||||
else
|
||||
{
|
||||
model.AirsDayOfWeek = "N/A";
|
||||
}
|
||||
model.Overview = series.Overview;
|
||||
model.Title = series.Title;
|
||||
model.SeriesId = series.SeriesId;
|
||||
model.HasBanner = !String.IsNullOrEmpty(series.BannerUrl);
|
||||
|
||||
var seasons = new List<SeasonModel>();
|
||||
var episodes = _episodeProvider.GetEpisodeBySeries(seriesId);
|
||||
|
||||
foreach (var season in episodes.Select(s => s.SeasonNumber).Distinct())
|
||||
{
|
||||
seasons.Add(new SeasonModel
|
||||
{
|
||||
SeasonNumber = season,
|
||||
Episodes = GetEpisodeModels(episodes.Where(e => e.SeasonNumber == season).ToList()).OrderByDescending(e=> e.EpisodeNumber).ToList()
|
||||
});
|
||||
}
|
||||
|
||||
model.Seasons = seasons;
|
||||
|
||||
return View(model);
|
||||
}
|
||||
|
||||
public ActionResult MassEdit()
|
||||
{
|
||||
var profiles = _qualityProvider.All();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue