public function beforeAction() { $this->Node->findConditions = array(); if (in_array($this->action, array('edit', 'create'))) { $this->addForm('AdminNodeForm'); $this->addForm('AdminNodeTextForm'); } return parent::beforeAction(); }
public function beforeAction() { $this->Comment->findConditions = array(); if (!empty($this->params['id'])) { if (!$this->Comment->fromId((int) $this->params['id'])) { return false; } $this->data->set('Comment', $this->Comment); } return parent::beforeAction(); }
public function beforeAction() { $this->BlogPost->findConditions = array(); return parent::beforeAction(); }