Rename *ActionProcedure classes to *ActionCommand

Renamed InsertActionProcedure, UpdateActionProcedure, and DeleteActionProcedure to their respective *ActionCommand counterparts to align with CQRS conventions. Updated all controller actions, handlers, tests, and related usages accordingly. No changes to business logic or method signatures.
This commit is contained in:
2026-03-24 11:39:55 +01:00
parent de503cac5b
commit cac33c46df
6 changed files with 16 additions and 16 deletions

View File

@@ -0,0 +1,34 @@
using MediatR;
using ReC.Application.Common.Procedures.InsertProcedure;
using ReC.Domain.Constants;
namespace ReC.Application.RecActions.Commands;
public record InsertActionCommand : IInsertProcedure
{
public long? ProfileId { get; set; }
public bool? Active { get; set; }
public byte? Sequence { get; set; }
public long? EndpointId { get; set; }
public long? EndpointAuthId { get; set; }
public short? EndpointParamsId { get; set; }
public short? SqlConnectionId { get; set; }
public RestType? TypeId { get; set; }
public string? PreSql { get; set; }
public string? HeaderSql { get; set; }
public string? BodySql { get; set; }
public string? PostSql { get; set; }
public byte? ErrorActionId { get; set; }
}
public class InsertActionProcedureHandler(ISender sender) : IRequestHandler<InsertActionCommand, long>
{
public async Task<long> Handle(InsertActionCommand request, CancellationToken cancel)
{
return await sender.Send(new InsertObjectProcedure
{
Entity = "ACTION",
Action = request
}, cancel);
}
}