Add DELETE endpoint to RecActionController for testing

A new HTTP DELETE endpoint has been added to the
`RecActionController` class, accessible via the `"fake"` route.
The `Delete` method is asynchronous and uses the `mediator.Send`
method to execute a `DeleteRecActionsCommand` with a hardcoded
`ProfileId` value of `2`. The method returns an HTTP 204 No
Content response. This endpoint appears to be intended for
testing or placeholder purposes.
This commit is contained in:
tekh 2025-12-03 13:43:39 +01:00
parent 1a0da4140b
commit 6eebd10dc1

View File

@ -71,5 +71,16 @@ public class RecActionController(IMediator mediator) : ControllerBase
return NoContent(); return NoContent();
} }
[HttpDelete("fake")]
public async Task<IActionResult> Delete(CancellationToken cancel)
{
await mediator.Send(new DeleteRecActionsCommand()
{
ProfileId = 2
}, cancel);
return NoContent();
}
#endregion CRUD #endregion CRUD
} }