public async Task <IHttpActionResult> Delete(int id)
        {
            var pedido = await _serviceBase.GetByIdAsync(id);

            await _serviceBase.DeleteAsync(pedido, id);

            return(Ok());
        }
Example #2
0
        public async Task <IHttpActionResult> DeleteAsync(int id)
        {
            var retPok = await _IPedidoAppService.GetByIdAsync(id);

            if (retPok == null)
            {
                return(NotFound());
            }
            else
            {
                await _IPedidoAppService.DeleteAsync(retPok, id);

                return(Ok());
            }
        }