New: Bulk Manage Applications, Download Clients

Co-authored-by: Qstick <qstick@gmail.com>
This commit is contained in:
Bogdan
2023-07-16 19:47:59 +03:00
parent f7c135faaf
commit f436d730fe
123 changed files with 4076 additions and 223 deletions
@@ -0,0 +1,12 @@
using NzbDrone.Core.Extras.Metadata;
namespace Readarr.Api.V1.Metadata
{
public class MetadataBulkResource : ProviderBulkResource<MetadataBulkResource>
{
}
public class MetadataBulkResourceMapper : ProviderBulkResourceMapper<MetadataBulkResource, MetadataDefinition>
{
}
}
@@ -1,16 +1,31 @@
using System;
using Microsoft.AspNetCore.Mvc;
using NzbDrone.Core.Extras.Metadata;
using Readarr.Http;
namespace Readarr.Api.V1.Metadata
{
[V1ApiController]
public class MetadataController : ProviderControllerBase<MetadataResource, IMetadata, MetadataDefinition>
public class MetadataController : ProviderControllerBase<MetadataResource, MetadataBulkResource, IMetadata, MetadataDefinition>
{
public static readonly MetadataResourceMapper ResourceMapper = new MetadataResourceMapper();
public static readonly MetadataResourceMapper ResourceMapper = new ();
public static readonly MetadataBulkResourceMapper BulkResourceMapper = new ();
public MetadataController(IMetadataFactory metadataFactory)
: base(metadataFactory, "metadata", ResourceMapper)
: base(metadataFactory, "metadata", ResourceMapper, BulkResourceMapper)
{
}
[NonAction]
public override ActionResult<MetadataResource> UpdateProvider([FromBody] MetadataBulkResource providerResource)
{
throw new NotImplementedException();
}
[NonAction]
public override object DeleteProviders([FromBody] MetadataBulkResource resource)
{
throw new NotImplementedException();
}
}
}