/** * @param \DLigo\Animaltool\Domain\Model\Animal $animal * @Flow\IgnoreValidation (argumentName="$animal") * @return void */ public function treatmentAction(Animal $animal) { $this->response->setHeader('no-store', true); $this->response->setHeader('no-cache', true); $this->view->assign('healthConditions', $animal->getHealthConditions()); $this->view->assign('breads', $this->breadRepository->findBySpecies($animal->getSpecies())); $this->view->assign('colors', $this->colorRepository->findAll()); $this->view->assign('genders', $animal->getGenders()); $this->view->assign('doctors', $this->userRepository->findByRoles(array('DLigo.Animaltool:Doctor'))); $ts = $this->therapyRepository->findAll(); $therapies = array(); foreach ($ts as $t) { $therapies[$this->persistenceManager->getIdentifierByObject($t)] = $t; } $this->view->assign('therapies', $therapies); $this->view->assign('animal', $animal); }