Ejemplo n.º 1
0
 public static function doSelectByDepartmentFromTestAppl()
 {
     $ta_id = sfContext::getInstance()->getRequest()->getParameter('test_applicant_id');
     $ta = TestApplicantPeer::retrieveByPK($ta_id);
     if ($ta == null) {
         return array();
     }
     $subject_transfers = $ta->getSubjectTransfers();
     $subject_ids = array();
     foreach ($subject_transfers as $st) {
         $subject_ids[] = $st->getSubjectId();
     }
     $dept1 = array();
     $dept2 = array();
     if ($ta->getDepartmentRelatedByDepartment1()) {
         $dept1 = $ta->getDepartmentRelatedByDepartment1()->getIdRecurs();
         $dept1 = explode(",", $dept1);
     }
     if ($ta->getDepartmentRelatedByDepartment2()) {
         $dept2 = $ta->getDepartmentRelatedByDepartment2()->getIdRecurs();
         $dept2 = explode(",", $dept2);
     }
     $depts = array_merge($dept1, array_diff($dept2, $dept1));
     $c = new Criteria();
     $c->add(SubjectPeer::DEPARTMENT_ID, $depts, Criteria::IN);
     $c->add(SubjectPeer::ID, $subject_ids, Criteria::NOT_IN);
     return SubjectPeer::doSelect($c);
 }
Ejemplo n.º 2
0
 public function getTestApplicant()
 {
     $c = new Criteria();
     $c->add(TestApplicantPeer::ID, $this->getPayer());
     $ta = TestApplicantPeer::doSelectOne($c);
     return $ta;
 }
Ejemplo n.º 3
0
 public function executeDoLogin()
 {
     if ($this->hasRequestParameter('login_user') && $this->hasRequestParameter('login_password')) {
         // check if the user exists
         $c = new Criteria();
         $c->add(TestApplicantPeer::CODE, $this->getRequestParameter('login_user'));
         $user = TestApplicantPeer::doSelectOne($c);
         if ($user) {
             // check if the password is correct
             $password = $this->getRequestParameter('login_password');
             $crypted = sha1(sfConfig::get('app_salt') . $password);
             if ($crypted == $user->getPassword()) {
                 // sign in
                 $this->getContext()->getUser()->signInApplicant($user);
                 // proceed to home page
                 $this->setTemplate('index');
                 return;
             }
         }
         // an error was found
         $this->getRequest()->setError('login_error_title', 'Login failed');
         $this->getRequest()->setError('login_error_msg', 'Your username or password are not correct. Please try again.');
         $this->getRequest()->setParameter('login_submit', null);
         return $this->forward('default', 'login');
     } else {
         $this->forward('default', 'login');
     }
 }
Ejemplo n.º 4
0
 public static function doSelectOrdered(Criteria $criteria, $con = null)
 {
     #$dept = sfContext::getInstance()->getUser()->getAttribute('department',null, 'bo');
     #$depts = $dept->getChildRecurs(array());
     $criteria->add(TestApplicantPeer::STATUS, 3, Criteria::NOT_IN);
     $criteria->addAscendingOrderByColumn(TestApplicantPeer::CODE);
     //		$criteria->add(TestApplicantPeer::ENROLLED, 0);
     return TestApplicantPeer::doSelect($criteria);
 }
Ejemplo n.º 5
0
 public function executeView()
 {
     $user_id = $this->getContext()->getUser()->getAttribute('user_id', null, 'bo');
     $test_applicant = TestApplicantPeer::retrieveByPk($user_id);
     $c = new Criteria();
     $c->add(TestApplSchedPeer::TEST_APPLICANT_ID, $test_applicant->getId());
     $c->add(AcademicCalendarPeer::DEPARTMENT_ID, $test_applicant->getDepartment1());
     $c->addJoin(AcademicCalendarPeer::ID, RegPeriodPeer::ACADEMIC_CALENDAR_ID);
     $c->addJoin(RegPeriodPeer::ID, RegTestPeriodPeer::REG_PERIOD_ID);
     $c->addJoin(RegTestPeriodPeer::ID, TestSchedulePeer::REG_TEST_PERIOD_ID);
     $c->addJoin(TestSchedulePeer::ID, TestApplSchedPeer::TEST_SCHEDULE_ID);
     $appl_sched1 = TestApplSchedPeer::doSelectJoinTestSchedule($c);
 }
Ejemplo n.º 6
0
 public static function doSelectByClassGroup2()
 {
     $ta_id = sfContext::getInstance()->getRequest()->getParameter('id');
     $ta = TestApplicantPeer::retrieveByPK($ta_id);
     if ($ta == null) {
         return array();
     }
     if ($ta->getClassGroup2() != null) {
         $dept_id = ClassGroupPeer::retrieveByPK($ta->getClassGroup2())->getDepartmentId();
         $c = new Criteria();
         $c->addJoin(RegPeriodPeer::ID, RegTestPeriodPeer::REG_PERIOD_ID);
         $c->addJoin(AcademicCalendarPeer::ID, RegPeriodPeer::ACADEMIC_CALENDAR_ID);
         $c->add(AcademicCalendarPeer::DEPARTMENT_ID, $dept_id);
         $objs = RegTestPeriodPeer::doSelect($c);
         return $objs;
     }
 }
