public void LoadForecastRaw(ServiceQueue[] serviceQueues, DateTime start, DateTime end, Action <IDailyObject> addTo) { if (serviceQueues.Length == 0) { return; } var x = new ActionableList <IDailyObject>(addTo); Session.CreateQuery( "from ForecastTraffic f where f.Forecast.ServiceQueue in (:serviceQueues) and f.Date >=:start and f.Date <:end") .SetParameterList("serviceQueues", serviceQueues) .SetDateTime("start", start.Date) .SetDateTime("end", end.Date) .SetReadOnly(true) .List(x); Session.CreateQuery( "from ForecastServiceLevelGoal f where f.Forecast.ServiceQueue in (:serviceQueues) and f.Date >=:start and f.Date <:end") .SetParameterList("serviceQueues", serviceQueues) .SetDateTime("start", start.Date) .SetDateTime("end", end.Date) .SetReadOnly(true) .List(x); }
public void LoadActuralRaw(ServiceQueue[] serviceQueues, DateTime start, DateTime end, Action <IDailyObject> addTo) { if (serviceQueues.Length == 0) { return; } var x = new ActionableList <IDailyObject>(addTo); Session.CreateQuery( "from ServiceQueueTraffic f where f.ServiceQueue in (:serviceQueue) and f.TrafficDate >=:start and f.TrafficDate <=:end") .SetParameterList("serviceQueue", serviceQueues) .SetDateTime("start", start.Date) .SetDateTime("end", end.Date) .List(x); }