public static function doSelectJoinAllExceptEmployee(Criteria $c, $con = null) { $c = clone $c; if ($c->getDbName() == Propel::getDefaultDB()) { $c->setDbName(self::DATABASE_NAME); } CourseScheduleTutorPeer::addSelectColumns($c); $startcol2 = CourseScheduleTutorPeer::NUM_COLUMNS - CourseScheduleTutorPeer::NUM_LAZY_LOAD_COLUMNS + 1; CourseSchedulePeer::addSelectColumns($c); $startcol3 = $startcol2 + CourseSchedulePeer::NUM_COLUMNS; $c->addJoin(CourseScheduleTutorPeer::COURSE_SCHEDULE_ID, CourseSchedulePeer::ID); $rs = BasePeer::doSelect($c, $con); $results = array(); while ($rs->next()) { $omClass = CourseScheduleTutorPeer::getOMClass(); $cls = Propel::import($omClass); $obj1 = new $cls(); $obj1->hydrate($rs); $omClass = CourseSchedulePeer::getOMClass(); $cls = Propel::import($omClass); $obj2 = new $cls(); $obj2->hydrate($rs, $startcol2); $newObject = true; for ($j = 0, $resCount = count($results); $j < $resCount; $j++) { $temp_obj1 = $results[$j]; $temp_obj2 = $temp_obj1->getCourseSchedule(); if ($temp_obj2->getPrimaryKey() === $obj2->getPrimaryKey()) { $newObject = false; $temp_obj2->addCourseScheduleTutor($obj1); break; } } if ($newObject) { $obj2->initCourseScheduleTutors(); $obj2->addCourseScheduleTutor($obj1); } $results[] = $obj1; } return $results; }
public function getCourseSchedules($criteria = null, $con = null) { include_once 'lib/model/om/BaseCourseSchedulePeer.php'; if ($criteria === null) { $criteria = new Criteria(); } elseif ($criteria instanceof Criteria) { $criteria = clone $criteria; } if ($this->collCourseSchedules === null) { if ($this->isNew()) { $this->collCourseSchedules = array(); } else { $criteria->add(CourseSchedulePeer::EMPLOYEE_ID, $this->getId()); CourseSchedulePeer::addSelectColumns($criteria); $this->collCourseSchedules = CourseSchedulePeer::doSelect($criteria, $con); } } else { if (!$this->isNew()) { $criteria->add(CourseSchedulePeer::EMPLOYEE_ID, $this->getId()); CourseSchedulePeer::addSelectColumns($criteria); if (!isset($this->lastCourseScheduleCriteria) || !$this->lastCourseScheduleCriteria->equals($criteria)) { $this->collCourseSchedules = CourseSchedulePeer::doSelect($criteria, $con); } } } $this->lastCourseScheduleCriteria = $criteria; return $this->collCourseSchedules; }
public static function doSelectJoinAllExceptEmployee(Criteria $c, $con = null) { $c = clone $c; if ($c->getDbName() == Propel::getDefaultDB()) { $c->setDbName(self::DATABASE_NAME); } ClassCounselPeer::addSelectColumns($c); $startcol2 = ClassCounselPeer::NUM_COLUMNS - ClassCounselPeer::NUM_LAZY_LOAD_COLUMNS + 1; CourseSchedulePeer::addSelectColumns($c); $startcol3 = $startcol2 + CourseSchedulePeer::NUM_COLUMNS; StudentPeer::addSelectColumns($c); $startcol4 = $startcol3 + StudentPeer::NUM_COLUMNS; CounselingStatusPeer::addSelectColumns($c); $startcol5 = $startcol4 + CounselingStatusPeer::NUM_COLUMNS; ClassGroupPeer::addSelectColumns($c); $startcol6 = $startcol5 + ClassGroupPeer::NUM_COLUMNS; $c->addJoin(ClassCounselPeer::COURSE_SCHEDULE_ID, CourseSchedulePeer::ID); $c->addJoin(ClassCounselPeer::STUDENT_ID, StudentPeer::ID); $c->addJoin(ClassCounselPeer::COUNSELING_STATUS_ID, CounselingStatusPeer::ID); $c->addJoin(ClassCounselPeer::CLASS_GROUP_ID, ClassGroupPeer::ID); $rs = BasePeer::doSelect($c, $con); $results = array(); while ($rs->next()) { $omClass = ClassCounselPeer::getOMClass(); $cls = Propel::import($omClass); $obj1 = new $cls(); $obj1->hydrate($rs); $omClass = CourseSchedulePeer::getOMClass(); $cls = Propel::import($omClass); $obj2 = new $cls(); $obj2->hydrate($rs, $startcol2); $newObject = true; for ($j = 0, $resCount = count($results); $j < $resCount; $j++) { $temp_obj1 = $results[$j]; $temp_obj2 = $temp_obj1->getCourseSchedule(); if ($temp_obj2->getPrimaryKey() === $obj2->getPrimaryKey()) { $newObject = false; $temp_obj2->addClassCounsel($obj1); break; } } if ($newObject) { $obj2->initClassCounsels(); $obj2->addClassCounsel($obj1); } $omClass = StudentPeer::getOMClass(); $cls = Propel::import($omClass); $obj3 = new $cls(); $obj3->hydrate($rs, $startcol3); $newObject = true; for ($j = 0, $resCount = count($results); $j < $resCount; $j++) { $temp_obj1 = $results[$j]; $temp_obj3 = $temp_obj1->getStudent(); if ($temp_obj3->getPrimaryKey() === $obj3->getPrimaryKey()) { $newObject = false; $temp_obj3->addClassCounsel($obj1); break; } } if ($newObject) { $obj3->initClassCounsels(); $obj3->addClassCounsel($obj1); } $omClass = CounselingStatusPeer::getOMClass(); $cls = Propel::import($omClass); $obj4 = new $cls(); $obj4->hydrate($rs, $startcol4); $newObject = true; for ($j = 0, $resCount = count($results); $j < $resCount; $j++) { $temp_obj1 = $results[$j]; $temp_obj4 = $temp_obj1->getCounselingStatus(); if ($temp_obj4->getPrimaryKey() === $obj4->getPrimaryKey()) { $newObject = false; $temp_obj4->addClassCounsel($obj1); break; } } if ($newObject) { $obj4->initClassCounsels(); $obj4->addClassCounsel($obj1); } $omClass = ClassGroupPeer::getOMClass(); $cls = Propel::import($omClass); $obj5 = new $cls(); $obj5->hydrate($rs, $startcol5); $newObject = true; for ($j = 0, $resCount = count($results); $j < $resCount; $j++) { $temp_obj1 = $results[$j]; $temp_obj5 = $temp_obj1->getClassGroup(); if ($temp_obj5->getPrimaryKey() === $obj5->getPrimaryKey()) { $newObject = false; $temp_obj5->addClassCounsel($obj1); break; } } if ($newObject) { $obj5->initClassCounsels(); $obj5->addClassCounsel($obj1); } $results[] = $obj1; } return $results; }
public static function doSelectJoinAllExceptAcademicCalendar(Criteria $c, $con = null) { $c = clone $c; if ($c->getDbName() == Propel::getDefaultDB()) { $c->setDbName(self::DATABASE_NAME); } VSubjectAgendaPeer::addSelectColumns($c); $startcol2 = VSubjectAgendaPeer::NUM_COLUMNS - VSubjectAgendaPeer::NUM_LAZY_LOAD_COLUMNS + 1; CourseSchedulePeer::addSelectColumns($c); $startcol3 = $startcol2 + CourseSchedulePeer::NUM_COLUMNS; ClassGroupPeer::addSelectColumns($c); $startcol4 = $startcol3 + ClassGroupPeer::NUM_COLUMNS; SubjectCurrPeer::addSelectColumns($c); $startcol5 = $startcol4 + SubjectCurrPeer::NUM_COLUMNS; $c->addJoin(VSubjectAgendaPeer::COURSE_SCHEDULE_ID, CourseSchedulePeer::ID); $c->addJoin(VSubjectAgendaPeer::CLASS_GROUP_ID, ClassGroupPeer::ID); $c->addJoin(VSubjectAgendaPeer::SUBJECT_CURR_ID, SubjectCurrPeer::ID); $rs = BasePeer::doSelect($c, $con); $results = array(); while ($rs->next()) { $omClass = VSubjectAgendaPeer::getOMClass(); $cls = Propel::import($omClass); $obj1 = new $cls(); $obj1->hydrate($rs); $omClass = CourseSchedulePeer::getOMClass(); $cls = Propel::import($omClass); $obj2 = new $cls(); $obj2->hydrate($rs, $startcol2); $newObject = true; for ($j = 0, $resCount = count($results); $j < $resCount; $j++) { $temp_obj1 = $results[$j]; $temp_obj2 = $temp_obj1->getCourseSchedule(); if ($temp_obj2->getPrimaryKey() === $obj2->getPrimaryKey()) { $newObject = false; $temp_obj2->addVSubjectAgenda($obj1); break; } } if ($newObject) { $obj2->initVSubjectAgendas(); $obj2->addVSubjectAgenda($obj1); } $omClass = ClassGroupPeer::getOMClass(); $cls = Propel::import($omClass); $obj3 = new $cls(); $obj3->hydrate($rs, $startcol3); $newObject = true; for ($j = 0, $resCount = count($results); $j < $resCount; $j++) { $temp_obj1 = $results[$j]; $temp_obj3 = $temp_obj1->getClassGroup(); if ($temp_obj3->getPrimaryKey() === $obj3->getPrimaryKey()) { $newObject = false; $temp_obj3->addVSubjectAgenda($obj1); break; } } if ($newObject) { $obj3->initVSubjectAgendas(); $obj3->addVSubjectAgenda($obj1); } $omClass = SubjectCurrPeer::getOMClass(); $cls = Propel::import($omClass); $obj4 = new $cls(); $obj4->hydrate($rs, $startcol4); $newObject = true; for ($j = 0, $resCount = count($results); $j < $resCount; $j++) { $temp_obj1 = $results[$j]; $temp_obj4 = $temp_obj1->getSubjectCurr(); if ($temp_obj4->getPrimaryKey() === $obj4->getPrimaryKey()) { $newObject = false; $temp_obj4->addVSubjectAgenda($obj1); break; } } if ($newObject) { $obj4->initVSubjectAgendas(); $obj4->addVSubjectAgenda($obj1); } $results[] = $obj1; } return $results; }
public static function doSelectJoinAllExceptAcademicCalendar(Criteria $c, $con = null) { $c = clone $c; if ($c->getDbName() == Propel::getDefaultDB()) { $c->setDbName(self::DATABASE_NAME); } VCourseSessionPeer::addSelectColumns($c); $startcol2 = VCourseSessionPeer::NUM_COLUMNS - VCourseSessionPeer::NUM_LAZY_LOAD_COLUMNS + 1; SubjectAccalPeer::addSelectColumns($c); $startcol3 = $startcol2 + SubjectAccalPeer::NUM_COLUMNS; SubjectCurrPeer::addSelectColumns($c); $startcol4 = $startcol3 + SubjectCurrPeer::NUM_COLUMNS; EmployeePeer::addSelectColumns($c); $startcol5 = $startcol4 + EmployeePeer::NUM_COLUMNS; ClassGroupPeer::addSelectColumns($c); $startcol6 = $startcol5 + ClassGroupPeer::NUM_COLUMNS; LocationPeer::addSelectColumns($c); $startcol7 = $startcol6 + LocationPeer::NUM_COLUMNS; ClassSessionPeer::addSelectColumns($c); $startcol8 = $startcol7 + ClassSessionPeer::NUM_COLUMNS; CourseSchedulePeer::addSelectColumns($c); $startcol9 = $startcol8 + CourseSchedulePeer::NUM_COLUMNS; $c->addJoin(VCourseSessionPeer::SUBJECT_ACCAL_ID, SubjectAccalPeer::ID); $c->addJoin(VCourseSessionPeer::SUBJECT_CURR_ID, SubjectCurrPeer::ID); $c->addJoin(VCourseSessionPeer::EMPLOYEE_ID, EmployeePeer::ID); $c->addJoin(VCourseSessionPeer::CLASS_GROUP_ID, ClassGroupPeer::ID); $c->addJoin(VCourseSessionPeer::LOCATION_ID, LocationPeer::ID); $c->addJoin(VCourseSessionPeer::CLASS_SESSION_ID, ClassSessionPeer::ID); $c->addJoin(VCourseSessionPeer::COURSE_SCHEDULE_ID, CourseSchedulePeer::ID); $rs = BasePeer::doSelect($c, $con); $results = array(); while ($rs->next()) { $omClass = VCourseSessionPeer::getOMClass(); $cls = Propel::import($omClass); $obj1 = new $cls(); $obj1->hydrate($rs); $omClass = SubjectAccalPeer::getOMClass(); $cls = Propel::import($omClass); $obj2 = new $cls(); $obj2->hydrate($rs, $startcol2); $newObject = true; for ($j = 0, $resCount = count($results); $j < $resCount; $j++) { $temp_obj1 = $results[$j]; $temp_obj2 = $temp_obj1->getSubjectAccal(); if ($temp_obj2->getPrimaryKey() === $obj2->getPrimaryKey()) { $newObject = false; $temp_obj2->addVCourseSession($obj1); break; } } if ($newObject) { $obj2->initVCourseSessions(); $obj2->addVCourseSession($obj1); } $omClass = SubjectCurrPeer::getOMClass(); $cls = Propel::import($omClass); $obj3 = new $cls(); $obj3->hydrate($rs, $startcol3); $newObject = true; for ($j = 0, $resCount = count($results); $j < $resCount; $j++) { $temp_obj1 = $results[$j]; $temp_obj3 = $temp_obj1->getSubjectCurr(); if ($temp_obj3->getPrimaryKey() === $obj3->getPrimaryKey()) { $newObject = false; $temp_obj3->addVCourseSession($obj1); break; } } if ($newObject) { $obj3->initVCourseSessions(); $obj3->addVCourseSession($obj1); } $omClass = EmployeePeer::getOMClass(); $cls = Propel::import($omClass); $obj4 = new $cls(); $obj4->hydrate($rs, $startcol4); $newObject = true; for ($j = 0, $resCount = count($results); $j < $resCount; $j++) { $temp_obj1 = $results[$j]; $temp_obj4 = $temp_obj1->getEmployee(); if ($temp_obj4->getPrimaryKey() === $obj4->getPrimaryKey()) { $newObject = false; $temp_obj4->addVCourseSession($obj1); break; } } if ($newObject) { $obj4->initVCourseSessions(); $obj4->addVCourseSession($obj1); } $omClass = ClassGroupPeer::getOMClass(); $cls = Propel::import($omClass); $obj5 = new $cls(); $obj5->hydrate($rs, $startcol5); $newObject = true; for ($j = 0, $resCount = count($results); $j < $resCount; $j++) { $temp_obj1 = $results[$j]; $temp_obj5 = $temp_obj1->getClassGroup(); if ($temp_obj5->getPrimaryKey() === $obj5->getPrimaryKey()) { $newObject = false; $temp_obj5->addVCourseSession($obj1); break; } } if ($newObject) { $obj5->initVCourseSessions(); $obj5->addVCourseSession($obj1); } $omClass = LocationPeer::getOMClass(); $cls = Propel::import($omClass); $obj6 = new $cls(); $obj6->hydrate($rs, $startcol6); $newObject = true; for ($j = 0, $resCount = count($results); $j < $resCount; $j++) { $temp_obj1 = $results[$j]; $temp_obj6 = $temp_obj1->getLocation(); if ($temp_obj6->getPrimaryKey() === $obj6->getPrimaryKey()) { $newObject = false; $temp_obj6->addVCourseSession($obj1); break; } } if ($newObject) { $obj6->initVCourseSessions(); $obj6->addVCourseSession($obj1); } $omClass = ClassSessionPeer::getOMClass(); $cls = Propel::import($omClass); $obj7 = new $cls(); $obj7->hydrate($rs, $startcol7); $newObject = true; for ($j = 0, $resCount = count($results); $j < $resCount; $j++) { $temp_obj1 = $results[$j]; $temp_obj7 = $temp_obj1->getClassSession(); if ($temp_obj7->getPrimaryKey() === $obj7->getPrimaryKey()) { $newObject = false; $temp_obj7->addVCourseSession($obj1); break; } } if ($newObject) { $obj7->initVCourseSessions(); $obj7->addVCourseSession($obj1); } $omClass = CourseSchedulePeer::getOMClass(); $cls = Propel::import($omClass); $obj8 = new $cls(); $obj8->hydrate($rs, $startcol8); $newObject = true; for ($j = 0, $resCount = count($results); $j < $resCount; $j++) { $temp_obj1 = $results[$j]; $temp_obj8 = $temp_obj1->getCourseSchedule(); if ($temp_obj8->getPrimaryKey() === $obj8->getPrimaryKey()) { $newObject = false; $temp_obj8->addVCourseSession($obj1); break; } } if ($newObject) { $obj8->initVCourseSessions(); $obj8->addVCourseSession($obj1); } $results[] = $obj1; } return $results; }
public static function doSelectJoinAllExceptEmployee(Criteria $c, $con = null) { $c = clone $c; if ($c->getDbName() == Propel::getDefaultDB()) { $c->setDbName(self::DATABASE_NAME); } ClassAgendaPeer::addSelectColumns($c); $startcol2 = ClassAgendaPeer::NUM_COLUMNS - ClassAgendaPeer::NUM_LAZY_LOAD_COLUMNS + 1; CourseSchedulePeer::addSelectColumns($c); $startcol3 = $startcol2 + CourseSchedulePeer::NUM_COLUMNS; ClassSessionPeer::addSelectColumns($c); $startcol4 = $startcol3 + ClassSessionPeer::NUM_COLUMNS; SubjectGradingPeer::addSelectColumns($c); $startcol5 = $startcol4 + SubjectGradingPeer::NUM_COLUMNS; StudentPeer::addSelectColumns($c); $startcol6 = $startcol5 + StudentPeer::NUM_COLUMNS; StudentAbsencePeer::addSelectColumns($c); $startcol7 = $startcol6 + StudentAbsencePeer::NUM_COLUMNS; ClassGroupPeer::addSelectColumns($c); $startcol8 = $startcol7 + ClassGroupPeer::NUM_COLUMNS; SchedulePeer::addSelectColumns($c); $startcol9 = $startcol8 + SchedulePeer::NUM_COLUMNS; $c->addJoin(ClassAgendaPeer::COURSE_SCHEDULE_ID, CourseSchedulePeer::ID); $c->addJoin(ClassAgendaPeer::CLASS_SESSION_ID, ClassSessionPeer::ID); $c->addJoin(ClassAgendaPeer::SUBJECT_GRADING_ID, SubjectGradingPeer::ID); $c->addJoin(ClassAgendaPeer::STUDENT_ID, StudentPeer::ID); $c->addJoin(ClassAgendaPeer::STUDENT_ABSENCE_ID, StudentAbsencePeer::ID); $c->addJoin(ClassAgendaPeer::CLASS_GROUP_ID, ClassGroupPeer::ID); $c->addJoin(ClassAgendaPeer::SCHEDULE_ID, SchedulePeer::ID); $rs = BasePeer::doSelect($c, $con); $results = array(); while ($rs->next()) { $omClass = ClassAgendaPeer::getOMClass(); $cls = Propel::import($omClass); $obj1 = new $cls(); $obj1->hydrate($rs); $omClass = CourseSchedulePeer::getOMClass(); $cls = Propel::import($omClass); $obj2 = new $cls(); $obj2->hydrate($rs, $startcol2); $newObject = true; for ($j = 0, $resCount = count($results); $j < $resCount; $j++) { $temp_obj1 = $results[$j]; $temp_obj2 = $temp_obj1->getCourseSchedule(); if ($temp_obj2->getPrimaryKey() === $obj2->getPrimaryKey()) { $newObject = false; $temp_obj2->addClassAgenda($obj1); break; } } if ($newObject) { $obj2->initClassAgendas(); $obj2->addClassAgenda($obj1); } $omClass = ClassSessionPeer::getOMClass(); $cls = Propel::import($omClass); $obj3 = new $cls(); $obj3->hydrate($rs, $startcol3); $newObject = true; for ($j = 0, $resCount = count($results); $j < $resCount; $j++) { $temp_obj1 = $results[$j]; $temp_obj3 = $temp_obj1->getClassSession(); if ($temp_obj3->getPrimaryKey() === $obj3->getPrimaryKey()) { $newObject = false; $temp_obj3->addClassAgenda($obj1); break; } } if ($newObject) { $obj3->initClassAgendas(); $obj3->addClassAgenda($obj1); } $omClass = SubjectGradingPeer::getOMClass(); $cls = Propel::import($omClass); $obj4 = new $cls(); $obj4->hydrate($rs, $startcol4); $newObject = true; for ($j = 0, $resCount = count($results); $j < $resCount; $j++) { $temp_obj1 = $results[$j]; $temp_obj4 = $temp_obj1->getSubjectGrading(); if ($temp_obj4->getPrimaryKey() === $obj4->getPrimaryKey()) { $newObject = false; $temp_obj4->addClassAgenda($obj1); break; } } if ($newObject) { $obj4->initClassAgendas(); $obj4->addClassAgenda($obj1); } $omClass = StudentPeer::getOMClass(); $cls = Propel::import($omClass); $obj5 = new $cls(); $obj5->hydrate($rs, $startcol5); $newObject = true; for ($j = 0, $resCount = count($results); $j < $resCount; $j++) { $temp_obj1 = $results[$j]; $temp_obj5 = $temp_obj1->getStudent(); if ($temp_obj5->getPrimaryKey() === $obj5->getPrimaryKey()) { $newObject = false; $temp_obj5->addClassAgenda($obj1); break; } } if ($newObject) { $obj5->initClassAgendas(); $obj5->addClassAgenda($obj1); } $omClass = StudentAbsencePeer::getOMClass(); $cls = Propel::import($omClass); $obj6 = new $cls(); $obj6->hydrate($rs, $startcol6); $newObject = true; for ($j = 0, $resCount = count($results); $j < $resCount; $j++) { $temp_obj1 = $results[$j]; $temp_obj6 = $temp_obj1->getStudentAbsence(); if ($temp_obj6->getPrimaryKey() === $obj6->getPrimaryKey()) { $newObject = false; $temp_obj6->addClassAgenda($obj1); break; } } if ($newObject) { $obj6->initClassAgendas(); $obj6->addClassAgenda($obj1); } $omClass = ClassGroupPeer::getOMClass(); $cls = Propel::import($omClass); $obj7 = new $cls(); $obj7->hydrate($rs, $startcol7); $newObject = true; for ($j = 0, $resCount = count($results); $j < $resCount; $j++) { $temp_obj1 = $results[$j]; $temp_obj7 = $temp_obj1->getClassGroup(); if ($temp_obj7->getPrimaryKey() === $obj7->getPrimaryKey()) { $newObject = false; $temp_obj7->addClassAgenda($obj1); break; } } if ($newObject) { $obj7->initClassAgendas(); $obj7->addClassAgenda($obj1); } $omClass = SchedulePeer::getOMClass(); $cls = Propel::import($omClass); $obj8 = new $cls(); $obj8->hydrate($rs, $startcol8); $newObject = true; for ($j = 0, $resCount = count($results); $j < $resCount; $j++) { $temp_obj1 = $results[$j]; $temp_obj8 = $temp_obj1->getSchedule(); if ($temp_obj8->getPrimaryKey() === $obj8->getPrimaryKey()) { $newObject = false; $temp_obj8->addClassAgenda($obj1); break; } } if ($newObject) { $obj8->initClassAgendas(); $obj8->addClassAgenda($obj1); } $results[] = $obj1; } return $results; }