public static function initialize($idP, $idS) { $OP = PromocionsPeer::retrieveByPK($idP); if (!$OP instanceof Promocions) { $OP = new Promocions(); $OP->setOrdre(0); $OP->setSiteId($idS); $OP->setActiu(true); } return new PromocionsForm($OP, array('IDS' => $idS)); }