コード例 #1
0
 public IActionResult Buyitem(PurchaseHistory obj)
 {
     try
     {
         _repo.Buyitem(obj);
         return(Ok());
     }
     catch (Exception e)
     {
         return(NotFound(e.InnerException.Message));
     }
 }
コード例 #2
0
 public IActionResult Buyitem(PurchaseHistory obj)
 {
     try
     {
         _repo.Buyitem(obj);
         return(Ok());
     }
     catch (Exception ex)
     {
         return(Content(ex.InnerException.Message));
     }
 }