processConfiguration($configuration, $configs); $container->setParameter('cl_chill_person.search.use_double_metaphone', $config['search']['use_double_metaphone']); $loader = new Loader\YamlFileLoader($container, new FileLocator(__DIR__.'/../Resources/config')); $loader->load('services.yml'); } private function declarePersonAsCustomizable (ContainerBuilder $container) { $bundles = $container->getParameter('kernel.bundles'); if (!isset($bundles['ChillCustomFieldsBundle'])) { throw new MissingBundleException('ChillCustomFieldsBundle'); } $container->prependExtensionConfig('chill_custom_fields', array('customizables_entities' => array( array('class' => 'Chill\PersonBundle\Entity\Person', 'name' => 'PersonEntity') ) ) ); } public function prepend(ContainerBuilder $container) { $this->prependRoleHierarchy($container); $bundles = $container->getParameter('kernel.bundles'); //add ChillMain to assetic-enabled bundles if (!isset($bundles['AsseticBundle'])) { throw new MissingBundleException('AsseticBundle'); } $asseticConfig = $container->getExtensionConfig('assetic'); $asseticConfig['bundles'][] = 'ChillPersonBundle'; $container->prependExtensionConfig('assetic', array('bundles' => array('ChillPersonBundle'))); $this-> declarePersonAsCustomizable($container); //declare routes for person bundle $container->prependExtensionConfig('chill_main', array( 'routing' => array( 'resources' => array( '@ChillPersonBundle/Resources/config/routing.yml' ) ) )); } protected function prependRoleHierarchy(ContainerBuilder $container) { $container->prependExtensionConfig('security', array( 'role_hierarchy' => array( 'CHILL_PERSON_UPDATE' => array('CHILL_PERSON_SEE'), 'CHILL_PERSON_CREATE' => array('CHILL_PERSON_SEE') ) )); } }