Ejemplo n.º 1
0
        public IActionResult DeleteCuisine(int cuisineId)
        {
            Cuisine deletedCuisine = cRepository.DeleteCuisine(cuisineId);

            if (deletedCuisine != null)
            {
                TempData["message"] = $"{deletedCuisine.CuisineType} was deleted!";
            }
            return(RedirectToAction(nameof(CuisineIndex)));
        }
 public void DeleteCuisine(Cuisine cuisine)
 {
     _cuisineRepository.DeleteCuisine(cuisine);
 }