Exemplo n.º 1
0
 /**
  * Polls list
  * 
  **/
 public function executeList()
 {
     $c = new Criteria();
     $c->addDescendingOrderByColumn(sfPollPeer::CREATED_AT);
     $this->polls = sfPollPeer::doSelect($c);
 }
Exemplo n.º 2
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(sfPollPeer::ID, $pks, Criteria::IN);
         $objs = sfPollPeer::doSelect($criteria, $con);
     }
     return $objs;
 }