You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello, I tried to extend product repository like documented in sylius website I also tried to copy files from this repository, because I see the code differs a bit from the code in documentation. But in any case I get this error 'Cannot autowire service "App\Doctrine\ORM\ProductRepository": argument "$entityManager" of method "Sylius\Bundle\CoreBundle\Doctrine\ORM\ProductRepository::__construct()" references class "Doctrine\ORM\EntityManager" but no such service exists. Try changing the type-hint to one of its parents: interface "Doctrine\ORM\EntityManagerInterface", or interface "Doctrine\Common\Persistence\ObjectManager".'
The text was updated successfully, but these errors were encountered:
In order to use your repository you need to configure it in the config/packages/_sylius.yaml. As you can see in the _sylius.yaml you already have a basic configuration, now you just need to add your repository and override resourceRepository
Hello, I tried to extend product repository like documented in sylius website I also tried to copy files from this repository, because I see the code differs a bit from the code in documentation. But in any case I get this error 'Cannot autowire service "App\Doctrine\ORM\ProductRepository": argument "$entityManager" of method "Sylius\Bundle\CoreBundle\Doctrine\ORM\ProductRepository::__construct()" references class "Doctrine\ORM\EntityManager" but no such service exists. Try changing the type-hint to one of its parents: interface "Doctrine\ORM\EntityManagerInterface", or interface "Doctrine\Common\Persistence\ObjectManager".'
The text was updated successfully, but these errors were encountered: