public function chooseType() { $this->criteria->addAscendingOrderByColumn(WebModuleTypePeer::NAME); $criteria = new Criteria(); $moduleTypes = WebModuleTypePeer::doSelect($this->criteria); return array('moduleTypes' => $moduleTypes, 'template' => 'module/choosetype'); }
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(WebModuleTypePeer::ID, $pks, Criteria::IN); $objs = WebModuleTypePeer::doSelect($criteria, $con); } return $objs; }