我試圖在我的symfony項目安裝sonataAdminBundle,這裏是我的composer.json文件SonataDoctrineORMAdminExtension.php
上午以下https://sonata-project.org/bundles/admin/2-3/doc/getting_started/installation.html
"sonata-project/admin-bundle": "~2.0",
"sonata-project/doctrine-orm-admin-bundle": "2.2.x-dev"
我把這個在我的appkernel文件
new Sonata\CoreBundle\SonataCoreBundle(),
new Sonata\BlockBundle\SonataBlockBundle(),
new Knp\Bundle\MenuBundle\KnpMenuBundle(),
new Sonata\AdminBundle\SonataAdminBundle(),
new Sonata\DoctrineORMAdminBundle\SonataDoctrineORMAdminBundle(),
在我的config.yml文件中 sonata_block: default_contexts: [cms] blocks: sonata.admin.block.admin_list: contexts: [admin]
我有這個issus
ClassNotFoundException in SonataDoctrineORMAdminExtension.php line 29: Attempted to load class "AbstractSonataAdminExtension" from namespace "Sonata\AdminBundle\DependencyInjection". Did you forget a "use" statement for another namespace?