[TYPO3-mvc] widget.paginate only working with repository standard methods?
Kevin Ulrich Moschallski
km at 3digit.de
Thu Jan 13 18:07:33 CET 2011
Hi Jochen,
you are in the widget controller context?
Try to make an instance of your repository and then call createQuery()
on the instance.
/**
* @var Tx_Yourext_Domain_Repository_YourRepository
*/
protected $articleRepository;
public function initializeAction() {
$this->yourRepository =
t3lib_div::makeInstance('Tx_Yourext_Domain_Repository_YourRepository');
}
$this->yourRepository->createQuery()
Regards,
Kevin
On 2011-01-13 17:03:56 +0100, Jochen Rieger said:
> Hi all,
>
> I'm currently checking the paginate widget which comes with the fluid
> trunk. A very nice tool as stated before already.
>
> But how does it work exactly? It seems as if it would perform some kind
> of findAll() action itself in the background.
>
> I am trying to use it on a manually composed query and it does not work
> properly.
>
> Is the following not supported by it?
>
> $query = $this->createQuery();
> $query->statement ($myManuallyComposedSql);
> return $query->execute();
>
> Regards,
> Jochen
More information about the TYPO3-project-typo3v4mvc
mailing list