嘿
我在Symfony2管理面板生成中遇到问题,我的Symfony版本是2.5,这是我在安装 Sonata管理包时遇到的问题
Problem 1 - Installation request for symfony-cmf/standard-edition 1.1.x-dev -> satisfi able by symfony-cmf/standard-edition[1.1.x-dev]. - symfony-cmf/standard-edition 1.1.x-dev requires sonata-project/doctrine-ph pcr-admin-bundle 1.1.* -> no matching package found. Potential causes: -A typo in the package name -The package is not available in a stable-enough version according to your min imum-stability setting
我搜索了它,得到了一些东西要读,但没有什么可以帮助。可能是什么问题,什么是最合适的解决方案。已经6天了,我被管理面板生成困住了。我正在关注官方文件,
Backend - Sonata Admin,它的第一个语句将我引导到this,在此之后我得到了这些错误。对不起,对于很长的故事,伙计们,但我很无奈。
亲切地回答,用简单的词语解释我真正的解决方案是什么:)
请为sonata-project / admin-bundle要求提供版本约束:
我尝试了dev-master和dev两者,没有任何帮助。
您的帮助将不胜感激:)
这里是composer.json
{
"name": "symfony-cmf/standard-edition",
"homepage": "http://cmf.symfony.com",
"license": "MIT",
"type": "project",
"description": "The \"Symfony CMF Standard Edition\" distribution",
"authors": [
{
"name": "Symfony CMF Community",
"homepage": "https://github.com/symfony-cmf/standard-edition/contributors"
}
],
"autoload": {
"psr-0": { "": "src/" }
},
"minimum-stability": "dev",
"require": {
"php": ">=5.3.3",
"symfony/symfony": "2.3.*",
"jackalope/jackalope-doctrine-dbal": "1.1.*",
"doctrine/doctrine-bundle": "1.2.*",
"doctrine/data-fixtures": "1.0.*",
"doctrine/doctrine-cache-bundle": "1.0.*",
"twig/extensions": "1.0.*",
"symfony/assetic-bundle": "2.3.*",
"symfony/swiftmailer-bundle": "2.3.*",
"symfony/monolog-bundle": "2.3.*",
"symfony-cmf/symfony-cmf": "1.2.*",
"symfony-cmf/simple-cms-bundle": "1.2.*",
"symfony-cmf/create-bundle": "1.2.*",
"sensio/distribution-bundle": "2.3.*",
"sensio/framework-extra-bundle": "2.3.*",
"sensio/generator-bundle": "2.3.*",
"incenteev/composer-parameter-handler": "~2.0",
"sonata-project/doctrine-phpcr-admin-bundle": "1.1.*",
"nelmio/alice": "1.*",
"sonata-project/admin-bundle": "2.2.*@dev"
},
"require-dev": {
"liip/functional-test-bundle": "1.0.*"
},
"scripts": {
"post-install-cmd": [
"Incenteev\\ParameterHandler\\ScriptHandler::buildParameters",
"Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::buildBootstrap",
"Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::clearCache",
"Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::installAssets",
"Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::installRequirementsFile",
"Symfony\\Cmf\\Bundle\\CreateBundle\\Composer\\ScriptHandler::downloadCreateAndCkeditor"
],
"post-update-cmd": [
"Incenteev\\ParameterHandler\\ScriptHandler::buildParameters",
"Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::buildBootstrap",
"Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::clearCache",
"Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::installAssets",
"Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::installRequirementsFile",
"Symfony\\Cmf\\Bundle\\CreateBundle\\Composer\\ScriptHandler::downloadCreateAndCkeditor"
]
},
"config": {
"bin-dir": "bin"
},
"extra": {
"symfony-app-dir": "app",
"symfony-web-dir": "web",
"incenteev-parameters": {
"file": "app/config/parameters.yml"
},
"branch-alias": {
"dev-master": "1.1-dev"
}
}
}
答案 0 :(得分:1)
我希望您按照官方Sonata管理站点上的安装说明进行操作:http://sonata-project.org/bundles/admin/2-2/doc/reference/installation.html
将此添加到composer.json: " sonata-project / admin-bundle":" 2.3。* @ dev"