public ActionResult <InventoryModel> GetInventoryById(int id)
 {
     try
     {
         var inventory = _inventoryRepo.GetInventoryById(id);
         if (inventory is null)
         {
             return(NotFound());
         }
         return(Ok(inventory));
     } catch (Exception e)
     {
         return(NotFound(e.Message));
     }
 }
Ejemplo n.º 2
0
 public Inventory GetInventoryById(int id)
 {
     return(repo.GetInventoryById(id));
 }