【发布时间】:2017-07-10 17:02:57
【问题描述】:
我刚刚使用 symfony 3.4 创建了一个新项目并生成了一个包,来自包生成的消息说一切都很好,然后我只需运行 clear cache 命令就可以开始工作它会显示此错误消息
php.exe C:\wamp64\www\bunead\bin\console 缓存:清除 致命错误:在第 19 行的 C:\wamp64\www\bunead\app\AppKernel.php 中找不到类 'AnnuaireBundle\AnnuaireBundle'
这是我的 Appkernel.php
class AppKernel extends Kernel
{
public function registerBundles()
{
$bundles = [
new Symfony\Bundle\FrameworkBundle\FrameworkBundle(),
new Symfony\Bundle\SecurityBundle\SecurityBundle(),
new Symfony\Bundle\TwigBundle\TwigBundle(),
new Symfony\Bundle\MonologBundle\MonologBundle(),
new Symfony\Bundle\SwiftmailerBundle\SwiftmailerBundle(),
new Doctrine\Bundle\DoctrineBundle\DoctrineBundle(),
new Sensio\Bundle\FrameworkExtraBundle\SensioFrameworkExtraBundle(),
new AppBundle\AppBundle(),
new AnnuaireBundle\AnnuaireBundle(),
];
【问题讨论】: