Exemplo n.º 1
0
        public IActionResult Delete(Car car)
        {
            var result = _carManager.Delete(car);

            if (result.Success)
            {
                return(Ok(result.Message));
            }
            return(BadRequest(result.Message));
        }
Exemplo n.º 2
0
 public IActionResult DeleteConfirmed(int carId)
 {
     carManager.Delete(carId);
     return(RedirectToAction("Index", "Car"));
 }