[TYPO3-mvc] Problems with widget.paginate ViewHelper
Franz Koch
typo3.RemoveForMessage at elements-net.de
Fri Sep 9 10:05:23 CEST 2011
Hey,
> $repository = new Tx_Myextension_Domain_Repository_CollectionRepository();
> $query = $repository->createQuey();
> $query->matching(...);
> $this->view->assign('collection', $query->execute());
>
> This should work (AFAK findByFoo() returns $query->execute(), too)?
well, yes, it would work, but it's not a clean code. Keep the query
stuff inside the repository and create a special findByWhatever method
with as many arguments you need to perform the query.
--
kind regards,
Franz Koch
More information about the TYPO3-project-typo3v4mvc
mailing list