diff --git a/src/Controller/IndexController.php b/src/Controller/IndexController.php index 0eb1cbf..f175a53 100644 --- a/src/Controller/IndexController.php +++ b/src/Controller/IndexController.php @@ -2,9 +2,7 @@ namespace App\Controller; -use App\Entity\MerParaSub; use App\Repository\MerParaSubRepository; -use Doctrine\ORM\EntityManager; use Symfony\Bundle\FrameworkBundle\Controller\AbstractController; use Symfony\Component\HttpFoundation\Response; use Symfony\Component\Routing\Annotation\Route; @@ -15,8 +13,8 @@ class IndexController extends AbstractController #[Route('/', name: 'app_index')] public function index(Entity1Repository $repo, MerParaSubRepository $subRepo): Response { + // repo dummy $sm = $repo->getSchemaManager(); - $entity8 = $repo->findOneByName('entity 8'); $sub = $subRepo->findOne(); dump($sub); @@ -24,7 +22,6 @@ class IndexController extends AbstractController return $this->render('index/index.html.twig', [ 'controller_name' => 'IndexController', - 'entity8' => $entity8, 'schemaManager' => $sm ]); } diff --git a/src/DataFixtures/MerFixtures.php b/src/DataFixtures/MerFixtures.php index a85e58d..fd9fd20 100644 --- a/src/DataFixtures/MerFixtures.php +++ b/src/DataFixtures/MerFixtures.php @@ -37,6 +37,10 @@ class MerFixtures extends Fixture $sub->setService($tmp)->setRedCode('redcode1')->setSubDate(new \DateTimeImmutable('now')); $manager->persist($sub); + $sub = new MerParaSub(); + $sub->setService($tmp)->setRedCode('redcode2')->setSubDate(new \DateTimeImmutable('now')); + $manager->persist($sub); + $manager->flush(); } }