Ejemplo n.º 7
0
 public static function retrieveByPKs($pks, $con = null)
 {
     if ($con === null) {
         $con = Propel::getConnection(self::DATABASE_NAME);
     }
     $objs = null;
     if (empty($pks)) {
         $objs = array();
     } else {
         $criteria = new Criteria();
         $criteria->add(TestApplicantPeer::ID, $pks, Criteria::IN);
         $objs = TestApplicantPeer::doSelect($criteria, $con);
     }
     return $objs;
 }
 public static function doSelectJoinAllExceptRegionRelatedByRegionId(Criteria $c, $con = null)
 {
     $c = clone $c;
     if ($c->getDbName() == Propel::getDefaultDB()) {
         $c->setDbName(self::DATABASE_NAME);
     }
     TestApplicantParentsPeer::addSelectColumns($c);
     $startcol2 = TestApplicantParentsPeer::NUM_COLUMNS - TestApplicantParentsPeer::NUM_LAZY_LOAD_COLUMNS + 1;
     TestApplicantPeer::addSelectColumns($c);
     $startcol3 = $startcol2 + TestApplicantPeer::NUM_COLUMNS;
     ReligionPeer::addSelectColumns($c);
     $startcol4 = $startcol3 + ReligionPeer::NUM_COLUMNS;
     CountryPeer::addSelectColumns($c);
     $startcol5 = $startcol4 + CountryPeer::NUM_COLUMNS;
     DegreePeer::addSelectColumns($c);
     $startcol6 = $startcol5 + DegreePeer::NUM_COLUMNS;
     $c->addJoin(TestApplicantParentsPeer::TEST_APPLICANT_ID, TestApplicantPeer::ID);
     $c->addJoin(TestApplicantParentsPeer::RELIGION_ID, ReligionPeer::ID);
     $c->addJoin(TestApplicantParentsPeer::COUNTRY_ID, CountryPeer::ID);
     $c->addJoin(TestApplicantParentsPeer::DEGREE_ID, DegreePeer::ID);
     $rs = BasePeer::doSelect($c, $con);
     $results = array();
     while ($rs->next()) {
         $omClass = TestApplicantParentsPeer::getOMClass();
         $cls = Propel::import($omClass);
         $obj1 = new $cls();
         $obj1->hydrate($rs);
         $omClass = TestApplicantPeer::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->getTestApplicant();
             if ($temp_obj2->getPrimaryKey() === $obj2->getPrimaryKey()) {
                 $newObject = false;
                 $temp_obj2->addTestApplicantParents($obj1);
                 break;
             }
         }
         if ($newObject) {
             $obj2->initTestApplicantParentss();
             $obj2->addTestApplicantParents($obj1);
         }
         $omClass = ReligionPeer::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->getReligion();
             if ($temp_obj3->getPrimaryKey() === $obj3->getPrimaryKey()) {
                 $newObject = false;
                 $temp_obj3->addTestApplicantParents($obj1);
                 break;
             }
         }
         if ($newObject) {
             $obj3->initTestApplicantParentss();
             $obj3->addTestApplicantParents($obj1);
         }
         $omClass = CountryPeer::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->getCountry();
             if ($temp_obj4->getPrimaryKey() === $obj4->getPrimaryKey()) {
                 $newObject = false;
                 $temp_obj4->addTestApplicantParents($obj1);
                 break;
             }
         }
         if ($newObject) {
             $obj4->initTestApplicantParentss();
             $obj4->addTestApplicantParents($obj1);
         }
         $omClass = DegreePeer::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->getDegree();
             if ($temp_obj5->getPrimaryKey() === $obj5->getPrimaryKey()) {
                 $newObject = false;
                 $temp_obj5->addTestApplicantParents($obj1);
                 break;
             }
         }
         if ($newObject) {
             $obj5->initTestApplicantParentss();
             $obj5->addTestApplicantParents($obj1);
         }
         $results[] = $obj1;
     }
     return $results;
 }
Ejemplo n.º 9
0
 public function fromArray($arr, $keyType = BasePeer::TYPE_PHPNAME)
 {
     $keys = TestApplicantPeer::getFieldNames($keyType);
     if (array_key_exists($keys[0], $arr)) {
         $this->setId($arr[$keys[0]]);
     }
     if (array_key_exists($keys[1], $arr)) {
         $this->setTestApplicantDetailId($arr[$keys[1]]);
     }
     if (array_key_exists($keys[2], $arr)) {
         $this->setCode($arr[$keys[2]]);
     }
     if (array_key_exists($keys[3], $arr)) {
         $this->setCode2($arr[$keys[3]]);
     }
     if (array_key_exists($keys[4], $arr)) {
         $this->setName($arr[$keys[4]]);
     }
     if (array_key_exists($keys[5], $arr)) {
         $this->setDepartment1($arr[$keys[5]]);
     }
     if (array_key_exists($keys[6], $arr)) {
         $this->setClassGroup1($arr[$keys[6]]);
     }
     if (array_key_exists($keys[7], $arr)) {
         $this->setRegTestPeriod1($arr[$keys[7]]);
     }
     if (array_key_exists($keys[8], $arr)) {
         $this->setLocation1($arr[$keys[8]]);
     }
     if (array_key_exists($keys[9], $arr)) {
         $this->setIspass1($arr[$keys[9]]);
     }
     if (array_key_exists($keys[10], $arr)) {
         $this->setRank1($arr[$keys[10]]);
     }
     if (array_key_exists($keys[11], $arr)) {
         $this->setDepartment2($arr[$keys[11]]);
     }
     if (array_key_exists($keys[12], $arr)) {
         $this->setClassGroup2($arr[$keys[12]]);
     }
     if (array_key_exists($keys[13], $arr)) {
         $this->setRegTestPeriod2($arr[$keys[13]]);
     }
     if (array_key_exists($keys[14], $arr)) {
         $this->setLocation2($arr[$keys[14]]);
     }
     if (array_key_exists($keys[15], $arr)) {
         $this->setIspass2($arr[$keys[15]]);
     }
     if (array_key_exists($keys[16], $arr)) {
         $this->setRank2($arr[$keys[16]]);
     }
     if (array_key_exists($keys[17], $arr)) {
         $this->setApplicantType($arr[$keys[17]]);
     }
     if (array_key_exists($keys[18], $arr)) {
         $this->setEnrolled($arr[$keys[18]]);
     }
     if (array_key_exists($keys[19], $arr)) {
         $this->setRegInfo($arr[$keys[19]]);
     }
     if (array_key_exists($keys[20], $arr)) {
         $this->setStatus($arr[$keys[20]]);
     }
     if (array_key_exists($keys[21], $arr)) {
         $this->setIsAlazhar($arr[$keys[21]]);
     }
     if (array_key_exists($keys[22], $arr)) {
         $this->setHeregStatus($arr[$keys[22]]);
     }
     if (array_key_exists($keys[23], $arr)) {
         $this->setYear($arr[$keys[23]]);
     }
     if (array_key_exists($keys[24], $arr)) {
         $this->setPassword($arr[$keys[24]]);
     }
 }
