示例#1
0
        public async Task <IActionResult> Withdraw(
            [FromServices] IWithdrawMoneyUseCase useCase,
            [FromRoute][Required] Guid accountId,
            [FromBody][Required] WithdrawRequest request)
        {
            useCase.SetOutputPort(this);

            await useCase.ExecuteAsync(accountId, request.Amount, request.Currency);

            return(_viewModel !);
        }
示例#2
0
 public WithdrawMoneyValidationUseCase(IWithdrawMoneyUseCase useCase)
 {
     _useCase = useCase;
 }