From 4771089b18e0da43fe7837d1f7925a2576b4dc9f Mon Sep 17 00:00:00 2001 From: Eileen McNaughton Date: Mon, 15 Sep 2014 16:28:07 +1200 Subject: [PATCH] CRM-15299 fix caseType behaviour on getcount --- api/v3/CaseType.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/api/v3/CaseType.php b/api/v3/CaseType.php index 654f20ce1a..521b0d6472 100644 --- a/api/v3/CaseType.php +++ b/api/v3/CaseType.php @@ -76,9 +76,10 @@ function civicrm_api3_case_type_create($params) { * @access public */ function civicrm_api3_case_type_get($params) { - civicrm_api3_verify_mandatory($params); + if (!empty($params['options']) && !empty($params['options']['is_count'])) { + return _civicrm_api3_basic_get(_civicrm_api3_get_BAO(__FUNCTION__), $params); + } $caseTypes = _civicrm_api3_basic_get(_civicrm_api3_get_BAO(__FUNCTION__), $params); - // format case type, to fetch xml definition return _civicrm_api3_case_type_get_formatResult($caseTypes); } -- 2.25.1