Esempio n. 1
0
 public async Task <CartBookResponse> AddBookIntoCart(int userID, CartRequest cart)
 {
     try
     {
         if (userID <= 0 || cart.BookID == 0)
         {
             return(null);
         }
         else
         {
             return(await _cartRepository.AddBookIntoCart(userID, cart));
         }
     }
     catch (Exception ex)
     {
         throw new Exception(ex.Message);
     }
 }