public bool Delete(int id)
        {
            var userProduct = new UserProduct {
                Id = id
            };

            return(_userProductService.Delete(userProduct));
        }
Exemple #2
0
        public ActionResult <Appointment> DeleteUser(int id)
        {
            var userProduct = service.Get(id);

            if (userProduct == null)
            {
                return(NotFound());
            }

            service.Delete(userProduct);
            service.SaveChanges();

            return(userProduct);
        }