Skip to content

Conversation

@mistacms
Copy link

Milan Stanek - Pridanie strankovania do zoznamu po 9.

@vasekboch vasekboch changed the title Milan Stanek - strankovani seznamu po 9 Ukol 2 - Milan Stanek Oct 16, 2016

$paginator = $this->get('knp_paginator');
$em = $this->getDoctrine()->getManager();
$all = $em->getRepository(Product::class)->findAll();
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tady pozor tohle ti vytáhne celou tabulku do paměti. To není zrovna efektivní. Při pár tisících položek a pár requestech ti umře jakýkoliv server. :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants