mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-08-24 16:43:48 +00:00
Add unaccent function
map the extension unaccent from postgresql
This commit is contained in:
@@ -60,5 +60,16 @@ class ChillMainExtension extends Extension implements PrependExtensionInterface
|
||||
'resources' => array('ChillMainBundle:Form:fields.html.twig'))
|
||||
);
|
||||
$container->prependExtensionConfig('twig', $twigConfig);
|
||||
|
||||
//add DQL function to ORM (default entity_manager)
|
||||
$container->prependExtensionConfig('doctrine', array(
|
||||
'orm' => array(
|
||||
'dql' => array(
|
||||
'string_functions' => array(
|
||||
'unaccent' => 'Chill\MainBundle\Doctrine\DQL\Unaccent'
|
||||
)
|
||||
)
|
||||
)
|
||||
));
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user