Ejemplo n.º 10
0
<style>
	th {
		font-style: italic;
		background-color: #DAF383;
		border: 1px solid black;
	}
</style>
<br>&nbsp;
<?php 
echo include_partial('global/listAsPDF', array('no_header' => true, 'title' => 'TANDA BUKTI PEMBAYARAN', 'subtitle' => 'No. ' . str_pad($journal->getId(), 4, '0', STR_PAD_LEFT) . '/KEU-GDS/' . date('m/y')));
use_helper('Number', 'myHelper');
$ta = TestApplicantPeer::retrieveByPK($journal->getPayer());
?>
<br>&nbsp;
<br>&nbsp;
<table align="center" style="border-collapse:collapse;margin-left: 40px;widht:100%;">
	<tr><td colspan="3"nowrap>Telah terima pembayaran dari<br><br></td></tr>
	<tr><td>Nama Calon Siswa</td><td>&nbsp;</td><td>: <?php 
echo $ta->getName();
?>
</td></tr>
	<tr><td>No. Pendaftaran</td><td>&nbsp;</td><td>: <?php 
echo $ta->getCode();
?>
</td></tr>
	<tr><td>Komponen Biaya</td><td>&nbsp;</td><td>: <?php 
echo $journal->getAcademicCost() && $journal->getAcademicCost()->getAcademicCostComponent() ? $journal->getAcademicCost()->getAcademicCostComponent()->toString() : '-';
?>
</td></tr>
	<tr><td>Jumlah Pembayaran</td><td>&nbsp;</td><td>: Rp. <?php 
echo format_number($journal->getAmount());
Ejemplo n.º 11
0
 public static function doSelectJoinAllExceptMember(Criteria $c, $con = null)
 {
     $c = clone $c;
     if ($c->getDbName() == Propel::getDefaultDB()) {
         $c->setDbName(self::DATABASE_NAME);
     }
     VStudentActivePeer::addSelectColumns($c);
     $startcol2 = VStudentActivePeer::NUM_COLUMNS - VStudentActivePeer::NUM_LAZY_LOAD_COLUMNS + 1;
     CurriculumPeer::addSelectColumns($c);
     $startcol3 = $startcol2 + CurriculumPeer::NUM_COLUMNS;
     AcademicCalendarPeer::addSelectColumns($c);
     $startcol4 = $startcol3 + AcademicCalendarPeer::NUM_COLUMNS;
     ClassGroupPeer::addSelectColumns($c);
     $startcol5 = $startcol4 + ClassGroupPeer::NUM_COLUMNS;
     TestApplicantPeer::addSelectColumns($c);
     $startcol6 = $startcol5 + TestApplicantPeer::NUM_COLUMNS;
     StudentDetailPeer::addSelectColumns($c);
     $startcol7 = $startcol6 + StudentDetailPeer::NUM_COLUMNS;
     $c->addJoin(VStudentActivePeer::CURRICULUM_ID, CurriculumPeer::ID);
     $c->addJoin(VStudentActivePeer::ACADEMIC_CALENDAR_ID, AcademicCalendarPeer::ID);
     $c->addJoin(VStudentActivePeer::CLASS_GROUP_ID, ClassGroupPeer::ID);
     $c->addJoin(VStudentActivePeer::TEST_APPLICANT_ID, TestApplicantPeer::ID);
     $c->addJoin(VStudentActivePeer::STUDENT_DETAIL_ID, StudentDetailPeer::ID);
     $rs = BasePeer::doSelect($c, $con);
     $results = array();
     while ($rs->next()) {
         $omClass = VStudentActivePeer::getOMClass();
         $cls = Propel::import($omClass);
         $obj1 = new $cls();
         $obj1->hydrate($rs);
         $omClass = CurriculumPeer::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->getCurriculum();
             if ($temp_obj2->getPrimaryKey() === $obj2->getPrimaryKey()) {
                 $newObject = false;
                 $temp_obj2->addVStudentActive($obj1);
                 break;
             }
         }
         if ($newObject) {
             $obj2->initVStudentActives();
             $obj2->addVStudentActive($obj1);
         }
         $omClass = AcademicCalendarPeer::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->getAcademicCalendar();
             if ($temp_obj3->getPrimaryKey() === $obj3->getPrimaryKey()) {
                 $newObject = false;
                 $temp_obj3->addVStudentActive($obj1);
                 break;
             }
         }
         if ($newObject) {
             $obj3->initVStudentActives();
             $obj3->addVStudentActive($obj1);
         }
         $omClass = ClassGroupPeer::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->getClassGroup();
             if ($temp_obj4->getPrimaryKey() === $obj4->getPrimaryKey()) {
                 $newObject = false;
                 $temp_obj4->addVStudentActive($obj1);
                 break;
             }
         }
         if ($newObject) {
             $obj4->initVStudentActives();
             $obj4->addVStudentActive($obj1);
         }
         $omClass = TestApplicantPeer::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->getTestApplicant();
             if ($temp_obj5->getPrimaryKey() === $obj5->getPrimaryKey()) {
                 $newObject = false;
                 $temp_obj5->addVStudentActive($obj1);
                 break;
             }
         }
         if ($newObject) {
             $obj5->initVStudentActives();
             $obj5->addVStudentActive($obj1);
         }
         $omClass = StudentDetailPeer::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->getStudentDetail();
             if ($temp_obj6->getPrimaryKey() === $obj6->getPrimaryKey()) {
                 $newObject = false;
                 $temp_obj6->addVStudentActive($obj1);
                 break;
             }
         }
         if ($newObject) {
             $obj6->initVStudentActives();
             $obj6->addVStudentActive($obj1);
         }
         $results[] = $obj1;
     }
     return $results;
 }
