Ejemplo n.º 1
0
 /**
  * Retrieve multiple objects by pkey.
  *
  * @param      array $pks List of primary keys
  * @param      PropelPDO $con the connection to use
  * @throws     PropelException Any exceptions caught during processing will be
  *		 rethrown wrapped into a PropelException.
  */
 public static function retrieveByPKs($pks, PropelPDO $con = null)
 {
     if ($con === null) {
         $con = Propel::getConnection(WingJobPeer::DATABASE_NAME, Propel::CONNECTION_READ);
     }
     $objs = null;
     if (empty($pks)) {
         $objs = array();
     } else {
         $criteria = new Criteria(WingJobPeer::DATABASE_NAME);
         $criteria->add(WingJobPeer::ID, $pks, Criteria::IN);
         $objs = WingJobPeer::doSelect($criteria, $con);
     }
     return $objs;
 }
Ejemplo n.º 2
0
 /**
  * Member Roster for pilot member
  */
 public function executeRoster(sfWebRequest $request)
 {
     if (!$this->getUser()->hasCredential(array('Administrator', 'Staff', 'Pilot', 'Member'), false)) {
         $this->getUser()->setFlash("warning", 'You don\'t have permission to access this url ' . $request->getReferer());
         $this->redirect('dashboard/index');
     }
     $this->wing_jobs = WingJobPeer::doSelect(new Criteria());
     $this->wing_job2 = $request->getParameter('wing_job1');
     $this->processRosterFilter($request);
     $this->pager = MemberPeer::getRosterPager($this->max, $this->page, $this->pilot_status, $this->wing_id, $this->ifr, $this->multi, $this->instructor, $this->board_member, $this->coordinator, $this->orientation_pilot, $this->state, $this->home_base, $this->area_code, $this->email, $this->wing_job2);
     $this->members = $this->pager->getResults();
 }