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

            return(Convert.ToBoolean(result));
        }
Ejemplo 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);
 }
Ejemplo n.º 6
0
 public Guid Save(Models.Domain.OrderItem product)
 {
     _productDatabaseContext.Add(product);
     _productDatabaseContext.SaveChanges();
     return(product.Id);
 }
Ejemplo 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);
 }