Ejemplo n.º 12
0
            ?>
									<?php 
            if ($can_remove) {
                echo link_to_remote(__('delete'), array('url' => ' payment_journal_s/delete?id=' . $payment_journal->getId() . '&student_id=' . $student->getId(), 'confirm' => __('Are you sure?'), 'update' => 'content', 'script' => 'true', 'before' => "this.blur();showIndicator('content', 'snakebig_black');", 'complete' => "hideIndicator()"), array('class' => 'red'));
            }
            ?>
								</p>
							</td>
						<?php 
        } else {
            ?>
							<td class='first'>
								<?php 
            $payer = null;
            if ($payment_journal->getPayerType() == PaymentJournal::PAYER_TYPE_APPLICANT) {
                $payer = TestApplicantPeer::retrieveByPK($payment_journal->getPayer());
            } elseif ($payment_journal->getPayerType() == PaymentJournal::PAYER_TYPE_STUDENT) {
                $payer = StudentPeer::retrieveByPK($payment_journal->getPayer());
            }
            ?>
								<?php 
            echo link_to_function(strlen($payment_journal->getPayer() && $payer != null) > 0 ? $payer->tostring() : 'n/a', visual_effect('toggle_appear', 'row_' . $payment_journal->getId(), array('onclick' => 'this.blur()')));
            ?>
								<p id="row_<?php 
            echo $payment_journal->getId();
            ?>
" style="display:none;">.
									<?php 
            echo link_to_remote(__('detail'), array('url' => ' payment_journal_s/show?id=' . $payment_journal->getId(), 'update' => 'content', 'script' => 'true', 'before' => "this.blur();showIndicator('content', 'snakebig_black');", 'complete' => "hideIndicator()"), array('class' => 'green'));
            ?>
									<?php 
Ejemplo n.º 13
0
 private function getThisApplicant()
 {
     $c = new Criteria();
     $c->add(TestApplicantPeer::ENQUIRER_ID, $this->user->getId(), Criteria::EQUAL);
     $applicant = TestApplicantPeer::doSelectOne($c);
     return $applicant;
 }
Ejemplo n.º 14
0
 public function executeRegistrationCard()
 {
     $id = $this->getRequestParameter('id');
     $this->forward404Unless($id);
     $ta = TestApplicantPeer::retrieveByPK($id);
     $this->forward404Unless($ta);
     $this->filename = $this->getActionName() . '_' . $ta->getCode();
     $cw = new Criteria();
     $cw->add(DepartmentDetailPeer::DEPARTMENT_ID, $ta->getDepartment1());
     $this->department_detail = DepartmentDetailPeer::doSelectOne($cw);
     $c = new Criteria();
     $c->add(TestApplSchedPeer::TEST_APPLICANT_ID, $ta->getId());
     $c->add(AcademicCalendarPeer::DEPARTMENT_ID, $ta->getDepartment1());
     $c->addJoin(AcademicCalendarPeer::ID, RegPeriodPeer::ACADEMIC_CALENDAR_ID);
     $c->addJoin(RegPeriodPeer::ID, RegTestPeriodPeer::REG_PERIOD_ID);
     $c->addJoin(RegTestPeriodPeer::ID, TestSchedulePeer::REG_TEST_PERIOD_ID);
     $c->addJoin(TestSchedulePeer::ID, TestApplSchedPeer::TEST_SCHEDULE_ID);
     $appl_sched1 = TestApplSchedPeer::doSelectJoinTestSchedule($c);
     $this->ta = $ta;
     $this->ta_detail = $ta->getTestApplicantDetail();
     $this->sched1 = $appl_sched1;
     $this->setLayout(false);
     $this->orientation = 'landscape';
     #$this->papersize = 'letter';
     $this->papersize = 'gdscform';
     $this->setViewClass('sfDomPDF');
 }
Ejemplo n.º 15
0
 public function executeDelete()
 {
     $test_applicant = TestApplicantPeer::retrieveByPk($this->getRequestParameter('id'));
     $this->forward404Unless($test_applicant);
     $test_applicant->delete();
     return $this->redirect('ac_reg_stu/list');
 }
Ejemplo n.º 16
0
 public function executeGraduateReceipt()
 {
     $ta_id = $this->getRequestParameter('id');
     $ta = TestApplicantPeer::retrieveByPK($ta_id);
     $this->forward404Unless($ta);
     $this->ta = $ta;
     $this->ta_detail = $ta->getTestApplicantDetail();
     $ta_detail = $ta->getTestApplicantDetail();
     $this->ta_detail = $ta_detail;
     $cw = new Criteria();
     $cw->add(DepartmentDetailPeer::DEPARTMENT_ID, $ta->getDepartment1());
     $this->department_detail = DepartmentDetailPeer::doSelectOne($cw);
     $cm = new Criteria();
     $cm->add(TestApplicantParentsPeer::TEST_APPLICANT_ID, $ta->getId());
     $cm->add(TestApplicantParentsPeer::RELATION, StudentParents::RELATION_FATHER);
     $father = TestApplicantParentsPeer::doSelectOne($cm);
     if ($father == null) {
         $father = new TestApplicantParents();
     }
     $cl = new Criteria();
     $cl->add(TestApplicantParentsPeer::TEST_APPLICANT_ID, $ta->getId());
     $cl->add(TestApplicantParentsPeer::RELATION, StudentParents::RELATION_MOTHER);
     $mother = TestApplicantParentsPeer::doSelectOne($cl);
     if ($mother == null) {
         $mother = new TestApplicantParents();
     }
     $c = new Criteria();
     $c->add(TestApplSchedPeer::TEST_APPLICANT_ID, $ta->getId());
     $c->add(AcademicCalendarPeer::DEPARTMENT_ID, $ta->getDepartment1());
     $c->addJoin(AcademicCalendarPeer::ID, RegPeriodPeer::ACADEMIC_CALENDAR_ID);
     $c->addJoin(RegPeriodPeer::ID, RegTestPeriodPeer::REG_PERIOD_ID);
     $c->addJoin(RegTestPeriodPeer::ID, TestSchedulePeer::REG_TEST_PERIOD_ID);
     $c->addJoin(TestSchedulePeer::ID, TestApplSchedPeer::TEST_SCHEDULE_ID);
     $appl_sched1 = TestApplSchedPeer::doSelectJoinTestSchedule($c);
     $this->setTemplate('graduateReceipt');
     $this->papersize = 'a4';
     $this->father = $father;
     $this->mother = $mother;
     $this->sched1 = $appl_sched1;
     $this->orientation = 'portrait';
     $this->setLayout(false);
     $this->setViewClass('sfDomPDF');
 }
Ejemplo n.º 17
0
<?php

$user_id = $this->getContext()->getUser()->getAttribute('user_id', null, 'bo');
$test_applicant = TestApplicantPeer::retrieveByPk($user_id);
$cr = new Criteria();
$cr->add(TestSubjectPeer::DEPARTMENT_ID, $test_applicant->getDepartment1());
$t_subject1 = TestSubjectPeer::doSelect($cr);
$t_count1 = TestSubjectPeer::doCount($cr);
?>
<div class="block column column-80">
  <!-- Jika terdapat dua pilihan -->
  <?php 
if ($test_applicant->getDepartment2() != null) {
    ?>
            
  <table border="0" cellpadding="2" cellspacing="1" width="60%;">
	<tr><td style='text-align: left; border:none; font-weight: bold;' class="ThRows" nowrap="nowrap" colspan="6">Hasil Ujian Test 1 :</td></tr>
  </table>  
  <?php 
} else {
    ?>
  <table border="0" cellpadding="2" cellspacing="1" width="60%;">
	<tr><td style='text-align: left; border:none; font-weight: bold;' class="ThRows" nowrap="nowrap" colspan="6">Hasil Ujian Test :</td></tr>
  </table>  
  <?php 
}
?>
  <br />
  <table id="masterDataTable" bgcolor="#d4d4d4" border="0" cellpadding="2" cellspacing="1" width="60%;">
	<tr><td style='text-align: center;' class="ThRows" nowrap="nowrap" colspan="<?php 
echo $t_count1;
Ejemplo n.º 18
0
 public function executeShowApplicant()
 {
     $group_id = $this->getContext()->getUser()->getAttribute('group_id', null, 'bo');
     $c = new Criteria();
     $c->add(JobPeer::CODE, 'sm_book/listApplicant');
     $job = JobPeer::doSelectOne($c);
     $acl = AclPeer::retrieveByPK($group_id, $job->getId());
     $this->can_add = $acl->getAddPriv() == 1;
     $this->can_edit = $acl->getEditPriv() == 1;
     $this->can_remove = $acl->getRemovePriv() == 1;
     $test_applicant = TestApplicantPeer::retrieveByPk($this->getRequestParameter('id'));
     $this->forward404Unless($test_applicant);
     $actions = array(array('name' => 'back', 'url' => 'sm_book/listApplicant', 'color' => 'black'));
     $this->actions = $actions;
     $this->test_applicant_detail = $test_applicant->getTestApplicantDetail();
     $this->test_applicant = $test_applicant;
     $this->subtitle = $test_applicant->toString() . ' - id:' . $test_applicant->getId();
 }
Ejemplo n.º 19
0
            echo link_to_remote(_('Tentukan Periode Test'), array('url' => 'auth/test?id=' . $applicant_id, 'update' => 'content', 'script' => 'true'));
        } else {
            echo link_to_remote(_('Informasi Detail Pendaftar'), array('url' => 'auth/test?id=' . $applicant_id, 'update' => 'content', 'script' => 'true'));
        }
        ?>
        </li>
