Esempio n. 1
0
 private void FillManufacturers(GoodsItem goodsItem)
 {
     if (goodsItem.ManufacturerId.HasValue)
     {
         goodsItem.Manufacturer = _shopManufacturerService.GetManufacturer(goodsItem.ManufacturerId.Value);
     }
     if (goodsItem.SupplierId.HasValue)
     {
         goodsItem.Supplier = _shopManufacturerService.GetManufacturer(goodsItem.SupplierId.Value);
     }
 }
Esempio n. 2
0
        private void FillManufaturers(Action action)
        {
            var manIds  = _actionManufacturerGateway.SelectByAction(action.HeartId).Select(x => x.ManufacturerId);
            var mans    = manIds.Select(x => _shopManufacturerService.GetManufacturer(x));
            var idNames = mans.Select(x => new IdNamePair <int>(x.HeartId, x.Name)).ToList();

            action.Manufacturers = idNames;
        }
Esempio n. 3
0
 public Manufacturer Get(int manufacturerId)
 {
     return(_shopManufacturerService.GetManufacturer(manufacturerId));
 }
Esempio n. 4
0
        public ActionResult Manufacturer(int id)
        {
            Manufacturer man = _shopManufacturerService.GetManufacturer(id);

            return(View(man));
        }