public static string GetSeasonImagesHtmlOverview([NotNull] this ShowItem si, [NotNull] Season s) { SeriesInfo ser = s.TheSeries; int snum = s.SeasonNumber; string body = ""; List <ProcessedEpisode> eis = si.SeasonEpisodes.ContainsKey(snum) ? si.SeasonEpisodes[snum] : ShowItem.ProcessedListFromEpisodes(s.Episodes.Values, si); string seasText = Season.UIFullSeasonWord(snum); if ((eis.Count > 0) && (eis[0].SeasonId > 0)) { seasText = " - <A HREF=\"" + TheTVDB.Instance.WebsiteUrl(si.TvdbCode, eis[0].SeasonId, false) + "\">" + seasText + "</a>"; } else { seasText = " - " + seasText; } body += "<h1><A HREF=\"" + TheTVDB.Instance.WebsiteUrl(si.TvdbCode, -1, true) + "\">" + si.ShowName + "</A>" + seasText + "</h1>"; if (TVSettings.Instance.NeedToDownloadBannerFile()) { body += ImageSection("Series Banner", 758, 140, ser.GetSeasonWideBannerPath(snum)); body += ImageSection("Series Poster", 350, 500, ser.GetSeasonBannerPath(snum)); } else { body += "<h2>Images are not being downloaded for this series. Please see Options -> Preferences -> Media Center to reconfigure.</h2>"; } return(body); }
public string GetWideBannerPath() => TheSeries.GetSeasonWideBannerPath(SeasonNumber);
private string GetSeasonImagesHTMLOverview(ShowItem si, SeriesInfo ser, int snum) { string body = ""; Season s = ser.Seasons[snum]; List<ProcessedEpisode> eis = null; // int snum = s.SeasonNumber; if (si.SeasonEpisodes.ContainsKey(snum)) eis = si.SeasonEpisodes[snum]; // use processed episodes if they are available else eis = ShowItem.ProcessedListFromEpisodes(s.Episodes, si); string seasText = snum == 0 ? "Specials" : ("Season " + snum); if ((eis.Count > 0) && (eis[0].SeasonID > 0)) seasText = " - <A HREF=\"" + TheTVDB.Instance.WebsiteURL(si.TVDBCode, eis[0].SeasonID, false) + "\">" + seasText + "</a>"; else seasText = " - " + seasText; body += "<h1><A HREF=\"" + TheTVDB.Instance.WebsiteURL(si.TVDBCode, -1, true) + "\">" + si.ShowName + "</A>" + seasText + "</h1>"; body += ImageSection("Series Banner", 758, 140, ser.GetSeasonWideBannerPath(snum)); body += ImageSection("Series Poster", 350, 500, ser.GetSeasonBannerPath(snum)); return body; }