public Offer GetOffer(int id) { log.Trace($"Getting offer {id}"); var offer = Offers.FirstOrDefault(e => e.Id == id); return(offer == null?OutgoingOffers.FirstOrDefault(e => e.Id == id) : offer); }
private Offer GetActiveOffer() { log.Trace("Getting active offer"); var offer = Offers.FirstOrDefault(o => o.TradeRequestSent); return(offer == null?OutgoingOffers.FirstOrDefault(o => o.TradeRequestSent) : offer); }
private void OfferDeleted(int vmId) { var foundTicketOfferViewModel = Offers.FirstOrDefault(ticketOfferViewModel => ticketOfferViewModel.VmId == vmId); InvokeOnMainThread(() => Offers.Remove(foundTicketOfferViewModel)); }