public ActionResult <Inventory> UpdateInventory(string id, Inventory inv) { var inventory = _repo.UpdateInventory(id, inv); if (inv.Id != id) { return(NotFound()); } return(inventory); }
public ActionResult <InventoryModel> UpdateInventory(int id, InventoryModel model) { try { _inventoryRepo.UpdateInventory(id, model); _inventoryRepo.SaveChanges(); return(NoContent()); } catch (Exception e) { return(NotFound(e.Message)); } }
public void UpdateInventory(Inventory inventory) { inventRepo.UpdateInventory(inventory); }
public bool UpdateInventory() { return(_inventoryRepo.UpdateInventory()); }