</ul>
</td></tr>
</table>
<br />
<?php 
    } elseif ($title == 'periode') {
        $c = new Criteria();
        $c->add(TestApplicantPhotoPeer::TEST_APPLICANT_ID, $applicant_id);
        $applicant_photo = TestApplicantPhotoPeer::doSelectOne($c);
        $applicant = TestApplicantPeer::retrieveByPK($applicant_id);
        ?>
<table width="500px" border="0" cellpadding="0" cellspacing="0">
<tr><td>
<ul id="breadcrumb">
        <li><?php 
        echo link_to(image_tag('home.png', array('title' => __('Home'))), '/auth', 'style=padding-top: 7px;');
        ?>
</li>
        <li><?php 
        echo link_to_remote(_('Biodata Pendaftar'), array('url' => 'auth/detail?id=' . $applicant_id, 'update' => 'content', 'script' => 'true'));
        ?>
</li>
        <li>
        <?php 
        if ($applicant_photo == null) {
Ejemplo n.º 20
0
 public function getTestApplicantsRelatedByDepartment2JoinRegTestPeriodRelatedByRegTestPeriod2($criteria = null, $con = null)
 {
     include_once 'lib/model/om/BaseTestApplicantPeer.php';
     if ($criteria === null) {
         $criteria = new Criteria();
     } elseif ($criteria instanceof Criteria) {
         $criteria = clone $criteria;
     }
     if ($this->collTestApplicantsRelatedByDepartment2 === null) {
         if ($this->isNew()) {
             $this->collTestApplicantsRelatedByDepartment2 = array();
         } else {
             $criteria->add(TestApplicantPeer::DEPARTMENT_2, $this->getId());
             $this->collTestApplicantsRelatedByDepartment2 = TestApplicantPeer::doSelectJoinRegTestPeriodRelatedByRegTestPeriod2($criteria, $con);
         }
     } else {
         $criteria->add(TestApplicantPeer::DEPARTMENT_2, $this->getId());
         if (!isset($this->lastTestApplicantRelatedByDepartment2Criteria) || !$this->lastTestApplicantRelatedByDepartment2Criteria->equals($criteria)) {
             $this->collTestApplicantsRelatedByDepartment2 = TestApplicantPeer::doSelectJoinRegTestPeriodRelatedByRegTestPeriod2($criteria, $con);
         }
     }
     $this->lastTestApplicantRelatedByDepartment2Criteria = $criteria;
     return $this->collTestApplicantsRelatedByDepartment2;
 }
Ejemplo n.º 21
0
				  <td><?php 
        echo $test_schedule->getTestSchedule()->getRegTestPeriod()->getRegPeriod() ? $test_schedule->getTestSchedule()->getRegTestPeriod()->getRegPeriod()->getAcademicCalendar()->getYear() : '-';
        ?>
</td> 
                  <td><?php 
        echo $test_schedule->getTestSchedule()->getStart() ? $test_schedule->getTestSchedule()->getStart('d-m-Y') : '-';
        ?>
</td>
                  <td><?php 
        echo $test_schedule->getLocationId() ? $test_schedule->getLocation()->toString() . ' (' . $test_schedule->getLocation()->getCapacity() . ')' : '-';
        ?>
</td>
                  <td align="center" style="text-align:center;">
                  	<?php 
        $c = new Criteria();
        $c->add(TestApplicantPeer::REG_TEST_PERIOD1, $test_schedule->getTestSchedule()->getRegTestPeriodId());
        $c->add(TestApplicantPeer::LOCATION1, $test_schedule->getLocationId());
        $applicant_count = TestApplicantPeer::doCount($c);
        echo $applicant_count;
        ?>
                  </td>
			</tr>
		<?php 
    }
    ?>
	<?php 
}
?>
	</tbody>
