Skip to content
Snippets Groups Projects
Commit cd93d472 authored by Tim Otten's avatar Tim Otten
Browse files

Merge pull request #250 from agh1/group_id-to-id

make group_id be id (after the opposite was done)
parents 79714f84 d64eb977
No related branches found
No related tags found
No related merge requests found
......@@ -97,7 +97,7 @@ function _civicrm_api3_group_create_spec(&$params) {
*/
function civicrm_api3_group_get($params) {
$options = _civicrm_api3_get_options_from_params($params, TRUE, 'get');
$options = _civicrm_api3_get_options_from_params($params, TRUE, 'group', 'get');
$sort = CRM_Utils_Array::value('sort', $options, NULL);
$offset = CRM_Utils_Array::value('offset', $options);
$rowCount = CRM_Utils_Array::value('limit', $options);
......@@ -108,6 +108,9 @@ function civicrm_api3_group_get($params) {
$returnProperties['id'] = 1;
$returnProperties = array_keys($returnProperties);
}
if (CRM_Utils_Array::value('group_id', $inputParams)) {
$inputParams['id'] = $inputParams['group_id'];
}
$groupObjects = CRM_Contact_BAO_Group::getGroups($inputParams, $returnProperties, $sort, $offset, $rowCount);
if (empty($groupObjects)) {
return civicrm_api3_create_success(FALSE);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment