$contactType = array('Individual', 'Household', 'Organization');
foreach ($contactType as $value) {
- $contactFields = CRM_Contact_BAO_Contact::exportableFields($value, FALSE, $required);
+ if ($mappingType == 'Search Builder') {
+ // get multiple custom group fields in this context
+ $contactFields = CRM_Contact_BAO_Contact::exportableFields($value, FALSE, $required, FALSE, TRUE);
+ } else {
+ $contactFields = CRM_Contact_BAO_Contact::exportableFields($value, FALSE, $required);
+ }
$contactFields = array_merge($contactFields, CRM_Contact_BAO_Query_Hook::singleton()->getFields());
// exclude the address options disabled in the Address Settings