Beispiel #1
0
 public ActionResult <IEnumerable <Item> > GetItemsByCategoryId(int id)
 {
     try
     {
         string userId = HttpContext.User.FindFirst(ClaimTypes.NameIdentifier).Value;
         return(Ok(_ls.GetItemsByCategoryId(id, userId)));
     }
     catch (Exception e)
     {
         return(BadRequest(e.Message));
     }
 }