projects
/
civicrm-core.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
493c757
)
CRM-15905 fix - API: problem sorting contacts on ID
author
monishdeb
<monish.deb@webaccessglobal.com>
Tue, 3 Feb 2015 10:15:29 +0000
(15:45 +0530)
committer
monishdeb
<monish.deb@webaccessglobal.com>
Tue, 3 Feb 2015 10:15:29 +0000
(15:45 +0530)
https://issues.civicrm.org/jira/browse/CRM-15905
api/v3/utils.php
patch
|
blob
|
blame
|
history
diff --git
a/api/v3/utils.php
b/api/v3/utils.php
index 6f5f3782b03229872a4e67e71b5583eb385125ca..fc41c821b2c73be523b52b89fd470ab0e4ee4f57 100644
(file)
--- a/
api/v3/utils.php
+++ b/
api/v3/utils.php
@@
-527,6
+527,10
@@
function _civicrm_api3_get_using_query_object($entity, $params, $additional_opti
$returnProperties = NULL;
}
+ if (substr($sort, 0, 2) == 'id') {
+ $sort = $entity . "_" . $sort;
+ }
+
$newParams = CRM_Contact_BAO_Query::convertFormValues($inputParams);
foreach ($newParams as &$newParam) {
if ($newParam[1] == '=' && is_array($newParam[2])) {
@@
-538,7
+542,6
@@
function _civicrm_api3_get_using_query_object($entity, $params, $additional_opti
$newParam[2] = $sqlFilter;
}
}
-
}
$skipPermissions = !empty($params['check_permissions']) ? 0 : 1;