Beispiel #1
0
        public ActionResult <Appointment> PostUser(Appointment user)
        {
            service.Add(user);
            service.SaveChanges();

            return(CreatedAtAction("GetUser", new { id = user.Id }, user));
        }
        public bool Add(UserProductInput userProductInput)
        {
            var userProduct = new UserProduct
            {
                UserId    = userProductInput.UserId,
                ProductId = userProductInput.ProductId
            };

            return(_userProductService.Add(userProduct));
        }