Example #1
0
 // GET: Items/Create
 public async Task <IActionResult> Create()
 {
     ViewData["CategoryId"] = new SelectList(await categoryService.Get(), "CategoryId", "Name");
     ViewBag.SizeId         = new SelectList(await parameterService.GetSizes(), "SizeId", "Size");
     ViewBag.ColorId        = new SelectList(await parameterService.GetColors(), "ColorId", "Color");
     ViewBag.SizeIdCopy     = ViewBag.SizeId;
     ViewBag.ColorIdCopy    = ViewBag.ColorId;
     return(View());
 }
Example #2
0
 public async Task <IActionResult> Create()
 {
     ViewData["ColorId"] = new SelectList(await parameterService.GetColors(), "ColorId", "Color");
     ViewData["SizeId"]  = new SelectList(await parameterService.GetSizes(), "SizeId", "Size");
     return(View());
 }