projects
/
civicrm-core.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge pull request #3837 from eileenmcnaughton/CRM-15113
[civicrm-core.git]
/
CRM
/
Core
/
DAO.php
diff --git
a/CRM/Core/DAO.php
b/CRM/Core/DAO.php
index fbd2f6c468f7177e5b3ab8784833ffd0aad32d9a..9dea4c8676c42c669c29ef1ff6012a5e55c7a365 100644
(file)
--- a/
CRM/Core/DAO.php
+++ b/
CRM/Core/DAO.php
@@
-196,6
+196,7
@@
class CRM_Core_DAO extends DB_DataObject {
*/
function initialize() {
$this->_connect();
*/
function initialize() {
$this->_connect();
+ $this->query("SET NAMES utf8");
}
/**
}
/**
@@
-1264,6
+1265,11
@@
SELECT contact_id
$numObjects = 1,
$createOnly = FALSE
) {
$numObjects = 1,
$createOnly = FALSE
) {
+ //this is a test function also backtrace is set for the test suite it sometimes unsets itself
+ // so we re-set here in case
+ $config = CRM_Core_Config::singleton();
+ $config->backtrace = TRUE;
+
static $counter = 0;
CRM_Core_DAO::$_testEntitiesToSkip = array(
'CRM_Core_DAO_Worldregion',
static $counter = 0;
CRM_Core_DAO::$_testEntitiesToSkip = array(
'CRM_Core_DAO_Worldregion',
@@
-1427,8
+1433,12
@@
SELECT contact_id
static function deleteTestObjects($daoName, $params = array(
)) {
static function deleteTestObjects($daoName, $params = array(
)) {
+ //this is a test function also backtrace is set for the test suite it sometimes unsets itself
+ // so we re-set here in case
+ $config = CRM_Core_Config::singleton();
+ $config->backtrace = TRUE;
- $object = new $daoName
(
);
+ $object = new $daoName
(
);
$object->id = CRM_Utils_Array::value('id', $params);
$deletions = array(); // array(array(0 => $daoName, 1 => $daoParams))
$object->id = CRM_Utils_Array::value('id', $params);
$deletions = array(); // array(array(0 => $daoName, 1 => $daoParams))
@@
-1955,4
+1965,6
@@
EOS;
return substr($string, 0, $length - 8) . "_{$md5string}";
}
return substr($string, 0, $length - 8) . "_{$md5string}";
}
+ function setApiFilter(&$params) {}
+
}
}