</table>
Ejemplo n.º 22
0
 public function executeSubmit()
 {
     header('Cache-Control: no-cache, must-revalidate');
     header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
     header('Content-type: application/json');
     $this->jsonwrapper = new jsonwrapper();
     /* Check sudah login atau belum */
     if (!$this->getUser()->isAuthenticated2('bo')) {
         $this->jsonwrapper->show_json_error('not login', 'Sorry, You must logged in to access this page.');
     }
     $user_id = $this->getContext()->getUser()->getAttribute('user_id', null, 'bo');
     /* Check apakah user terdaftar */
     $applicant = TestApplicantPeer::retrieveByPk($user_id);
     if (!$applicant) {
         $this->jsonwrapper->show_json_error('not register', 'Sorry, Please register first.');
     }
     /* check ada parameter question atau tidak */
     $data = $this->getRequestParameter('question');
     if (empty($data)) {
         $this->jsonwrapper->show_json_error('allQuestionError', 'Please choose an option.');
     }
     $errorAnswer = array();
     /* Cari Soal */
     $c = new Criteria();
     $c->addAscendingOrderByColumn(AngketpmbSoalPeer::ORDERING);
     $soal = AngketpmbSoalPeer::doSelect($c);
     if (!$soal) {
         $this->jsonwrapper->show_json_error('allQuestionError', 'Question is no longer exist. Please refresh the page.');
     }
     foreach ($soal as $s) {
         if (!array_key_exists($s->getId(), $data)) {
             $errorAnswer[] = array('id' => $s->getId(), 'message' => 'Please choose an option.');
         }
     }
     /* Start Transaction */
     $connection = Propel::getConnection('propel');
     $connection->begin();
     /* Getting or Creating Angket Session */
     $c = new Criteria();
     $c->add(AngketpmbSessionPeer::TEST_APPLICANT_ID, $applicant->getId(), Criteria::EQUAL);
     $angketSession = AngketpmbSessionPeer::doSelectOne($c);
     if (!$angketSession) {
         try {
             $angketSession = new AngketpmbSession();
             $angketSession->setTestApplicantId($applicant->getId());
             $angketSession->save();
         } catch (Exception $e) {
             $connection->rollback();
             $this->jsonwrapper->print_json(array('success' => 0, 'code' => 'processError', 'message' => 'Sorry, there is an error while saving your answer. Please trye again later', 'hideMessage' => 'Error while create applicant session'));
             die;
         }
     }
     /* check apakah ada pertanyaan yang belum dijawab */
     foreach ($data as $key => $value) {
         $soal = AngketpmbSoalPeer::retrieveByPk($key);
         /* Jika soal tidak ketemu */
         if (!$soal) {
             $errorAnswer[] = array('id' => $key, 'message' => 'Question is no longer exist. Please refresh the page.');
             continue;
         }
         /* Jika belum dijawab */
         if (empty($value)) {
             $errorAnswer[] = array('id' => $key, 'message' => 'Please choose an option.');
             continue;
         }
         /* Jika jawaban tidak ketemu */
         $option = AngketpmbOptionPeer::retrieveByPk($value);
         if (!$option) {
             $errorAnswer[] = array('id' => $key, 'message' => 'Option you choosed is no longer exist. Please refresh the page.');
             continue;
         }
         /* Jika jawaban bukan untuk soal ini */
         if ($option->getSoalId() != $soal->getId()) {
             $errorAnswer[] = array('id' => $key, 'message' => 'Option you choosed is not valid. Please refresh the page.');
             continue;
         }
         /* Mencari jawaban yang sudah pernah dijawab */
         $c = new Criteria();
         $c->add(AngketpmbSessionAnswerPeer::SESSION_ID, $angketSession->getId(), Criteria::EQUAL);
         $c->add(AngketpmbSessionAnswerPeer::SOAL_ID, $soal->getId(), Criteria::EQUAL);
         $angketAnswer = AngketpmbSessionAnswerPeer::doSelectOne($c);
         if ($angketAnswer) {
             /* Update */
             if ($angketAnswer->getOptionId() != $option->getId()) {
                 try {
                     $angketAnswer->setOptionId($option->getId());
                     $angketAnswer->save();
                 } catch (Exception $e) {
                     $connection->rollback();
                     $this->jsonwrapper->print_json(array('success' => 0, 'code' => 'processError', 'message' => 'Sorry, there is an error while saving your answer. Please trye again later', 'hideMessage' => 'Error while update applicant answer Id = ' . $angketAnswer->getId()));
                     die;
                 }
             }
         } else {
             /* Insert */
             try {
                 $angketAnswer = new AngketpmbSessionAnswer();
                 $angketAnswer->setSessionId($angketSession->getId());
                 $angketAnswer->setSoalId($soal->getId());
                 $angketAnswer->setOptionId($option->getId());
                 $angketAnswer->save();
             } catch (Exception $e) {
                 $connection->rollback();
                 $this->jsonwrapper->print_json(array('success' => 0, 'code' => 'processError', 'message' => 'Sorry, there is an error while saving your answer. Please trye again later', 'hideMessage' => 'Error while insert applicant answer SoalId = ' . $soal->getId()));
                 die;
             }
         }
     }
     if (count($errorAnswer) > 0) {
         $connection->rollback();
         $this->jsonwrapper->print_json(array('success' => 0, 'code' => 'someQuestionError', 'data' => $errorAnswer));
         die;
     }
     $connection->commit();
     $this->jsonwrapper->print_json(array('success' => 1, 'message' => 'Berhasil'));
     die;
 }
