Beispiel #1
0
        public async Task <IActionResult> AddBuyer([FromBody] AddBuyerRequestModel auction)
        {
            bool success = await _service.AddBuyer(auction.AuctionId, auction.Buyer);

            if (success)
            {
                await _hubContext.Clients.All.SendAsync("AddBuyer", JsonConvert.SerializeObject(auction));

                return(Ok());
            }

            return(BadRequest());
        }