public function executeDelete(sfWebRequest $request) { $request->checkCSRFProtection(); $this->forward404Unless($Grupa = GrupaPeer::retrieveByPk($request->getParameter('id')), sprintf('Object Grupa does not exist (%s).', $request->getParameter('id'))); $Grupa->delete(); $this->redirect('grupa/index'); }
/** * Get the associated Grupa object * * @param PropelPDO Optional Connection object. * @return Grupa The associated Grupa object. * @throws PropelException */ public function getGrupa(PropelPDO $con = null) { if ($this->aGrupa === null && $this->grupa_id !== null) { $this->aGrupa = GrupaPeer::retrieveByPk($this->grupa_id); /* The following can be used additionally to guarantee the related object contains a reference to this object. This level of coupling may, however, be undesirable since it could result in an only partially populated collection in the referenced object. $this->aGrupa->addKlientGrupas($this); */ } return $this->aGrupa; }