1
0
mirror of https://github.com/Radarr/Radarr.git synced 2026-04-24 22:35:49 -04:00

New: Add support for prioritizing indexers (#5000)

This commit is contained in:
nitsua
2020-09-12 02:25:32 -04:00
committed by GitHub
parent 4fafdcabb7
commit 9a46d5165c
14 changed files with 125 additions and 18 deletions
@@ -10,6 +10,7 @@ namespace Radarr.Api.V3.Indexers
public bool SupportsRss { get; set; }
public bool SupportsSearch { get; set; }
public DownloadProtocol Protocol { get; set; }
public int Priority { get; set; }
}
public class IndexerResourceMapper : ProviderResourceMapper<IndexerResource, IndexerDefinition>
@@ -29,6 +30,7 @@ namespace Radarr.Api.V3.Indexers
resource.SupportsRss = definition.SupportsRss;
resource.SupportsSearch = definition.SupportsSearch;
resource.Protocol = definition.Protocol;
resource.Priority = definition.Priority;
return resource;
}
@@ -45,6 +47,7 @@ namespace Radarr.Api.V3.Indexers
definition.EnableRss = resource.EnableRss;
definition.EnableAutomaticSearch = resource.EnableAutomaticSearch;
definition.EnableInteractiveSearch = resource.EnableInteractiveSearch;
definition.Priority = resource.Priority;
return definition;
}