AppKernel.php 2.3KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. <?php
  2. use Symfony\Component\HttpKernel\Kernel;
  3. use Symfony\Component\Config\Loader\LoaderInterface;
  4. class AppKernel extends Kernel
  5. {
  6. public function registerBundles()
  7. {
  8. $bundles = array(
  9. new Symfony\Bundle\FrameworkBundle\FrameworkBundle(),
  10. new Symfony\Bundle\SecurityBundle\SecurityBundle(),
  11. new Symfony\Bundle\TwigBundle\TwigBundle(),
  12. new Symfony\Bundle\MonologBundle\MonologBundle(),
  13. new Symfony\Bundle\SwiftmailerBundle\SwiftmailerBundle(),
  14. new Symfony\Bundle\DoctrineBundle\DoctrineBundle(),
  15. new Symfony\Bundle\AsseticBundle\AsseticBundle(),
  16. new Sensio\Bundle\FrameworkExtraBundle\SensioFrameworkExtraBundle(),
  17. new JMS\SecurityExtraBundle\JMSSecurityExtraBundle(),
  18. new FOS\UserBundle\FOSUserBundle(),
  19. new Symfony\Bundle\DoctrineFixturesBundle\DoctrineFixturesBundle(),
  20. new Stof\DoctrineExtensionsBundle\StofDoctrineExtensionsBundle(),
  21. new Sonata\jQueryBundle\SonatajQueryBundle(),
  22. new Sonata\BluePrintBundle\SonataBluePrintBundle(),
  23. new Sonata\AdminBundle\SonataAdminBundle(),
  24. new Knp\Bundle\MenuBundle\KnpMenuBundle(),
  25. new Muzich\CoreBundle\MuzichCoreBundle(),
  26. new Muzich\UserBundle\MuzichUserBundle(),
  27. new Muzich\IndexBundle\MuzichIndexBundle(),
  28. new Muzich\HomeBundle\MuzichHomeBundle(),
  29. new Muzich\MynetworkBundle\MuzichMynetworkBundle(),
  30. new Muzich\AdminBundle\MuzichAdminBundle(),
  31. new Muzich\GroupBundle\MuzichGroupBundle(),
  32. new Muzich\FavoriteBundle\MuzichFavoriteBundle(),
  33. new Muzich\CommentBundle\MuzichCommentBundle(),
  34. );
  35. if (in_array($this->getEnvironment(), array('dev', 'test'))) {
  36. $bundles[] = new Acme\DemoBundle\AcmeDemoBundle();
  37. $bundles[] = new Symfony\Bundle\WebProfilerBundle\WebProfilerBundle();
  38. $bundles[] = new Sensio\Bundle\DistributionBundle\SensioDistributionBundle();
  39. $bundles[] = new Sensio\Bundle\GeneratorBundle\SensioGeneratorBundle();
  40. }
  41. return $bundles;
  42. }
  43. public function registerContainerConfiguration(LoaderInterface $loader)
  44. {
  45. $loader->load(__DIR__.'/config/config_'.$this->getEnvironment().'.yml');
  46. }
  47. }