Ejemplo n.º 23
0
 public function getTestApplicantsJoinLocationRelatedByLocation2($criteria = null, $con = null)
 {
     include_once 'lib/model/om/BaseTestApplicantPeer.php';
     if ($criteria === null) {
         $criteria = new Criteria();
     } elseif ($criteria instanceof Criteria) {
         $criteria = clone $criteria;
     }
     if ($this->collTestApplicants === null) {
         if ($this->isNew()) {
             $this->collTestApplicants = array();
         } else {
             $criteria->add(TestApplicantPeer::TEST_APPLICANT_DETAIL_ID, $this->getId());
             $this->collTestApplicants = TestApplicantPeer::doSelectJoinLocationRelatedByLocation2($criteria, $con);
         }
     } else {
         $criteria->add(TestApplicantPeer::TEST_APPLICANT_DETAIL_ID, $this->getId());
         if (!isset($this->lastTestApplicantCriteria) || !$this->lastTestApplicantCriteria->equals($criteria)) {
             $this->collTestApplicants = TestApplicantPeer::doSelectJoinLocationRelatedByLocation2($criteria, $con);
         }
     }
     $this->lastTestApplicantCriteria = $criteria;
     return $this->collTestApplicants;
 }
Ejemplo n.º 24
0
 public function getTestApplicant($con = null)
 {
     include_once 'lib/model/om/BaseTestApplicantPeer.php';
     if ($this->aTestApplicant === null && $this->test_applicant_id !== null) {
         $this->aTestApplicant = TestApplicantPeer::retrieveByPK($this->test_applicant_id, $con);
     }
     return $this->aTestApplicant;
 }
 public static function doSelectJoinAllExceptTalent(Criteria $c, $con = null)
 {
     $c = clone $c;
     if ($c->getDbName() == Propel::getDefaultDB()) {
         $c->setDbName(self::DATABASE_NAME);
     }
     TestApplicantAchievementPeer::addSelectColumns($c);
     $startcol2 = TestApplicantAchievementPeer::NUM_COLUMNS - TestApplicantAchievementPeer::NUM_LAZY_LOAD_COLUMNS + 1;
     TestApplicantPeer::addSelectColumns($c);
     $startcol3 = $startcol2 + TestApplicantPeer::NUM_COLUMNS;
     $c->addJoin(TestApplicantAchievementPeer::TEST_APPLICANT_ID, TestApplicantPeer::ID);
     $rs = BasePeer::doSelect($c, $con);
     $results = array();
     while ($rs->next()) {
         $omClass = TestApplicantAchievementPeer::getOMClass();
         $cls = Propel::import($omClass);
         $obj1 = new $cls();
         $obj1->hydrate($rs);
         $omClass = TestApplicantPeer::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->getTestApplicant();
             if ($temp_obj2->getPrimaryKey() === $obj2->getPrimaryKey()) {
                 $newObject = false;
                 $temp_obj2->addTestApplicantAchievement($obj1);
                 break;
             }
         }
         if ($newObject) {
             $obj2->initTestApplicantAchievements();
             $obj2->addTestApplicantAchievement($obj1);
         }
         $results[] = $obj1;
     }
     return $results;
 }
Ejemplo n.º 26
0
 public function executeGetLetter()
 {
     $test_applicant = TestApplicantPeer::retrieveByPK($this->getRequestParameter('test_applicant_id'));
     $this->forward404Unless($test_applicant);
     $this->test_applicant = $test_applicant;
     $this->subject_transfers = $test_applicant->getSubjectTransfers();
     $this->setViewClass('sfDomPDF');
 }
