// GET: OuterMemoryFormFactor public ActionResult Index() { var motherBoardFormFactors = _motherBoardFormFactorService.GetOuterMemoryFormFactors().OrderBy(m => m.Name); var model = motherBoardFormFactors.Select(m => new OuterMemoryFormFactorViewModel { Id = m.Id, Name = m.Name }); return(View(model)); }
// GET: PCCase/Create public ActionResult Create() { var motherBoardFormFactorService = _motherBoardFormFactorService.GetMotherBoardFormFactors(); ViewBag.MotherBoardFormFactors = new SelectList(motherBoardFormFactorService, "Id", "Name"); var outerMemoryFormFactors = _outerMemoryFormFactorService.GetOuterMemoryFormFactors(); ViewBag.OuterMemoryFormFactors = new SelectList(outerMemoryFormFactors, "Id", "Name"); var manufacturers = _manufacturerService.GetManufacturers(); ViewBag.Manufacturers = new SelectList(manufacturers, "Id", "Name"); return(View()); }