+--------------------------------------------------------------------+
| This file is a part of CiviCRM. |
| |
+--------------------------------------------------------------------+
| This file is a part of CiviCRM. |
| |
return civicrm_api3('contact', 'create', $profileParams);
$ufGroupDetails = array();
return civicrm_api3('contact', 'create', $profileParams);
$ufGroupDetails = array();
$contactIds = array($params['contact_id']);
CRM_Contact_BAO_GroupContact::addContactsToGroup($contactIds,
$ufGroupDetails['add_to_group_id']
$contactIds = array($params['contact_id']);
CRM_Contact_BAO_GroupContact::addContactsToGroup($contactIds,
$ufGroupDetails['add_to_group_id']
*
* Note that that since the existing code for deriving a blank profile is not easily accessible our
* interim solution is just to return an empty array
*
* Note that that since the existing code for deriving a blank profile is not easily accessible our
* interim solution is just to return an empty array
if(isset($profileFields[$profileID][$entityfield])) {
unset($profileFields[$profileID][$entityfield]);
}
if(isset($profileFields[$profileID][$entityfield])) {
unset($profileFields[$profileID][$entityfield]);
}
- // we will make the mixed case version (e.g. of 'Primary') an alias
- $profileFields[$profileID][$fieldName]['api.aliases'][] = $entityfield;
+ if(!in_array($entityfield, $profileFields[$profileID][$fieldName]['api.aliases'])) {
+ // we will make the mixed case version (e.g. of 'Primary') an alias
+ $profileFields[$profileID][$fieldName]['api.aliases'][] = $entityfield;
+ }
function _civicrm_api3_order_by_weight($a, $b) {
return CRM_Utils_Array::value('weight', $b) < CRM_Utils_Array::value('weight', $a) ? TRUE : FALSE;
}
function _civicrm_api3_order_by_weight($a, $b) {
return CRM_Utils_Array::value('weight', $b) < CRM_Utils_Array::value('weight', $a) ? TRUE : FALSE;
}
/**
* Here we map the profile fields as stored in the uf_field table to their 'real entity'
* we also return the profile fieldname
*
/**
* Here we map the profile fields as stored in the uf_field table to their 'real entity'
* we also return the profile fieldname
*
'check_number' => 'contribution',
'contribution_status_id' => 'contribution',
'soft_credit' => 'contribution',
'check_number' => 'contribution',
'contribution_status_id' => 'contribution',
'soft_credit' => 'contribution',