• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

PHP GradeSpecPeer类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了PHP中GradeSpecPeer的典型用法代码示例。如果您正苦于以下问题:PHP GradeSpecPeer类的具体用法?PHP GradeSpecPeer怎么用?PHP GradeSpecPeer使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



在下文中一共展示了GradeSpecPeer类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。

示例1: executeUploadFinish

 public function executeUploadFinish()
 {
     $employee_id = sfContext::getInstance()->getUser()->getAttribute('user_id', null, 'bo');
     $employee = EmployeePeer::retrieveByPK($employee_id);
     $this->forward404Unless($employee);
     $this->employee_id = $employee_id;
     $this->employee = $employee;
     $course_schedule = CourseSchedulePeer::retrieveByPk($this->getRequestParameter('course_id'));
     $this->forward404Unless($course_schedule);
     $course_schedule_id = $course_schedule->getId();
     $actions = array();
     $this->actions = $actions;
     $this->subtitle = $course_schedule->getSubjectCurr()->getSubject()->getName() . ' - (' . $course_schedule->getClassGroup()->toString() . ' # ' . $course_schedule->getAcademicCalendar()->getName() . ')';
     $this->type = 'edit';
     $this->course_schedule = $course_schedule;
     $cr = new Criteria();
     $cr->add(GradeSpecPeer::PARENT, 1);
     $cr->addAscendingOrderByColumn(GradeSpecPeer::ID);
     $this->grade1 = GradeSpecPeer::doSelect($cr);
     $this->count1 = GradeSpecPeer::doCount($cr);
     $cw = new Criteria();
     $cw->add(GradeSpecPeer::PARENT, 7);
     $cw->addAscendingOrderByColumn(GradeSpecPeer::ID);
     $this->grade2 = GradeSpecPeer::doSelect($cw);
     $this->count2 = GradeSpecPeer::doCount($cw);
     $cm = new Criteria();
     $cm->addJoin(StudentAccalPeer::STUDENT_ID, VStudentActivePeer::ID);
     $cm->add(StudentAccalPeer::ACADEMIC_CALENDAR_ID, $course_schedule->getAcademicCalendarId());
     $cm->add(StudentAccalPeer::CLASS_GROUP_ID, $course_schedule->getClassGroupId());
     $c = new Criteria();
     $c->add(StudentAccalPeer::ACADEMIC_CALENDAR_ID, $course_schedule->getAcademicCalendarId());
     $c->add(StudentAccalPeer::CLASS_GROUP_ID, $course_schedule->getClassGroupId());
     $c->addJoin(VStudentActivePeer::ID, StudentAccalPeer::STUDENT_ID);
     $c->addJoin(StudentPeer::ID, VStudentActivePeer::ID);
     $c->addAscendingOrderByColumn(StudentPeer::CLASS_NAME);
     $rpp = $this->getRequestParameter('max_per_page', $this->getUser()->getAttribute('max_per_page', ParamsPeer::retrieveByCode('row_per_page')->getValue(), 'student'));
     $this->getUser()->setAttribute('max_per_page', $rpp, 'student');
     $pager = new sfPropelPager('Student', $rpp);
     $pager->setCriteria($c);
     $page = $this->getRequestParameter('page', $this->getUser()->getAttribute('page', 1, 'student'));
     $this->getUser()->setAttribute('page', $page, 'student');
     $pager->setPage($page);
     $pager->init();
     $this->pager = $pager;
     $this->student_count = StudentAccalPeer::doCount($cm);
 }
开发者ID:taryono,项目名称:school,代码行数:46,代码来源:actions.class.php


示例2: getLevel

 public function getLevel()
 {
     if ($this->getParent() != 0) {
         return GradeSpecPeer::retrieveByPK($this->getParent())->getLevel() + 1;
     } else {
         return 1;
     }
 }
开发者ID:taryono,项目名称:school,代码行数:8,代码来源:GradeSpec.php


示例3: sendSmsCourseTest

 public function sendSmsCourseTest($schedule, $userType, $userMessage)
 {
     $dayName = array(1 => 'Senin', 2 => 'Selasa', 3 => 'Rabu', 4 => 'Kamis', 5 => "Jum'at", 6 => 'Sabtu', 7 => 'Minggu');
     $gradeSpecCode = $schedule->getGradeSpec()->getCode();
     $parentGradeSpec = GradeSpecPeer::retrieveByPK($schedule->getGradeSpec()->getParent());
     $parentCode = $parentGradeSpec->getCode();
     $gradeSpec = $parentCode . '' . $gradeSpecCode;
     $subjectCurr = $schedule->getSubjectCurr()->getSubject()->getCode();
     $classGroup = $schedule->getClassGroup()->getName();
     $location = $schedule->getLocation()->getCampus();
     $day = $dayName[date('N', strtotime($schedule->getDate()))];
     $date = date('d-n-y', strtotime($schedule->getDate()));
     $time = date('H:i', strtotime($schedule->getDate()));
     $materi = $schedule->getDetail();
     $departmentId = $schedule->getClassGroup()->getDepartmentId();
     $senderId = $this->getSenderId($departmentId);
     /* Generate Message */
     $message = $senderId->getText() . ' ';
     $message .= $gradeSpec . ' ' . $subjectCurr . ' ' . $classGroup . '. ' . $day . ', ' . $date . ' ' . '. ' . $userMessage;
     /* Get Students */
     $students = $this->contact->getStudents($schedule->getClassGroupId());
     /* Mapping SMS */
     $sms = array('subject' => 'INFO JADWAL ' . $gradeSpec . ' ' . $subjectCurr . ' kelas ' . $classGroup, 'message' => $message);
     $this->sendSmsToStudent($senderId->getId(), $schedule->getEmployeeId(), $userType, $sms, $students);
 }
