コード例 #1
0
        public async Task <ServiceResult> Get([FromRoute] string clienteId, [FromRoute] string id)
        {
            ServiceResult service = new ServiceResult();

            try
            {
                VentaDTO venta = new VentaDTO();
                venta = await ventaService.BuscarPorCodigoAsync(clienteId, id);

                service.Data = venta;
            }
            catch (Exception ex)
            {
                service.Errors(ex);
                _logger.LogError(ex);
            }
            return(service);
        }