我正在升级 symfony 3.1 中的一个旧应用程序,它在左侧的“验证”面板之后缺少表单面板(它是唯一缺少的面板)。我认为升级到最新的 3.4.x(目前是 3.4.18)可以解决这个问题。我什至删除了整个供应商树并从作曲家安装,但我没有让它出现在网络分析器上,尽管我看到了“新”绿色条和版本。
任何新项目或我自己创建的都有它,所以我认为它与我的安装无关。我什至比较了 composer.json 以试图找出可能缺少的内容,但我找不到任何有用的东西。.../view/Collectors/form.html.twig 文件就在那里。
这是我的 AppKernel.php:
use Symfony\Component\HttpKernel\Kernel;
use Symfony\Component\Config\Loader\LoaderInterface;
class AppKernel extends Kernel
{
public function __construct($environment, $debug)
{
date_default_timezone_set('Europe/Paris');
parent::__construct($environment, $debug);
}
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 Knp\Bundle\PaginatorBundle\KnpPaginatorBundle(),
new Vich\UploaderBundle\VichUploaderBundle(),
new Liip\ImagineBundle\LiipImagineBundle(),
new Ikadoc\KCFinderBundle\IkadocKCFinderBundle(),
new Core23\DompdfBundle\Core23DompdfBundle(),
new AppBundle\AppBundle(),
];
if (in_array($this->getEnvironment(), ['dev', 'test'], true)) {
$bundles[] = new Doctrine\Bundle\FixturesBundle\DoctrineFixturesBundle();
$bundles[] = new Symfony\Bundle\DebugBundle\DebugBundle();
$bundles[] = new Symfony\Bundle\WebProfilerBundle\WebProfilerBundle();
$bundles[] = new Sensio\Bundle\DistributionBundle\SensioDistributionBundle();
$bundles[] = new Sensio\Bundle\GeneratorBundle\SensioGeneratorBundle();
$bundles[] = new Symfony\Bundle\WebServerBundle\WebServerBundle();
}
return $bundles;
}
public function getRootDir()
{
return __DIR__;
}
public function getCacheDir()
{
return dirname(__DIR__).'/var/cache/'.$this->getEnvironment();
}
public function getLogDir()
{
return dirname(__DIR__).'/var/logs';
}
public function registerContainerConfiguration(LoaderInterface $loader)
{
$loader->load($this->getRootDir().'/config/config_'.$this->getEnvironment().'.yml');
}
}
我错过了什么?