Mark CreateResultViewCommand as obsolete, add handler

CreateResultViewCommand is now marked obsolete, advising use of related procedures or views instead. Added an obsolete CreateResultViewCommandHandler that delegates creation to the repository.
This commit is contained in:
2026-01-14 14:36:30 +01:00
parent 16f48f125b
commit cf34a54170

View File

@@ -6,6 +6,7 @@ using System.Text.Json.Serialization;
namespace ReC.Application.OutResults.Commands;
[Obsolete("Use the related procedure or view.")]
public class CreateResultViewCommand : IAuthScoped, IRequest
{
public required long ActionId { get; set; }
@@ -20,6 +21,7 @@ public class CreateResultViewCommand : IAuthScoped, IRequest
public AuthScope Scope { get; } = new();
}
[Obsolete("Use the related procedure or view.")]
public class CreateResultViewCommandHandler(IRepository<ResultView> repo) : IRequestHandler<CreateResultViewCommand>
{
public Task Handle(CreateResultViewCommand request, CancellationToken cancel) => repo.CreateAsync(request, cancel);