Пример #1
0
 public virtual void AddProduct(Product product)
 {
     product.StoresStockedIn.Add(this);
     Products.Add(product);
 }
Пример #2
0
 public void CreateForStore(Product product, int storeId)
 {
     var store = _storeRepository.GetById(storeId);
     store.AddProduct(product);
     _storeRepository.Update(store);
 }
Пример #3
0
 public void Update(Product product)
 {
     _productRepository.Update(product);
 }
Пример #4
0
 public void Create(Product product)
 {
     _productRepository.Create(product);
 }