2015-03-02 21:57:49 +01:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace Trinity\Bundle\UserBundle\DependencyInjection;
|
|
|
|
|
|
|
|
use Symfony\Component\Config\Definition\Builder\TreeBuilder;
|
|
|
|
use Symfony\Component\Config\Definition\ConfigurationInterface;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* This is the class that validates and merges configuration from your app/config files
|
|
|
|
*
|
|
|
|
* To learn more see {@link http://symfony.com/doc/current/cookbook/bundles/extension.html#cookbook-bundles-extension-config-class}
|
|
|
|
*/
|
|
|
|
class Configuration implements ConfigurationInterface
|
|
|
|
{
|
|
|
|
/**
|
|
|
|
* {@inheritDoc}
|
|
|
|
*/
|
|
|
|
public function getConfigTreeBuilder()
|
|
|
|
{
|
|
|
|
$treeBuilder = new TreeBuilder();
|
|
|
|
$rootNode = $treeBuilder->root('trinity_user');
|
|
|
|
|
|
|
|
$rootNode->children()
|
|
|
|
->scalarNode('bo_auth_role')
|
|
|
|
->defaultValue('ROLE_WEBMASTER')
|
|
|
|
->end()
|
2015-05-04 19:34:46 +02:00
|
|
|
|
|
|
|
->booleanNode('active_when_generate')
|
|
|
|
->defaultValue(false)
|
|
|
|
->end()
|
|
|
|
|
|
|
|
->scalarNode('sender_mail')
|
|
|
|
->defaultValue('noreply@webetdesign.com')
|
|
|
|
->end()
|
|
|
|
->scalarNode('sender_name')
|
|
|
|
->defaultValue('Web&Design')
|
|
|
|
->end()
|
|
|
|
|
2015-03-02 21:57:49 +01:00
|
|
|
->arrayNode('roles')
|
|
|
|
->prototype('scalar')
|
|
|
|
->end()
|
|
|
|
->end()
|
|
|
|
;
|
|
|
|
|
|
|
|
return $treeBuilder;
|
|
|
|
}
|
|
|
|
}
|