开发者ID:taryono,项目名称:school,代码行数:25,代码来源:lekarSms.php


示例4: doSelectJoinAllExceptDepartment

 public static function doSelectJoinAllExceptDepartment(Criteria $c, $con = null)
 {
     $c = clone $c;
     if ($c->getDbName() == Propel::getDefaultDB()) {
         $c->setDbName(self::DATABASE_NAME);
     }
     GradeComponentPeer::addSelectColumns($c);
     $startcol2 = GradeComponentPeer::NUM_COLUMNS - GradeComponentPeer::NUM_LAZY_LOAD_COLUMNS + 1;
     GradeSpecPeer::addSelectColumns($c);
     $startcol3 = $startcol2 + GradeSpecPeer::NUM_COLUMNS;
     $c->addJoin(GradeComponentPeer::GRADE_SPEC_ID, GradeSpecPeer::ID);
     $rs = BasePeer::doSelect($c, $con);
     $results = array();
     while ($rs->next()) {
         $omClass = GradeComponentPeer::getOMClass();
         $cls = Propel::import($omClass);
         $obj1 = new $cls();
         $obj1->hydrate($rs);
         $omClass = GradeSpecPeer::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->getGradeSpec();
             if ($temp_obj2->getPrimaryKey() === $obj2->getPrimaryKey()) {
                 $newObject = false;
                 $temp_obj2->addGradeComponent($obj1);
                 break;
             }
         }
         if ($newObject) {
             $obj2->initGradeComponents();
             $obj2->addGradeComponent($obj1);
         }
         $results[] = $obj1;
     }
     return $results;
 }
开发者ID:taryono,项目名称:school,代码行数:40,代码来源:BaseGradeComponentPeer.php


示例5: executeListScoreAsCSV

 public function executeListScoreAsCSV()
 {
     $course_schedule = CourseSchedulePeer::retrieveByPk($this->getRequestParameter('course_id'));
     $this->forward404Unless($course_schedule);
     $course_schedule_id = $course_schedule->getId();
     $cr = new Criteria();
     $cr->add(GradeSpecPeer::PARENT, 1);
     $cr->addAscendingOrderByColumn(GradeSpecPeer::CODE);
     $this->grade1 = GradeSpecPeer::doSelect($cr);
     $this->count1 = GradeSpecPeer::doCount($cr);
     $cw = new Criteria();
     $cw->add(GradeSpecPeer::PARENT, 7);
     $cw->addAscendingOrderByColumn(GradeSpecPeer::CODE);
     $this->grade2 = GradeSpecPeer::doSelect($cw);
     $this->count2 = GradeSpecPeer::doCount($cw);
     $cm = new Criteria();
     $cm->addJoin(StudentAccalPeer::STUDENT_ID, VStudentActivePeer::ID);
     $cm->add(StudentAccalPeer::ACADEMIC_CALENDAR_ID, $course_schedule->getAcademicCalendarId());
     $cm->add(StudentAccalPeer::CLASS_GROUP_ID, $course_schedule->getClassGroupId());
     $c = new Criteria();
     $c->add(StudentAccalPeer::ACADEMIC_CALENDAR_ID, $course_schedule->getAcademicCalendarId());
     $c->add(StudentAccalPeer::CLASS_GROUP_ID, $course_schedule->getClassGroupId());
     $c->addJoin(VStudentActivePeer::ID, StudentAccalPeer::STUDENT_ID);
     $c->addJoin(StudentPeer::ID, VStudentActivePeer::ID);
     $c->addAscendingOrderByColumn(StudentPeer::CLASS_NAME);
     $rpp = $this->getRequestParameter('max_per_page', $this->getUser()->getAttribute('max_per_page', ParamsPeer::retrieveByCode('row_per_page')->getValue(), 'student'));
     $this->getUser()->setAttribute('max_per_page', $rpp, 'student');
     $pager = new sfPropelPager('Student', $rpp);
     $pager->setCriteria($c);
     $page = $this->getRequestParameter('page', $this->getUser()->getAttribute('page', 1, 'student'));
     $this->getUser()->setAttribute('page', $page, 'student');
     $pager->setPage($page);
     $pager->init();
     $this->pager = $pager;
     $this->student_count = StudentAccalPeer::doCount($cm);
     $this->subtitle = $course_schedule->getSubjectCurr()->getSubject()->getName() . ' - ' . $course_schedule->getClassGroup()->toString();
     $this->course_schedule = $course_schedule;
     $this->setLayout(false);
     $this->getResponse()->setHttpHeader('Content-Type', 'text/csv');
     $this->getResponse()->setHttpHeader('Content-Disposition', 'attachment; filename="' . $this->getModuleName() . '.csv"');
 }
开发者ID:taryono,项目名称:school,代码行数:41,代码来源:actions.class.php


示例6: getGradeSpec

 public function getGradeSpec($con = null)
 {
     include_once 'lib/model/om/BaseGradeSpecPeer.php';
     if ($this->aGradeSpec === null && $this->grade_spec_id !== null) {
         $this->aGradeSpec = GradeSpecPeer::retrieveByPK($this->grade_spec_id, $con);
     }
     return $this->aGradeSpec;
 }
开发者ID:taryono,项目名称:school,代码行数:8,代码来源:BaseCur13GradeEkskul.php


示例7: input_date_tag

					</td>
					
					<td class='filter'><?php 
