From d56831777fba7abcc6574d112236f4d9e3d3166b Mon Sep 17 00:00:00 2001 From: Thomas Metois Date: Mon, 5 Dec 2016 17:35:09 +0100 Subject: [PATCH] Add DoctrineExtensions for more Mysql functions --- composer.json | 3 ++- config/autoload/global.php | 9 +++++++-- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/composer.json b/composer.json index cd5a27d..2b5a7e4 100644 --- a/composer.json +++ b/composer.json @@ -15,7 +15,8 @@ "robmorgan/phinx": "0.5.*", "monarc/core": "dev-master", "monarc/frontoffice": "dev-master", - "phing/phing": "~2.0" + "phing/phing": "~2.0", + "beberlei/DoctrineExtensions": "^1.0" }, "config": { "bin-dir": "bin/" diff --git a/config/autoload/global.php b/config/autoload/global.php index e8fc108..44caa2e 100644 --- a/config/autoload/global.php +++ b/config/autoload/global.php @@ -74,6 +74,7 @@ return array( 'configuration' => 'orm_cli', ), ), + // https://github.com/beberlei/DoctrineExtensions/blob/master/config/mysql.yml 'configuration' => array( 'orm_default' => array( 'metadata_cache' => 'mycache', @@ -85,7 +86,9 @@ return array( 'proxy_namespace' => 'DoctrineORMModule\Proxy', 'filters' => array(), 'datetime_functions' => array(), - 'string_functions' => array(), + 'string_functions' => array( + 'greatest' => 'DoctrineExtensions\Query\Mysql\Greatest', + ), 'numeric_functions' => array(), 'second_level_cache' => array(), ), @@ -99,7 +102,9 @@ return array( 'proxy_namespace' => 'DoctrineORMModule\Proxy', 'filters' => array(), 'datetime_functions' => array(), - 'string_functions' => array(), + 'string_functions' => array( + 'greatest' => 'DoctrineExtensions\Query\Mysql\Greatest', + ), 'numeric_functions' => array(), 'second_level_cache' => array(), ),