From 9191ec4179e53e809c0d540616801622b5d92d5c Mon Sep 17 00:00:00 2001 From: TekH Date: Mon, 12 Jan 2026 10:52:41 +0100 Subject: [PATCH] Update [Obsolete] messages to mention procedures or views Updated [Obsolete] attribute messages across several commands, handlers, and the mapping profile to clarify that related procedures or views should be used instead. Added [Obsolete] to CreateOutResCommand. No functional changes made. --- .../OutResults/Commands/CreateOutResCommand.cs | 1 + src/ReC.Application/RecActionViews/MappingProfile.cs | 2 +- .../RecActions/Commands/CreateRecActionCommand.cs | 4 ++-- .../RecActions/Commands/DeleteRecActionsCommand.cs | 4 ++-- 4 files changed, 6 insertions(+), 5 deletions(-) diff --git a/src/ReC.Application/OutResults/Commands/CreateOutResCommand.cs b/src/ReC.Application/OutResults/Commands/CreateOutResCommand.cs index 73de95e..98480a3 100644 --- a/src/ReC.Application/OutResults/Commands/CreateOutResCommand.cs +++ b/src/ReC.Application/OutResults/Commands/CreateOutResCommand.cs @@ -4,6 +4,7 @@ using ReC.Domain.Entities; namespace ReC.Application.OutResults.Commands; +[Obsolete("Use the related procedure or view.")] public class CreateOutResCommand : IRequest { public required long ActionId { get; set; } diff --git a/src/ReC.Application/RecActionViews/MappingProfile.cs b/src/ReC.Application/RecActionViews/MappingProfile.cs index fc095d6..7ebf781 100644 --- a/src/ReC.Application/RecActionViews/MappingProfile.cs +++ b/src/ReC.Application/RecActionViews/MappingProfile.cs @@ -6,7 +6,7 @@ namespace ReC.Application.RecActionViews; // TODO: update to inject AddedWho from the current host/user contex public class MappingProfile : AutoMapper.Profile { - [Obsolete("Use the related procedure.")] + [Obsolete("Use the related procedure or view.")] public MappingProfile() { CreateMap() diff --git a/src/ReC.Application/RecActions/Commands/CreateRecActionCommand.cs b/src/ReC.Application/RecActions/Commands/CreateRecActionCommand.cs index 151ecf3..603fbe1 100644 --- a/src/ReC.Application/RecActions/Commands/CreateRecActionCommand.cs +++ b/src/ReC.Application/RecActions/Commands/CreateRecActionCommand.cs @@ -6,7 +6,7 @@ using ReC.Application.Endpoints.Commands; namespace ReC.Application.RecActions.Commands; -[Obsolete("Use the related procedure.")] +[Obsolete("Use the related procedure or view.")] public record CreateRecActionCommand : IRequest { public long ProfileId { get; init; } @@ -28,7 +28,7 @@ public record CreateRecActionCommand : IRequest public long? EndpointAuthId { get; set; } } -[Obsolete("Use the related procedure.")] +[Obsolete("Use the related procedure or view.")] public class CreateRecActionCommandHandler(ISender sender, IRepository repo) : IRequestHandler { public async Task Handle(CreateRecActionCommand request, CancellationToken cancel) diff --git a/src/ReC.Application/RecActions/Commands/DeleteRecActionsCommand.cs b/src/ReC.Application/RecActions/Commands/DeleteRecActionsCommand.cs index 11f86cd..55c1c39 100644 --- a/src/ReC.Application/RecActions/Commands/DeleteRecActionsCommand.cs +++ b/src/ReC.Application/RecActions/Commands/DeleteRecActionsCommand.cs @@ -6,13 +6,13 @@ using ReC.Domain.Entities; namespace ReC.Application.RecActions.Commands; -[Obsolete("Use the related procedure.")] +[Obsolete("Use the related procedure or view.")] public class DeleteRecActionsCommand : IRequest { public required long ProfileId { get; init; } } -[Obsolete("Use the related procedure.")] +[Obsolete("Use the related procedure or view.")] public class DeleteRecActionsCommandHandler(IRepository repo) : IRequestHandler { public async Task Handle(DeleteRecActionsCommand request, CancellationToken cancel)