Ejemplo n.º 27
0
"
<?php 
$i = 0;
foreach ($pager->getResults() as $payment_history) {
    ++$i;
    ?>
"<?php 
    echo $i + ($pager->getPage() - 1) * $pager->getMaxPerPage();
    ?>
",<?php 
    if (!$byStudent) {
        ?>
"<?php 
        $payer = null;
        if ($payment_history->getPaymentJournal()->getPayerType() == PaymentJournal::PAYER_TYPE_APPLICANT) {
            $payer = TestApplicantPeer::retrieveByPK($payment_history->getPaymentJournal()->getPayer());
        } elseif ($payment_history->getPaymentJournal()->getPayerType() == PaymentJournal::PAYER_TYPE_STUDENT) {
            $payer = StudentPeer::retrieveByPK($payment_history->getPaymentJournal()->getPayer());
        }
        echo strlen($payment_history->getPaymentJournal()->getPayer() && $payer != null) > 0 ? $payer->tostring() : 'n/a';
        ?>
",<?php 
    }
    ?>
"<?php 
    echo $payment_history->getPaymentJournal()->getAcademicCost() ? $payment_history->getPaymentJournal()->getAcademicCost()->getAcademicCostComponent() ? $payment_history->getPaymentJournal()->getAcademicCost()->getAcademicCostComponent()->toString() : '-' : '-';
    ?>
","<?php 
    echo $payment_history->getPaymentJournal()->getAcademicProcess() ? $payment_history->getPaymentJournal()->getAcademicProcess()->toString() : '-';
    ?>
","<?php 
Ejemplo n.º 28
0
 public function executeSaveResult()
 {
     $i18n = new sfI18N();
     $i18n->initialize($this->getContext());
     $i18n->setCulture($this->getUser()->getCulture());
     $action_i18n = $i18n->globalMessageFormat->format('save as new');
     $action_type = $this->getRequestParameter('action_type');
     $test_applicant_id = $this->getRequestParameter('test_applicant_id');
     $test_schedule_id = $this->getRequestParameter('test_schedule_id');
     $dept_id = $this->getRequestParameter('department_id');
     $c = new Criteria();
     $c->add(TestApplSchedPeer::TEST_APPLICANT_ID, $this->getRequestParameter('test_applicant_id'));
     $c->add(TestApplSchedPeer::TEST_SCHEDULE_ID, $this->getRequestParameter('test_schedule_id'));
     $test_appl_sched = TestApplSchedPeer::doSelectOne($c);
     $test_appl_sched->setTestApplicantId($this->getRequestParameter('test_applicant_id'));
     $test_appl_sched->setTestScheduleId($this->getRequestParameter('test_schedule_id'));
     $test_appl_sched->setRank('rank');
     $test_appl_sched->setDescription('description');
     $test_appl_sched->save();
     $test_applicant = TestApplicantPeer::retrieveByPK($this->getRequestParameter('test_applicant_id'));
     $test_applicant->setStatus('status');
     $test_applicant->save();
     return $this->redirect('test_schedule/listApplicant?id=' . $test_schedule_id . '&dept_id=' . $dept_id);
 }
Ejemplo n.º 29
0
    <div class="login">
            <p style="text-align:left; width:90%; line-height: 15px; padding-top: 0px;"></p>
            <h2 class="contentheading"><b><?php 
echo $this->getContext()->getUser()->getAttribute('username_long', '', 'bo');
?>
</b></h2>
                    <?php 
$applicant = TestApplicantPeer::retrieveByPk($this->getContext()->getUser()->getAttribute('user_id', '', 'bo'));
$cls = ClassGroupPeer::retrieveByPk($applicant->getClassGroup1());
?>
            <p style="padding-top: 15px; line-height: 20px;">No. Pendaftaran Anda adalah <br><b><?php 
echo $applicant->getCode() ? $applicant->getCode() : '-';
?>
</b><br />
            Pilihan Kelas Anda adalah <br><b><?php 
echo $applicant->getClassGroup1() ? $cls->toString() . ' - ' . $cls->getParentName() : '-';
?>
</b><br /><br>
            <?php 
echo link_to_remote('Informasi Detail', array('url' => 'auth/test?id=' . $applicant->getId(), 'update' => 'content', 'script' => 'true'), array('class' => 'user_logout', 'title' => 'Detail Informasi'));
?>
<br />
            <?php 
echo link_to('Logout', '/auth/logout', 'class=user_logout title=keluar');
?>
</p>
    </div>
Ejemplo n.º 30
0
 public static function doSelectJoinAllExceptPaymentModel(Criteria $c, $con = null)
 {
     $c = clone $c;
     if ($c->getDbName() == Propel::getDefaultDB()) {
         $c->setDbName(self::DATABASE_NAME);
     }
     PaymentApplicantPeer::addSelectColumns($c);
     $startcol2 = PaymentApplicantPeer::NUM_COLUMNS - PaymentApplicantPeer::NUM_LAZY_LOAD_COLUMNS + 1;
     AcademicCostPeer::addSelectColumns($c);
     $startcol3 = $startcol2 + AcademicCostPeer::NUM_COLUMNS;
     TestApplicantPeer::addSelectColumns($c);
     $startcol4 = $startcol3 + TestApplicantPeer::NUM_COLUMNS;
     AcademicProcessPeer::addSelectColumns($c);
     $startcol5 = $startcol4 + AcademicProcessPeer::NUM_COLUMNS;
     $c->addJoin(PaymentApplicantPeer::ACADEMIC_COST_ID, AcademicCostPeer::ID);
     $c->addJoin(PaymentApplicantPeer::TEST_APPLICANT_ID, TestApplicantPeer::ID);
     $c->addJoin(PaymentApplicantPeer::ACADEMIC_PROCESS_ID, AcademicProcessPeer::ID);
     $rs = BasePeer::doSelect($c, $con);
     $results = array();
     while ($rs->next()) {
         $omClass = PaymentApplicantPeer::getOMClass();
         $cls = Propel::import($omClass);
         $obj1 = new $cls();
         $obj1->hydrate($rs);
         $omClass = AcademicCostPeer::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->getAcademicCost();
             if ($temp_obj2->getPrimaryKey() === $obj2->getPrimaryKey()) {
                 $newObject = false;
                 $temp_obj2->addPaymentApplicant($obj1);
                 break;
             }
         }
         if ($newObject) {
             $obj2->initPaymentApplicants();
             $obj2->addPaymentApplicant($obj1);
         }
         $omClass = TestApplicantPeer::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->getTestApplicant();
             if ($temp_obj3->getPrimaryKey() === $obj3->getPrimaryKey()) {
                 $newObject = false;
                 $temp_obj3->addPaymentApplicant($obj1);
                 break;
             }
         }
         if ($newObject) {
             $obj3->initPaymentApplicants();
             $obj3->addPaymentApplicant($obj1);
         }
         $omClass = AcademicProcessPeer::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->getAcademicProcess();
             if ($temp_obj4->getPrimaryKey() === $obj4->getPrimaryKey()) {
                 $newObject = false;
                 $temp_obj4->addPaymentApplicant($obj1);
                 break;
             }
         }
         if ($newObject) {
             $obj4->initPaymentApplicants();
             $obj4->addPaymentApplicant($obj1);
         }
         $results[] = $obj1;
     }
     return $results;
 }