Answer the question
In order to leave comments, you need to log in
Double query in doctrine + phalcon?
Hello, it was required for the project to use phalcon framework and doctrine. I didn’t work much with either one, so I decided to take a ready-made skeleton application. Googled and found https://github.com/imuneer/phalcon-doctrine. I started it, everything is fine, but in the controller there is an action index with the following code:
$em = $this->di['entityManager'];
$c = new Customer();
$c->setLabel("Customer - " . rand());
$em->persist($c);
$em->flush();
$customers = $em->getRepository('Models\Customer')->findAll();
$this->view->customers = $customers;
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question