Ejemplo n.º 1
0
        public async Task <bool> Executar(FiltroRelatorioGamesDto filtroRelatorioGamesDto)
        {
            unitOfWork.IniciarTransacao();
            var usuarioLogado = await mediator.Send(new ObterUsuarioLogadoQuery());

            var retorno = await mediator.Send(new GerarRelatorioCommand(TipoRelatorio.RelatorioExemplo, filtroRelatorioGamesDto, usuarioLogado));

            unitOfWork.PersistirTransacao();
            return(retorno);
        }
        public async Task <bool> Executar(FiltroRelatorioGamesDto filtroRelatorioGamesDto)
        {
            var retorno = await mediator.Send(new GerarRelatorioCommand(TipoRelatorio.RelatorioExemplo, filtroRelatorioGamesDto, filtroRelatorioGamesDto.UsuarioRf));

            return(retorno);
        }
 public async Task <IActionResult> ExemploGames([FromBody] FiltroRelatorioGamesDto filtroRelatorioGamesDto, [FromServices] IGamesUseCase gamesUseCase)
 {
     return(Ok(await gamesUseCase.Executar(filtroRelatorioGamesDto)));
 }