// If contact list has changed, households will probably be at the end of
// the list. Sort it again by sort_name.
if (implode(',', $this->_contactIds) != $relID) {
- $contact_sort = array();
$result = civicrm_api3('Contact', 'get', array(
'return' => array('id'),
'id' => array('IN' => $this->_contactIds),
$searchParams = $this->controller->exportValues();
if ($searchParams['radio_ts'] == 'ts_sel') {
// Create a static group.
-
$randID = md5(time() . rand(1, 1000)); // groups require a unique name
$grpTitle = "Hidden Group {$randID}";
$grpID = CRM_Core_DAO::getFieldValue('CRM_Contact_DAO_Group', $grpTitle, 'id', 'title');
'title' => $newGroupTitle,
'group_type' => array('2' => 1),
);
- $group = CRM_Contact_BAO_Group::create($groupParams);
+ CRM_Contact_BAO_Group::create($groupParams);
}
// note at this point its a static group
}
else {
// Create a smart group.
-
$ssId = $this->get('ssID');
$hiddenSmartParams = array(
'group_type' => array('2' => 1),