public ActionResult SelectInventory(string countGroup, string itemNumber, string warehouseLoc, string batchLot) { var inventoryItems = InventoryDataService.GetInventoryRecordsByGroupId(countGroup); ViewBag.iD = countGroup; return(View("Inventory", new InventoryViewModel() { Records = inventoryItems, SelectedRecord = InventoryDataService.SelectInventory(countGroup, itemNumber, warehouseLoc, batchLot).First() })); }
public ActionResult UpdateInventory(string itno, string bdentry, string seentry, string stkentry, string ctgp, string blno, string whlc) { var inventoryItems = InventoryDataService.UpdateInventory(itno, bdentry, seentry, stkentry, ctgp, blno, whlc); var inventoryItems2 = InventoryDataService.GetInventoryRecordsByGroupId(ctgp); if (inventoryItems.Count == 1) { return(RedirectToAction("Index", "Group")); } return(View("Inventory", new InventoryViewModel() { Records = inventoryItems2, SelectedRecord = InventoryDataService.SelectInventory(ctgp, itno, whlc, blno).First() })); }