Created
March 24, 2015 15:28
-
-
Save Skyl0/7f284c49d1d82e542e03 to your computer and use it in GitHub Desktop.
Controller Problems
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace Y7group\Y7Fahrzeugdatenbank\Controller; | |
/** | |
* FahrzeugController | |
*/ | |
class FahrzeugController extends \TYPO3\CMS\Extbase\Mvc\Controller\ActionController { | |
/** | |
* fahrzeugRepository | |
* | |
* @var \Y7group\Y7Fahrzeugdatenbank\Domain\Repository\FahrzeugRepository | |
* @inject | |
*/ | |
protected $fahrzeugRepository = NULL; | |
/** | |
* action list | |
* | |
* @return void | |
*/ | |
public function listAction() { | |
$fahrzeugs = $this->fahrzeugRepository->findAll(); | |
$this->view->assign('fahrzeugs', $fahrzeugs); | |
} | |
/** | |
* action show | |
* | |
* @param \Y7group\Y7Fahrzeugdatenbank\Domain\Model\Fahrzeug $fahrzeug | |
* @return void | |
*/ | |
public function showAction(\Y7group\Y7Fahrzeugdatenbank\Domain\Model\Fahrzeug $fahrzeug) { | |
$this->view->assign('fahrzeug', $fahrzeug); | |
} | |
/** | |
* action listByCategory | |
* @param \Y7group\Y7Fahrzeugdatenbank\Domain\Model\FzKategorie $cat | |
* @return void | |
*/ | |
public function listByCategoryAction(){//\Y7group\Y7Fahrzeugdatenbank\Domain\Model\FzKategorie $cat) { | |
$fahrzeugByCat = $this->fahrzeugRepository->findAll(); | |
debug($fahrzeugByCat, '('.__CLASS__.'::'.__FUNCTION__.')', __LINE__, __FILE__, 3); // TODO DELETE | |
$this->view->assign('fahrzeug', $fahrzeugByCat); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment