示例#1
0
        public bool RentClassRooms(List <RequestMatch> requests)
        {
            bool didWork = true;

            foreach (RequestMatch rm in requests)
            {
                TimeSpan ts = new TimeSpan(7, 0, 0, 0);
                bool     t  = dbCtrl.RentClassRoom(rm.ClassroomId, rm.GroupId, DateTime.Now, DateTime.Now.Add(ts));
                if (!t)
                {
                    didWork = false;
                }
            }
            return(didWork);
        }