Pregunta

I've searched all the manuals for the answer, but can not find it at all.

I'm trying to apply the CMF to my existing Symfony 2 project using this doc: http://symfony.com/doc/master/cmf/tutorials/creating_cms_using_cmf_and_sonata.html

Then, I've got the Tree problems explained here: http://symfony.com/doc/master/cmf/tutorials/creating_cms_using_cmf_and_sonata.html#tree-problems

And I tried to fill some fixtures using PHPCR like it explained here: http://symfony.com/doc/master/cmf/tutorials/using_blockbundle_and_contentbundle.html#using-the-phpcr

But I had no luck at all with this strange red-backgrounded error:

The class 'Symfony\Cmf\Bundle\BlockBundle\Doctrine\Phpcr\SimpleBlock' was not found in the chain configured namespaces Doctrine\ODM\PHPCR\Document, Symfony\Component\Routing, Symfony\Cmf\Bundle\RoutingBundle\Model, Symfony\Cmf\Bundle\RoutingBundle\Doctrine\Phpcr, Symfony\Cmf\Bundle\MenuBundle\Model, Symfony\Cmf\Bundle\MenuBundle\Doctrine\Phpcr

What does it mean and how to heal this strange behaviour?

Also, does anybody have a good explanation or tutorials how to use this great Symfony-CMF things?

¿Fue útil?

Solución

This error looks like you did not activate any storage layer for the CmfBlockBundle. Do you have something like

cmf_block:
    persistence:
        phpcr:
            enabled: true

If you also use the CmfCoreBundle, it is enough to have it enabled there, as the CmfCoreBundle prepends this configuration to all cmf bundles.

cmf_core:
    persistence:
        phpcr:
            enabled: true
Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top