echo input_date_tag('filters[DATE]', isset($filters['DATE']) ? $filters['DATE'] : null, array('rich' => true, 'calendar_button_img' => '/images/calendar.gif'));
?>
</td>
                    
					<td class='filter'>
					<?php 
echo input_tag('filters[SUBJECT_NAME]', isset($filters['SUBJECT_NAME']) ? $filters['SUBJECT_NAME'] : null, array('size' => 15));
?>
</td>
					
                    			<td class='filter'>
					<?php 
echo my_object_select_tag(isset($filters['GRADE_SPEC_ID']) ? $filters['GRADE_SPEC_ID'] : null, null, GradeSpecPeer::getParents(), array('include_blank' => true, 'related_class' => 'VSpec', 'peer_method' => 'doSelectOrdered', 'control_name' => 'filters[GRADE_SPEC_ID]', 'style' => 'width: 100px;'));
?>
</td>
                    
					<td class='filter'>
					<?php 
echo input_tag('filters[EMPLOYEE_NAME]', isset($filters['EMPLOYEE_NAME']) ? $filters['EMPLOYEE_NAME'] : null, array('size' => 15));
?>
</td>
					
                    			<td class='filter'><?php 
echo input_tag('filters[CODE_CLASS]', isset($filters['CODE_CLASS']) ? $filters['CODE_CLASS'] : null, array('size' => 7));
?>
</td>
                                        
					<td class='filter'>
开发者ID:taryono,项目名称:school,代码行数:31,代码来源:listSuccess.php


示例8: doSelectJoinAllExceptGradeComponent

 public static function doSelectJoinAllExceptGradeComponent(Criteria $c, $con = null)
 {
     $c = clone $c;
     if ($c->getDbName() == Propel::getDefaultDB()) {
         $c->setDbName(self::DATABASE_NAME);
     }
     SchedulePeer::addSelectColumns($c);
     $startcol2 = SchedulePeer::NUM_COLUMNS - SchedulePeer::NUM_LAZY_LOAD_COLUMNS + 1;
     SubjectCurrPeer::addSelectColumns($c);
     $startcol3 = $startcol2 + SubjectCurrPeer::NUM_COLUMNS;
     EmployeePeer::addSelectColumns($c);
     $startcol4 = $startcol3 + EmployeePeer::NUM_COLUMNS;
     ClassGroupPeer::addSelectColumns($c);
     $startcol5 = $startcol4 + ClassGroupPeer::NUM_COLUMNS;
     LocationPeer::addSelectColumns($c);
     $startcol6 = $startcol5 + LocationPeer::NUM_COLUMNS;
     ClassSessionPeer::addSelectColumns($c);
     $startcol7 = $startcol6 + ClassSessionPeer::NUM_COLUMNS;
     AcademicCalendarPeer::addSelectColumns($c);
     $startcol8 = $startcol7 + AcademicCalendarPeer::NUM_COLUMNS;
     GradeSpecPeer::addSelectColumns($c);
     $startcol9 = $startcol8 + GradeSpecPeer::NUM_COLUMNS;
     $c->addJoin(SchedulePeer::SUBJECT_CURR_ID, SubjectCurrPeer::ID);
     $c->addJoin(SchedulePeer::EMPLOYEE_ID, EmployeePeer::ID);
     $c->addJoin(SchedulePeer::CLASS_GROUP_ID, ClassGroupPeer::ID);
     $c->addJoin(SchedulePeer::LOCATION_ID, LocationPeer::ID);
     $c->addJoin(SchedulePeer::CLASS_SESSION_ID, ClassSessionPeer::ID);
     $c->addJoin(SchedulePeer::ACADEMIC_CALENDAR_ID, AcademicCalendarPeer::ID);
     $c->addJoin(SchedulePeer::GRADE_SPEC_ID, GradeSpecPeer::ID);
     $rs = BasePeer::doSelect($c, $con);
     $results = array();
     while ($rs->next()) {
         $omClass = SchedulePeer::getOMClass();
         $cls = Propel::import($omClass);
         $obj1 = new $cls();
         $obj1->hydrate($rs);
         $omClass = SubjectCurrPeer::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->getSubjectCurr();
             if ($temp_obj2->getPrimaryKey() === $obj2->getPrimaryKey()) {
                 $newObject = false;
                 $temp_obj2->addSchedule($obj1);
                 break;
             }
         }
         if ($newObject) {
             $obj2->initSchedules();
             $obj2->addSchedule($obj1);
         }
         $omClass = EmployeePeer::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->getEmployee();
             if ($temp_obj3->getPrimaryKey() === $obj3->getPrimaryKey()) {
                 $newObject = false;
                 $temp_obj3->addSchedule($obj1);
                 break;
             }
         }
         if ($newObject) {
             $obj3->initSchedules();
             $obj3->addSchedule($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->addSchedule($obj1);
                 break;
             }
         }
         if ($newObject) {
             $obj4->initSchedules();
             $obj4->addSchedule($obj1);
         }
         $omClass = LocationPeer::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->getLocation();
             if ($temp_obj5->getPrimaryKey() === $obj5->getPrimaryKey()) {
                 $newObject = false;
//.........这里部分代码省略.........
开发者ID:taryono,项目名称:school,代码行数:101,代码来源:BaseSchedulePeer.php


示例9: executePrintMiddle


//.........这里部分代码省略.........
     $cm->addAscendingOrderByColumn(VCoursePeer::CODE);
     $this->ipas = VCoursePeer::doSelect($cm);
     $ipa_count = VCoursePeer::doCount($cm);
     $this->ipa_count = $ipa_count;
     $cl = new Criteria();
     $cl->add(VCoursePeer::CLASS_GROUP_ID, $counseling->getClassGroupId(), Criteria::IN);
     $cl->add(VCoursePeer::ACADEMIC_CALENDAR_ID, $academic_calendar->getId(), Criteria::IN);
     $cton1 = $cl->getNewCriterion(VCoursePeer::SUBJECT_CURR_ID, 343, Criteria::IN);
     $cton2 = $cl->getNewCriterion(VCoursePeer::SUBJECT_CURR_ID, 338, Criteria::IN);
     $cton3 = $cl->getNewCriterion(VCoursePeer::SUBJECT_CURR_ID, 347, Criteria::IN);
     $cton2->addOr($cton3);
     $cton1->addOr($cton2);
     $cl->add($cton1);
     $cl->addAscendingOrderByColumn(VCoursePeer::CODE);
     $this->ips = VCoursePeer::doSelect($cl);
     $ips_count = VCoursePeer::doCount($cl);
     $this->ips_count = $ips_count;
     $cd = new Criteria();
     $cd->add(VCoursePeer::CLASS_GROUP_ID, $counseling->getClassGroupId(), Criteria::IN);
     $cd->add(VCoursePeer::ACADEMIC_CALENDAR_ID, $academic_calendar->getId(), Criteria::IN);
     $cton1 = $cd->getNewCriterion(VCoursePeer::SUBJECT_CURR_ID, 352, Criteria::IN);
     $cton2 = $cd->getNewCriterion(VCoursePeer::SUBJECT_CURR_ID, 349, Criteria::IN);
     $cton3 = $cd->getNewCriterion(VCoursePeer::SUBJECT_CURR_ID, 348, Criteria::IN);
     $cton4 = $cd->getNewCriterion(VCoursePeer::SUBJECT_CURR_ID, 341, Criteria::IN);
     $cton5 = $cd->getNewCriterion(VCoursePeer::SUBJECT_CURR_ID, 355, Criteria::IN);
     $cton4->addOr($cton5);
     $cton3->addOr($cton4);
     $cton2->addOr($cton3);
     $cton1->addOr($cton2);
     $cd->add($cton1);
     $cd->addAscendingOrderByColumn(VCoursePeer::CODE);
     $this->subjects2 = VCoursePeer::doSelect($cd);
     $subject_count2 = VCoursePeer::doCount($cd);
     $this->subject_count2 = $subject_count2;
     $cb = new Criteria();
     $cb->add(VCoursePeer::CLASS_GROUP_ID, $counseling->getClassGroupId(), Criteria::IN);
     $cb->add(VCoursePeer::ACADEMIC_CALENDAR_ID, $academic_calendar->getId(), Criteria::IN);
     $cb->add(VCoursePeer::SUBJECT_GROUP_ID, 7, Criteria::IN);
     $cb->add(VCoursePeer::SUBJECT_CURR_ID, 319, Criteria::NOT_IN);
     $cb->add(VCoursePeer::SUBJECT_CURR_ID, 333, Criteria::NOT_IN);
     $cb->addAscendingOrderByColumn(VCoursePeer::CODE);
     $this->subjects7 = VCoursePeer::doSelect($cb);
     $subject_count7 = VCoursePeer::doCount($cb);
     $this->subject_count7 = $subject_count7;
     $crit = new Criteria();
     $crit->add(VCoursePeer::CLASS_GROUP_ID, $counseling->getClassGroupId());
     $crit->add(VCoursePeer::ACADEMIC_CALENDAR_ID, $academic_calendar->getId());
     $crit->add(VCoursePeer::SUBJECT_GROUP_ID, 8);
     $crit->addAscendingOrderByColumn(VCoursePeer::CODE);
     $this->subjects8 = VCoursePeer::doSelect($crit);
     $subject_count8 = VCoursePeer::doCount($crit);
     $this->subject_count8 = $subject_count8;
     $cr = new Criteria();
     $cr->add(GradeSpecPeer::PARENT, 1);
     $cr->addAscendingOrderByColumn(GradeSpecPeer::ID);
     $this->grade1 = GradeSpecPeer::doSelect($cr);
     $this->count1 = GradeSpecPeer::doCount($cr);
     $cr = new Criteria();
     $cr->add(GradeSpecPeer::PARENT, 7);
     $cr->addAscendingOrderByColumn(GradeSpecPeer::ID);
     $this->grade2 = GradeSpecPeer::doSelect($cr);
     $this->count2 = GradeSpecPeer::doCount($cr);
     $cron = new Criteria();
     $cron->add(GradeSpecPeer::PARENT, 1);
     $cton1 = $cron->getNewCriterion(GradeSpecPeer::ID, 53, Criteria::NOT_IN);
     $cton2 = $cron->getNewCriterion(GradeSpecPeer::ID, 54, Criteria::NOT_IN);
     $cton1->addAnd($cton2);
     $cron->add($cton1);
     $cron->addAscendingOrderByColumn(GradeSpecPeer::ID);
     $this->grade_pdf1 = GradeSpecPeer::doSelect($cron);
     $this->count_pdf1 = GradeSpecPeer::doCount($cron);
     $crew = new Criteria();
     $crew->add(GradeSpecPeer::PARENT, 7);
     $cton1 = $crew->getNewCriterion(GradeSpecPeer::ID, 55, Criteria::NOT_IN);
     $cton2 = $crew->getNewCriterion(GradeSpecPeer::ID, 56, Criteria::NOT_IN);
     $cton1->addAnd($cton2);
     $crew->add($cton1);
     $crew->addAscendingOrderByColumn(GradeSpecPeer::ID);
     $this->grade_pdf2 = GradeSpecPeer::doSelect($crew);
     $this->count_pdf2 = GradeSpecPeer::doCount($crew);
     $ce = new Criteria();
     $ce->add(DepartmentDetailPeer::DEPARTMENT_ID, $counseling->getAcademicCalendar()->getDepartmentId());
     $this->department_detail = DepartmentDetailPeer::doSelectOne($ce);
     $rpp = $this->getRequestParameter('max_per_page', 999);
     $pager = new sfPropelPager('VCourse', $rpp);
     $pager->setCriteria($co);
     $pager->setPage($this->getRequestParameter('page', 1));
     $pager->init();
     $this->pager = $pager;
     $this->students = $students;
     $this->subtitle = '';
     $this->counseling = $counseling;
     $this->tanggal = $time;
     $this->tgl_cetak = $tgl;
     $this->time2 = $time2;
     $this->academic_calendar = $academic_calendar;
     $this->papersize = 'a4';
     $this->orientation = 'portrait';
     $this->setViewClass('sfDomPDF');
 }
