mirror of
https://github.com/lidarr/Lidarr
synced 2025-01-30 10:51:42 +00:00
Fixed: Episode/Season searches on BTN are now performed by tvdb numbering instead of scene numbering. (let us know if you run into problems with series with scene numbering)
This commit is contained in:
parent
4d837a46af
commit
e143b18df3
1 changed files with 18 additions and 10 deletions
|
@ -34,10 +34,15 @@ public virtual IList<IEnumerable<IndexerRequest>> GetSearchRequests(SingleEpisod
|
|||
var parameters = new BroadcastheNetTorrentQuery();
|
||||
if (AddSeriesSearchParameters(parameters, searchCriteria))
|
||||
{
|
||||
parameters.Category = "Episode";
|
||||
parameters.Name = String.Format("S{0:00}E{1:00}", searchCriteria.SeasonNumber, searchCriteria.EpisodeNumber);
|
||||
foreach (var episode in searchCriteria.Episodes)
|
||||
{
|
||||
parameters = parameters.Clone();
|
||||
|
||||
pageableRequest.AddIfNotNull(GetPagedRequests(MaxPages, parameters));
|
||||
parameters.Category = "Episode";
|
||||
parameters.Name = String.Format("S{0:00}E{1:00}", episode.SeasonNumber, episode.EpisodeNumber);
|
||||
|
||||
pageableRequest.AddIfNotNull(GetPagedRequests(MaxPages, parameters));
|
||||
}
|
||||
}
|
||||
|
||||
return pageableRequest;
|
||||
|
@ -50,17 +55,20 @@ public virtual IList<IEnumerable<IndexerRequest>> GetSearchRequests(SeasonSearch
|
|||
var parameters = new BroadcastheNetTorrentQuery();
|
||||
if (AddSeriesSearchParameters(parameters, searchCriteria))
|
||||
{
|
||||
parameters.Category = "Episode";
|
||||
parameters.Name = String.Format("S{0:00}E%", searchCriteria.SeasonNumber);
|
||||
foreach (var seasonNumber in searchCriteria.Episodes.Select(v => v.SeasonNumber).Distinct())
|
||||
{
|
||||
parameters.Category = "Episode";
|
||||
parameters.Name = String.Format("S{0:00}E%", seasonNumber);
|
||||
|
||||
pageableRequest.AddIfNotNull(GetPagedRequests(MaxPages, parameters));
|
||||
pageableRequest.AddIfNotNull(GetPagedRequests(MaxPages, parameters));
|
||||
|
||||
parameters = parameters.Clone();
|
||||
parameters = parameters.Clone();
|
||||
|
||||
parameters.Category = "Season";
|
||||
parameters.Name = String.Format("Season {0}", searchCriteria.SeasonNumber);
|
||||
parameters.Category = "Season";
|
||||
parameters.Name = String.Format("Season {0}", seasonNumber);
|
||||
|
||||
pageableRequest.AddIfNotNull(GetPagedRequests(MaxPages, parameters));
|
||||
pageableRequest.AddIfNotNull(GetPagedRequests(MaxPages, parameters));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue