public ActionResult CreateToolTransaction(ToolsTransaction toolTransaction) { if (this.ModelState.IsValid) { toolTransaction = transactionService.CreateToolTransaction(toolTransaction); return(RedirectToAction("Details", new { stockId = toolTransaction.StockId })); } ViewBag.TransactionTypes = new SelectList(transactionService.GetTransactionTypeList(), "TransactionTypeId", "Description"); ViewBag.Tools = new SelectList(toolsService.GetTools(), "ToolsId", "Name"); return(View("ToolTransactionForm", toolTransaction)); }
public IActionResult Index() { var toolss = toolsService.GetTools(); return(View(toolss)); }