public Seat GetSeatBySaloonAndSeatIndex(Saloon saloon, int index) { foreach (var seat in saloon.Seats) { if (seat.Index() == index) { return(seat); } } return(null); }
public List <Seat> GetSeatsInSaloon(Saloon saloon) { return(context.Seats.Where(s => s.Saloon.SaloonId == saloon.SaloonId).ToList()); }