Details
-
Type: Bug
-
Status: Done/Fixed
-
Priority: Trivial
-
Resolution: Cannot Reproduce
-
Affects Version/s: 2.2.8
-
Fix Version/s: 3.0
-
Component/s: CiviCRM API
-
Labels:None
Description
We use Drupal 6 + CiviCRM 2.2.8 + custom code. We did not modify Drupal or CiviCRM tables. We did not make mo
civicrm_contact_get() returned all the values of custom fields provided in the parameters.
We add or remove a field in any custom data using CiviCRM admin tool without any other modifications.... civicrm_contact_get() (v2) does not return any custom data fields.
We did the following to solve the problem and it's working:
CRM_Contact_BAO_Query::apiQuery():
foreach ($returnProperties as $key=>$value)
{ $fields[$key] = array($key); } $query =& new CRM_Contact_BAO_Query( $params, $returnProperties,
$fields, true, false, 1,
false, true, $smartGroupCache );
Just pass $fields to the constructor.
The extended class is attached.
It would be useful to allow more parameters for API functions.