public async Task <IActionResult> Add(AddPurchaseDto purchaseDto) { var result = await purchaseService.BuyBook(purchaseDto, new CancellationToken()); if (result.Status == ActionStatus.Failure) { return(BadRequest()); } return(Ok(result.Purchase)); }
public async Task <IActionResult> Add(AddPurchaseDto purchaseDto) { var result = await purchaseService.BuyBook(purchaseDto, new CancellationToken()); if (result.Status == ActionStatus.Failure) { return(BadRequest()); } return(Ok(result.Purchase)); }