Esempio n. 1
0
        public bool Update(Models.Domain.OrderItem model)
        {
            _productDatabaseContext.Update(model);
            int result = _productDatabaseContext.SaveChanges();

            return(Convert.ToBoolean(result));
        }
Esempio n. 2
0
        public bool Delete(Guid id)
        {
            Models.Domain.OrderItem model = this.GetById(id);
            _productDatabaseContext.Remove(model);
            int result = _productDatabaseContext.SaveChanges();

            return(Convert.ToBoolean(result));
        }
 public Models.Domain.OrderItem GetProductId(Guid Id)
 {
     Models.Domain.OrderItem model = _orderItemRepository.GetById(Id);
     return(model);
 }
 public bool Update(Models.Domain.OrderItem model)
 {
     return(_orderItemRepository.Update(model));
 }
 public Guid Save(Models.Domain.OrderItem model)
 {
     _orderItemRepository.Save(model);
     return(model.Id);
 }
Esempio n. 6
0
 public Guid Save(Models.Domain.OrderItem product)
 {
     _productDatabaseContext.Add(product);
     _productDatabaseContext.SaveChanges();
     return(product.Id);
 }
Esempio n. 7
0
 public Models.Domain.OrderItem GetById(Guid id)
 {
     Models.Domain.OrderItem model = _productDatabaseContext.Set <Models.Domain.OrderItem>().Where(p => p.Id == id).FirstOrDefault();
     return(model);
 }