开发者ID:taryono,项目名称:school,代码行数:101,代码来源:actions.class.php


示例10: retrieveByPKs

 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(GradeSpecPeer::ID, $pks, Criteria::IN);
         $objs = GradeSpecPeer::doSelect($criteria, $con);
     }
     return $objs;
 }
开发者ID:taryono,项目名称:school,代码行数:15,代码来源:BaseGradeSpecPeer.php


示例11: executeDelete

 public function executeDelete()
 {
     $grade_spec = GradeSpecPeer::retrieveByPk($this->getRequestParameter('id'));
     $this->forward404Unless($grade_spec);
     $ref_error = 0;
     foreach ($grade_spec->getRefCountMethods() as $ref) {
         $method = "count" . $ref['affix'];
         $count = $grade_spec->{$method}();
         if ($count > 0) {
             ++$ref_error;
             $this->getRequest()->setError('grade_spec/delete/' . sfInflector::camelize($ref['table']), $count);
         }
     }
     if ($ref_error > 0) {
         $this->getRequest()->setError('grade_spec/delete', '_ERR_DELETE_ (' . $grade_spec->toString() . ' - id:' . $grade_spec->getId() . ')');
     } else {
         $grade_spec->delete();
     }
     return $this->forward('grade_spec', 'list');
 }
开发者ID:taryono,项目名称:school,代码行数:20,代码来源:actions.class.php


示例12: input_hidden_tag

echo input_hidden_tag('course_id', $course_schedule->getId());
echo input_hidden_tag('action_type', '');
?>
<table class="form">
<tr><td class="form">
	<table class="form_content" width="100%">
	<tbody>
        <tr>
           <td class="first" width="20%" style="vertical-align:middle;"><label><?php 
echo __('Kategori');
?>
</label></td>
           <td width="2%" class="first" style="text-align:center; vertical-align:middle;">:</td>
		   <td style="vertical-align:middle;" class="first">
			<?php 
echo my_object_select_tag($schedule, 'getGradeSpecId', GradeSpecPeer::getParents(), array('related_class' => 'VSpec', 'include_blank' => true, 'peer_method' => 'doSelectOrdered'));
?>
			<?php 
echo form_error('grade_spec_id');
?>
           </td>
        </tr>
        <tr>
           <td style="vertical-align:top;"><label><?php 
echo __('Materi Ujian');
?>
</label></td>
           <td style="text-align:center; vertical-align:top;">:</td>
           <td style="vertical-align:top;">
           <?php 
echo object_textarea_tag($schedule, 'getDetail', array('size' => '50x3'));
开发者ID:taryono,项目名称:school,代码行数:31,代码来源:editTestSuccess.php


