projects
/
civicrm-core.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
civicrm_api3_create_error, api/v3/Generic/Update - Remove unnecessary indirection
[civicrm-core.git]
/
api
/
v3
/
Generic
/
Getlist.php
diff --git
a/api/v3/Generic/Getlist.php
b/api/v3/Generic/Getlist.php
index 779c4c0738b614a6b9d30b76e385112082e2554c..6cc49431286e687e37e202dc85122487536d2e8a 100644
(file)
--- a/
api/v3/Generic/Getlist.php
+++ b/
api/v3/Generic/Getlist.php
@@
-53,9
+53,9
@@
function civicrm_api3_generic_getList($apiRequest) {
$output = array('page_num' => $request['page_num']);
// Limit is set for searching but not fetching by id
$output = array('page_num' => $request['page_num']);
// Limit is set for searching but not fetching by id
- if (!empty($request['params']['limit'])) {
+ if (!empty($request['params']['
options']['
limit'])) {
// If we have an extra result then this is not the last page
// If we have an extra result then this is not the last page
- $last = $request['params']['limit'] - 1;
+ $last = $request['params']['
options']['
limit'] - 1;
$output['more_results'] = isset($values[$last]);
unset($values[$last]);
}
$output['more_results'] = isset($values[$last]);
unset($values[$last]);
}
@@
-117,7
+117,7
@@
function _civicrm_api3_generic_getList_defaults($entity, &$request) {
$request['id'] = explode(',', $request['id']);
}
// Don't run into search limits when prefilling selection
$request['id'] = explode(',', $request['id']);
}
// Don't run into search limits when prefilling selection
- unset($params['
limit'], $params['offset'], $request['params']['limit'], $request['param
s']['offset']);
+ unset($params['
options']['limit'], $params['options']['offset'], $request['params']['options']['limit'], $request['params']['option
s']['offset']);
$params[$request['id_field']] = is_array($request['id']) ? array('IN' => $request['id']) : $request['id'];
}
$request['params'] += $params;
$params[$request['id_field']] = is_array($request['id']) ? array('IN' => $request['id']) : $request['id'];
}
$request['params'] += $params;