mirror of
https://github.com/Prowlarr/Prowlarr.git
synced 2026-04-22 22:34:53 -04:00
21 lines
865 B
C#
21 lines
865 B
C#
using FluentValidation;
|
|
using NzbDrone.Core.Download;
|
|
using NzbDrone.SignalR;
|
|
using Prowlarr.Http;
|
|
|
|
namespace Prowlarr.Api.V1.DownloadClient
|
|
{
|
|
[V1ApiController]
|
|
public class DownloadClientController : ProviderControllerBase<DownloadClientResource, DownloadClientBulkResource, IDownloadClient, DownloadClientDefinition>
|
|
{
|
|
public static readonly DownloadClientResourceMapper ResourceMapper = new ();
|
|
public static readonly DownloadClientBulkResourceMapper BulkResourceMapper = new ();
|
|
|
|
public DownloadClientController(IBroadcastSignalRMessage signalRBroadcaster, IDownloadClientFactory downloadClientFactory)
|
|
: base(signalRBroadcaster, downloadClientFactory, "downloadclient", ResourceMapper, BulkResourceMapper)
|
|
{
|
|
SharedValidator.RuleFor(c => c.Priority).InclusiveBetween(1, 50);
|
|
}
|
|
}
|
|
}
|