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 #1923 from civicrm/4.3
[civicrm-core.git]
/
api
/
v3
/
ReportTemplate.php
diff --git
a/api/v3/ReportTemplate.php
b/api/v3/ReportTemplate.php
index 84cb499a259e50e034b8c03f9c455c35cf890dbe..5129dec72816081eac65eb36622d6b7113002655 100644
(file)
--- a/
api/v3/ReportTemplate.php
+++ b/
api/v3/ReportTemplate.php
@@
-39,7
+39,8
@@
function civicrm_api3_report_template_create($params) {
'CRM_Core_DAO_OptionGroup', 'report_template', 'id', 'name'
);
if (!empty($params['component_id']) && !is_numeric($params['component_id'])) {
'CRM_Core_DAO_OptionGroup', 'report_template', 'id', 'name'
);
if (!empty($params['component_id']) && !is_numeric($params['component_id'])) {
- $params['component_id'] = array_search($params['component_id'], CRM_Core_PseudoConstant::component());
+ $components = CRM_Core_PseudoConstant::get('CRM_Core_DAO_OptionValue', 'component_id', array('onlyActive' => FALSE, 'labelColumn' => 'name'));
+ $params['component_id'] = array_search($params['component_id'], $components);
}
return civicrm_api3_option_value_create($params);
}
}
return civicrm_api3_option_value_create($params);
}