Ejemplo n.º 1
0
        public async Task <PadraoResponse <Teste> > PostTeste(Teste model)
        {
            PadraoResponse <Teste> response = new PadraoResponse <Teste>();

            model.Id = Guid.NewGuid();
            model.NovoRegistro();
            await _unitOfWork.TesteRepository.Inserir(model);

            await _unitOfWork.CommitAsync();

            _testeServiceBus.PublishTeste(model);

            response.Data = model;
            return(response);
        }