对于一个客户我几乎完成了一个项目,在Symfony 2.8中构建。客户要求我添加一些额外的CMS功能,这样他就可以自己做一些基本的页面编辑,比如添加/编辑页面和菜单。
我不熟悉Symfony CMF,但正如我所知,只需安装SimpleCmsBundle即可。正如文档所声称的那样,它应该很容易安装,但我仍然会收到错误。以下是我采取的步骤:
将包添加到composer并在de kernel中实例化bundle。就像在http://symfony.com/doc/current/cmf/bundles/simple_cms/introduction.html#installation所说的一样。
正在运行composer update
会产生以下错误:
- doctrine/phpcr-bundle 1.3.4 requires phpcr/phpcr-implementation 2.1.* -> no matching package found.
- doctrine/phpcr-bundle 1.3.3 requires phpcr/phpcr-implementation 2.1.* -> no matching package found.
- doctrine/phpcr-bundle 1.3.2 requires phpcr/phpcr-implementation 2.1.* -> no matching package found.
- doctrine/phpcr-bundle 1.3.1 requires phpcr/phpcr-implementation 2.1.* -> no matching package found.
- doctrine/phpcr-bundle 1.3.0 requires phpcr/phpcr-implementation 2.1.* -> no matching package found.
- doctrine/phpcr-bundle 1.2.4 requires phpcr/phpcr-implementation 2.1.* -> no matching package found.
- doctrine/phpcr-bundle 1.2.3 requires phpcr/phpcr-implementation 2.1.* -> no matching package found.
- doctrine/phpcr-bundle 1.2.2 requires phpcr/phpcr-implementation 2.1.* -> no matching package found.
- doctrine/phpcr-bundle 1.2.1 requires phpcr/phpcr-implementation 2.1.* -> no matching package found.
- doctrine/phpcr-bundle 1.2.0 requires phpcr/phpcr-implementation 2.1.* -> no matching package found.
- doctrine/phpcr-bundle 1.1.2 requires phpcr/phpcr-implementation 2.1.* -> no matching package found.
- doctrine/phpcr-bundle 1.1.1 requires phpcr/phpcr-implementation 2.1.* -> no matching package found.
- doctrine/phpcr-bundle 1.1.0 requires phpcr/phpcr-implementation 2.1.* -> no matching package found.
- symfony-cmf/simple-cms-bundle 1.3.0 requires doctrine/phpcr-bundle ~1.1 -> satisfiable by doctrine/phpcr-bundle[1.1.0, 1.1.1, 1.1.2, 1.2.0, 1.2.1, 1.2.2, 1.2.3, 1.2.4, 1.3.0, 1.3.1, 1.3.2, 1.3.3, 1.3.4].
- Installation request for symfony-cmf/simple-cms-bundle 1.3.0 -> satisfiable by symfony-cmf/simple-cms-bundle[1.3.0].
经过一番搜索,我发现我错过了一个PHPCR实现:https://github.com/symfony-cmf/simple-cms-bundle/issues/142。所以我安装了jackalope/jackalope-doctrine-dbal
现在运行composer update
会产生:
You have requested a non-existent parameter "Could not determine the Doctrine manager. Either Doctrine is not configured or a bundle is misconfigured.".
现在我被卡住了,因为这个错误几乎没有给我谷歌的结果。显然,我是唯一一个遇到此错误的人。我做错了什么?