public IActionResult EditStock(int id) { var stock = _stockManagementService.GetStock(id); var tableModel = GetTableModel(null, stock); var model = tableModel.GetCurrentRow().ToList(); ViewData["Action"] = nameof(EditStock); return(PartialView("TableEditor/_TableEdit", model)); }