Пример #1
0
 public BusDriver GetBusDriverByDayIdBusColorAndTimeOfDay(int dayId, BusColor busColor, TimeOfDay timeOfDay)
 {
     return(_busDrivers
            .Include(b => b.Day)
            .Include(b => b.Driver)
            .SingleOrDefault(d => d.DayId == dayId && d.BusColor == busColor && d.TimeOfDay == timeOfDay));
 }
 public BusDriver(Day day, Driver driver, TimeOfDay timeOfDay, BusColor busColor)
 {
     Day       = day;
     DayId     = day.DayId;
     Driver    = driver;
     DriverId  = driver.DriverId;
     TimeOfDay = timeOfDay;
     BusColor  = busColor;
 }