public Auction AddAuction(Auction newAuction) { _context.Auctions.Add(newAuction); _context.SaveChanges(); return(newAuction); }
public Bid GetHighBid(Auction a2b) { Bid hiBid = _context.Bids.Where(x => x.Auctionid == a2b.Id).OrderByDescending(y => y.Amount).FirstOrDefault(); return(hiBid); }