*
* @var array
*/
- static $_commPrefs = array(
+ public static $_commPrefs = array(
'do_not_phone',
'do_not_email',
'do_not_mail',
*
* @var array
*/
- static $_greetingTypes = array(
+ public static $_greetingTypes = array(
'addressee',
'email_greeting',
'postal_greeting',
*
* @var array
*/
- static $_importableFields = array();
+ public static $_importableFields = array();
/**
* Static field for all the contact information that we can potentially export.
*
* @var array
*/
- static $_exportableFields = NULL;
+ public static $_exportableFields = NULL;
/**
* Class constructor.
if (!empty($params['contact_id']) && !empty($missingGreetingParams)) {
$savedGreetings = civicrm_api3('Contact', 'getsingle', array(
'id' => $params['contact_id'],
- 'return' => array_keys($missingGreetingParams))
+ 'return' => array_keys($missingGreetingParams),
+ )
);
foreach (array_keys($missingGreetingParams) as $missingGreetingParam) {
* True when used during search, might conflict with export param?.
*
* @param bool $withMultiRecord
- *
+ * @param bool $checkPermissions
* @return array
* array of exportable Fields
*/
'Household',
'Organization',
'All',
- )
- )) {
+ ))) {
$fields = array_merge($fields, CRM_Core_OptionValue::getFields('', $contactType));
}
// add current employer for individuals
}
else {
foreach (array(
- 'Individual',
- 'Household',
- 'Organization',
- ) as $type) {
+ 'Individual',
+ 'Household',
+ 'Organization',
+ ) as $type) {
$fields = array_merge($fields,
CRM_Core_BAO_CustomField::getFieldsForImport($type, FALSE, FALSE, $search, $checkPermissions, $withMultiRecord)
);
CRM_Contact_BAO_GroupContact::addContactsToGroup($contactIds, $addToGroupID);
}
- CRM_Contact_BAO_GroupContactCache::opportunisticCacheFlush();
+ // reset the group contact cache for this group
+ // HACK: Dave disabled this on 12/09/2014 due to a crazy amount of lock wait timeouts on cache tables, causing donations to fail.
+ //CRM_Contact_BAO_GroupContactCache::opportunisticCacheFlush();
if ($editHook) {
CRM_Utils_Hook::post('edit', 'Profile', $contactID, $params);
}
}
}
- elseif (in_array($key,
- array(
- 'nick_name',
- 'job_title',
- 'middle_name',
- 'birth_date',
- 'gender_id',
- 'current_employer',
- 'prefix_id',
- 'suffix_id',
- )) &&
- ($value == '' || !isset($value)) &&
- ($session->get('authSrc') & (CRM_Core_Permission::AUTH_SRC_CHECKSUM + CRM_Core_Permission::AUTH_SRC_LOGIN)) == 0 ||
- ($key == 'current_employer' && empty($params['current_employer']))) {
+ elseif (in_array($key, array(
+ 'nick_name',
+ 'job_title',
+ 'middle_name',
+ 'birth_date',
+ 'gender_id',
+ 'current_employer',
+ 'prefix_id',
+ 'suffix_id',
+ )) && ($value == '' || !isset($value)) &&
+ ($session->get('authSrc') & (CRM_Core_Permission::AUTH_SRC_CHECKSUM + CRM_Core_Permission::AUTH_SRC_LOGIN)) == 0 ||
+ ($key == 'current_employer' && empty($params['current_employer']))) {
// CRM-10128: if auth source is not checksum / login && $value is blank, do not fill $data with empty value
// to avoid update with empty values
continue;
array('table' => 'civicrm_im', 'column' => 'contact_id'),
array('table' => 'civicrm_phone', 'column' => 'contact_id'),
array('table' => 'civicrm_website', 'column' => 'contact_id'),
- )
- )
+ ))
->alterTriggerInfo($info, $tableName);
// Update phone table to populate phone_numeric field