示例13: executeListMiddle

 public function executeListMiddle()
 {
     $employee_id = sfContext::getInstance()->getUser()->getAttribute('user_id', null, 'bo');
     $employee = EmployeePeer::retrieveByPK($employee_id);
     $this->forward404Unless($employee);
     $counseling_id = $this->getRequestParameter('counseling_id');
     $counseling = CounselingPeer::retrieveByPK($counseling_id);
     $this->forward404Unless($counseling);
     $accal_id = $this->getRequestParameter('accal_id');
     $academic_calendar = AcademicCalendarPeer::retrieveByPK($accal_id);
     $this->forward404Unless($academic_calendar);
     $student_id = $this->getRequestParameter('student_id');
     $student = StudentPeer::retrieveByPK($this->getRequestParameter('student_id'));
     $this->forward404Unless($student);
     if ($employee->getDepartmentId() == 3) {
         $c = new Criteria();
         $c->add(VCoursePeer::CLASS_GROUP_ID, $student->getClassGroupId());
         $c->add(VCoursePeer::ACADEMIC_CALENDAR_ID, $academic_calendar->getId());
         $c->addAscendingOrderByColumn(VCoursePeer::CODE);
         $this->subjects = VCoursePeer::doSelect($c);
         $subject_count = VCoursePeer::doCount($c);
         $this->subject_count = $subject_count;
         $c = new Criteria();
         $c->add(VCoursePeer::CLASS_GROUP_ID, $student->getClassGroupId(), Criteria::IN);
         $c->add(VCoursePeer::ACADEMIC_CALENDAR_ID, $academic_calendar->getId(), Criteria::IN);
         $c->add(VCoursePeer::SUBJECT_GROUP_ID, 7, Criteria::IN);
         $c->add(VCoursePeer::SUBJECT_CURR_ID, 319, Criteria::NOT_IN);
         $c->addAscendingOrderByColumn(VCoursePeer::CODE);
         $this->subjects7 = VCoursePeer::doSelect($c);
         $subject_count7 = VCoursePeer::doCount($c);
         $this->subject_count7 = $subject_count7;
     } else {
         $c = new Criteria();
         $c->add(VCoursePeer::CLASS_GROUP_ID, $student->getClassGroupId(), Criteria::IN);
         $c->add(VCoursePeer::ACADEMIC_CALENDAR_ID, $academic_calendar->getId(), Criteria::IN);
         $c->add(VCoursePeer::SUBJECT_CURR_ID, 316, Criteria::NOT_IN);
         $c->addAscendingOrderByColumn(VCoursePeer::CODE);
         $this->subjects = VCoursePeer::doSelect($c);
         $subject_count = VCoursePeer::doCount($c);
         $this->subject_count = $subject_count;
         $c = new Criteria();
         $c->add(VCoursePeer::CLASS_GROUP_ID, $student->getClassGroupId(), Criteria::IN);
         $c->add(VCoursePeer::ACADEMIC_CALENDAR_ID, $academic_calendar->getId(), Criteria::IN);
         $c->add(VCoursePeer::SUBJECT_GROUP_ID, 7, Criteria::IN);
         $c->add(VCoursePeer::SUBJECT_CURR_ID, 316, Criteria::NOT_IN);
         $c->addAscendingOrderByColumn(VCoursePeer::CODE);
         $this->subjects7 = VCoursePeer::doSelect($c);
         $subject_count7 = VCoursePeer::doCount($c);
         $this->subject_count7 = $subject_count7;
     }
     $c = new Criteria();
     $c->add(VCoursePeer::CLASS_GROUP_ID, $student->getClassGroupId());
     $c->add(VCoursePeer::ACADEMIC_CALENDAR_ID, $academic_calendar->getId());
     $c->add(VCoursePeer::SUBJECT_GROUP_ID, 8);
     $c->addAscendingOrderByColumn(VCoursePeer::CODE);
     $this->subjects8 = VCoursePeer::doSelect($c);
     $subject_count8 = VCoursePeer::doCount($c);
     $this->subject_count8 = $subject_count8;
     $cr = new Criteria();
     $cr->add(GradeSpecPeer::PARENT, 1);
     $this->grade1 = GradeSpecPeer::doSelect($cr);
     $this->count1 = GradeSpecPeer::doCount($cr);
     $cr = new Criteria();
     $cr->add(GradeSpecPeer::PARENT, 7);
     $this->grade2 = GradeSpecPeer::doSelect($cr);
     $this->count2 = GradeSpecPeer::doCount($cr);
     $cw = new Criteria();
     $cton1 = $cw->getNewCriterion(GradeSpecPeer::PARENT, 1, Criteria::IN);
     $cton2 = $cw->getNewCriterion(GradeSpecPeer::ID, 19, Criteria::NOT_IN);
     $cton3 = $cw->getNewCriterion(GradeSpecPeer::ID, 25, Criteria::NOT_IN);
     $cton2->addAnd($cton3);
     $cton1->addAnd($cton2);
     $cw->add($cton1);
     $this->gradeSD1 = GradeSpecPeer::doSelect($cw);
     $this->countSD1 = GradeSpecPeer::doCount($cw);
     $cw = new Criteria();
     $cton1 = $cw->getNewCriterion(GradeSpecPeer::PARENT, 7, Criteria::IN);
     $cton2 = $cw->getNewCriterion(GradeSpecPeer::ID, 18, Criteria::NOT_IN);
     $cton3 = $cw->getNewCriterion(GradeSpecPeer::ID, 26, Criteria::NOT_IN);
     $cton2->addAnd($cton3);
     $cton1->addAnd($cton2);
     $cw->add($cton1);
     $this->gradeSD2 = GradeSpecPeer::doSelect($cw);
     $this->countSD2 = GradeSpecPeer::doCount($cw);
     $crit = new Criteria();
     $crit->add(GradeSpecPeer::PARENT, 1);
     $cton1 = $crit->getNewCriterion(GradeSpecPeer::ID, 53, Criteria::NOT_IN);
     $cton2 = $crit->getNewCriterion(GradeSpecPeer::ID, 54, Criteria::NOT_IN);
     $cton1->addAnd($cton2);
     $crit->add($cton1);
     $this->gradePdf1 = GradeSpecPeer::doSelect($crit);
     $this->countPdf1 = GradeSpecPeer::doCount($crit);
     $crew = new Criteria();
     $crew->add(GradeSpecPeer::PARENT, 7);
     $cton1 = $crew->getNewCriterion(GradeSpecPeer::ID, 55, Criteria::NOT_IN);
     $cton2 = $crew->getNewCriterion(GradeSpecPeer::ID, 56, Criteria::NOT_IN);
     $cton1->addAnd($cton2);
     $crew->add($cton1);
     $this->gradePdf2 = GradeSpecPeer::doSelect($crew);
     $this->countPdf2 = GradeSpecPeer::doCount($crew);
//.........这里部分代码省略.........
开发者ID:taryono,项目名称:school,代码行数:101,代码来源:actions.class.php


示例14: executeEditFromScore

 public function executeEditFromScore()
 {
     $student_id = $this->getRequestParameter('student_id');
     $student = StudentPeer::retrieveByPK($student_id);
     $this->forward404Unless($student);
     $this->student = $student;
     $group_id = $this->getContext()->getUser()->getAttribute('group_id', null, 'bo');
     $c = new Criteria();
     $c->add(JobPeer::CODE, $this->getModuleName());
     $job = JobPeer::doSelectOne($c);
     $acl = AclPeer::retrieveByPK($group_id, $job->getId());
     if (!$acl) {
         $this->forward('default', 'error404');
     }
     $this->can_add = $acl->getAddPriv() == 1;
     $this->can_edit = $acl->getEditPriv() == 1;
     $this->can_remove = $acl->getRemovePriv() == 1;
     $c = new Criteria();
     $c->add(VCoursePeer::CLASS_GROUP_ID, $student->getClassGroupId());
     $c->add(VCoursePeer::ACADEMIC_CALENDAR_ID, $student->getAcademicCalendarId());
     $c->addAscendingOrderByColumn(VCoursePeer::SUBJECT_CURR_ID);
     $this->subjects = VCoursePeer::doSelect($c);
     $this->subject_count = VCoursePeer::doCount($c);
     $cr = new Criteria();
     $cr->add(GradeSpecPeer::PARENT, 1);
     $this->grade1 = GradeSpecPeer::doSelect($cr);
     $this->count1 = GradeSpecPeer::doCount($cr);
     $cr = new Criteria();
     $cr->add(GradeSpecPeer::PARENT, 7);
     $this->grade2 = GradeSpecPeer::doSelect($cr);
     $this->count2 = GradeSpecPeer::doCount($cr);
     $rpp = $this->getRequestParameter('max_per_page', 999);
     $pager = new sfPropelPager('VCourse', $rpp);
     $pager->setCriteria($c);
     $pager->setPage($this->getRequestParameter('page', 1));
     $pager->init();
     $this->pager = $pager;
 }
开发者ID:taryono,项目名称:school,代码行数:38,代码来源:actions.class.php


示例15: __

                    <?php 
if ($pager->getNbResults() < 1) {
    ?>
                        <tr class="list"><td colspan="100"><div class="no_record"><?php 
    echo __('No record found');
    ?>
</div></td></tr>
                    <?php 
} else {
    ?>
                        <?php 
    $i = 0;
    foreach ($pager->getResults() as $grade_spec) {
        $c = new Criteria();
        $c->add(GradeSpecPeer::PARENT, $grade_spec->getId());
        $grade_spec->child = GradeSpecPeer::doCount($c);
        ?>
                        <tr id='cs_<?php 
        echo $grade_spec->getId();
        ?>
' class="list<?php 
        ++$i;
        if ($i % 2 == 0) {
            echo ' even';
        }
        ?>
">
                                <td id='cs_<?php 
        echo $grade_spec->getId();
        ?>
_expand' style="vertical-align: middle; text-align: center;">
开发者ID:taryono,项目名称:school,代码行数:31,代码来源:listSuccess.php


示例16: executeEditObject

 public function executeEditObject()
 {
     $rule_id = $this->getRequestParameter('rule_id');
     $score_rule = ScoreRulePeer::retrieveByPK($rule_id);
     $this->forward404Unless($score_rule);
     $actions = array(array('name' => 'save', 'type' => 'submit', 'options' => array('class' => 'save_button', 'onclick' => "action_type.value=this.value")));
     array_push($actions, array('name' => 'cancel', 'url' => 'score_rule_new/listSubject?rule_id=' . $score_rule->getId(), 'color' => 'white'));
     $c = new Criteria();
     $c->add(GradeSpecPeer::TYPE_SPEC, GradeSpec::OTHERS, Criteria::NOT_EQUAL);
     $grade_specs = GradeSpecPeer::doSelect($c);
     $this->grade_specs = $grade_specs;
     $subtitle = $score_rule->toName();
     $this->subtitle = $subtitle;
     $this->actions = $actions;
     $this->type = 'add';
     $this->score_rule = $score_rule;
     $actions2 = array(array('name' => '<span>Aturan Penilaian</span>', 'url' => 'score_rule_new/list', 'color' => 'sun'));
     array_push($actions2, array('name' => '<span>Daftar Mata Pelajaran</span>', 'url' => 'score_rule_new/listSubject?rule_id=' . $score_rule->getId(), 'color' => 'sun'));
     array_push($actions2, array('name' => '<span>Daftar Kategori Penilaian</span>', 'url' => 'score_rule_new/listObject?rule_id=' . $score_rule->getId(), 'color' => 'sky', 'type' => 'direct'));
     $this->actions2 = $actions2;
 }
开发者ID:taryono,项目名称:school,代码行数:21,代码来源:actions.class.php


示例17: executeListHistoryScore

 public function executeListHistoryScore()
 {
     $student_id = sfContext::getInstance()->getUser()->getAttribute('user_id', null, 'bo');
     $student = StudentPeer::retrieveByPK($student_id);
     $this->forward404Unless($student);
     $course_schedule = CourseSchedulePeer::retrieveByPk($this->getRequestParameter('course_id'));
     $this->forward404Unless($course_schedule);
     $course_schedule_id = $course_schedule->getId();
     $c = new Criteria();
     $c->addJoin(StudentAccalPeer::STUDENT_ID, VStudentActivePeer::ID);
     $c->add(StudentAccalPeer::STUDENT_ID, $student->getId());
     $c->add(StudentAccalPeer::ACADEMIC_CALENDAR_ID, $course_schedule->getAcademicCalendarId());
     $c->add(StudentAccalPeer::CLASS_GROUP_ID, $course_schedule->getClassGroupId());
     $student_accal = StudentAccalPeer::doSelectOne($c);
     $this->forward404Unless($student_accal);
     $this->student_accal = $student_accal;
     $cr = new Criteria();
     $cr->add(GradeSpecPeer::PARENT, 1);
     $this->grade1 = GradeSpecPeer::doSelect($cr);
     $this->count1 = GradeSpecPeer::doCount($cr);
     $crew = new Criteria();
     $crew->add(GradeSpecPeer::PARENT, 7);
     $this->grade2 = GradeSpecPeer::doSelect($crew);
     $this->count2 = GradeSpecPeer::doCount($crew);
     $actions = array();
     $this->actions = $actions;
     $this->subtitle = $course_schedule->getSubjectCurr()->getSubject()->getName() . ' - ' . $course_schedule->getClassGroup()->toString();
     $this->type = 'list';
     $this->course_schedule = $course_schedule;
     $this->course_schedule_id = $course_schedule_id;
     $this->student = $student;
     $actions2 = array(array('name' => '<span>' . $course_schedule->getAcademicCalendar()->getName() . '</span>', 'url' => 'student_agenda/listHistory', 'color' => 'sun'));
     array_push($actions2, array('name' => '<span>Agenda Kelas</span>', 'url' => 'student_agenda/listHistoryAgenda?course_id=' . $course_schedule->getId(), 'color' => 'sun'));
     array_push($actions2, array('name' => '<span>Absensi</span>', 'url' => 'student_agenda/listHistoryAbsence?course_id=' . $course_schedule->getId(), 'color' => 'sun'));
     array_push($actions2, array('name' => '<span>Jadwal Tugas/Ulangan/PR</span>', 'url' => 'student_agenda/listHistoryTest?course_id=' . $course_schedule->getId(), 'color' => 'sun'));
     array_push($actions2, array('name' => '<span>Penilaian</span>', 'url' => 'student_agenda/listHistoryScore?course_id=' . $course_schedule->getId(), 'color' => 'sun', 'type' => 'direct'));
     $this->actions2 = $actions2;
 }
开发者ID:taryono,项目名称:school,代码行数:38,代码来源:actions.class.php


示例18: doSelectJoinAllExceptAcademicCalendar

 public static function doSelectJoinAllExceptAcademicCalendar(Criteria $c, $con = null)
 {
     $c = clone $c;
     if ($c->getDbName() == Propel::getDefaultDB()) {
         $c->setDbName(self::DATABASE_NAME);
     }
     VRaportPeer::addSelectColumns($c);
     $startcol2 = VRaportPeer::NUM_COLUMNS - VRaportPeer::NUM_LAZY_LOAD_COLUMNS + 1;
     StudentCoursePeer::addSelectColumns($c);
     $startcol3 = $startcol2 + StudentCoursePeer::NUM_COLUMNS;
     GradeComponentPeer::addSelectColumns($c);
     $startcol4 = $startcol3 + GradeComponentPeer::NUM_COLUMNS;
     GradeSpecPeer::addSelectColumns($c);
     $startcol5 = $startcol4 + GradeSpecPeer::NUM_COLUMNS;
     CitationPeer::addSelectColumns($c);
     $startcol6 = $startcol5 + CitationPeer::NUM_COLUMNS;
     SubjectPeer::addSelectColumns($c);
     $startcol7 = $startcol6 + SubjectPeer::NUM_COLUMNS;
     $c->addJoin(VRaportPeer::STUDENT_COURSE_ID, StudentCoursePeer::ID);
     $c->addJoin(VRaportPeer::GRADE_COMPONENT_ID, GradeComponentPeer::ID);
     $c->addJoin(VRaportPeer::GRADE_SPEC_ID, GradeSpecPeer::ID);
     $c->addJoin(VRaportPeer::CITATION_ID, CitationPeer::ID);
     $c->addJoin(VRaportPeer::SUBJECT_ID, SubjectPeer::ID);
     $rs = BasePeer::doSelect($c, $con);
     $results = array();
     while ($rs->next()) {
         $omClass = VRaportPeer::getOMClass();
         $cls = Propel::import($omClass);
         $obj1 = new $cls();
         $obj1->hydrate($rs);
         $omClass = StudentCoursePeer::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->getStudentCourse();
             if ($temp_obj2->getPrimaryKey() === $obj2->getPrimaryKey()) {
                 $newObject = false;
                 $temp_obj2->addVRaport($obj1);
                 break;
             }
         }
         if ($newObject) {
             $obj2->initVRaports();
             $obj2->addVRaport($obj1);
         }
         $omClass = GradeComponentPeer::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->getGradeComponent();
             if ($temp_obj3->getPrimaryKey() === $obj3->getPrimaryKey()) {
                 $newObject = false;
                 $temp_obj3->addVRaport($obj1);
                 break;
             }
         }
         if ($newObject) {
             $obj3->initVRaports();
             $obj3->addVRaport($obj1);
         }
         $omClass = GradeSpecPeer::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->getGradeSpec();
             if ($temp_obj4->getPrimaryKey() === $obj4->getPrimaryKey()) {
                 $newObject = false;
                 $temp_obj4->addVRaport($obj1);
                 break;
             }
         }
         if ($newObject) {
             $obj4->initVRaports();
             $obj4->addVRaport($obj1);
         }
  

鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PHP GradebookUtils类代码示例发布时间:2022-05-23
下一篇:
PHP Gpf_SqlBuilder_SelectBuilder类代码示例发布时间:2022-05-23
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap