Ejemplo n.º 1
0
 public IEnumerable <Flight> GetByCompanyAndDeparture(string company, string departure, DateTime?beginDate, DateTime?endDate)
 {
     return(_context.Flights
            .Where(FlightQueries.GetByCompany(company))
            .Where(FlightQueries.GetByDeparture(departure))
            .Where(FlightQueries.GetByStdPeriod(beginDate ?? DateTime.Now.AddHours(-6), endDate ?? DateTime.Now.AddHours(6)))
            .AsNoTracking());
 }
Ejemplo n.º 2
0
 public IEnumerable <Flight> GetByCompany(string company, DateTime?beginDate, DateTime?endDate)
 {
     return(_context.Flights.Where(FlightQueries.GetByCompany(company)).Where(FlightQueries.GetByStdPeriod(beginDate ?? DateTime.Now.AddHours(-6), endDate ?? DateTime.Now.AddHours(6))));
 }