Example #1
0
        public Kart Create(Kart kart)
        {
            var kurt = _ctx.Add(kart).Entity;

            _ctx.SaveChanges();
            return(kurt);
        }
        public Product CreateProduct(Product product)
        {
            var prod = _ctx.Add(product).Entity;

            _ctx.SaveChanges();
            return(prod);
        }
        public User CreateUser(User user, Kart kart)
        {
            var users = _ctx.Add(user).Entity;

            users.ShoppingKart = kart;
            _ctx.SaveChanges();
            return(users);
        }