AND value is not NULL');
CRM_Core_DAO::executeQuery('DELETE FROM civicrm_setting WHERE name = "activity_tab_filter"');
-
+ $date = CRM_Utils_Time::getTime('Y-m-d H:i:s');
CRM_Core_DAO::executeQuery('ALTER TABLE civicrm_setting ADD UNIQUE INDEX index_domain_contact_name (domain_id, contact_id, name)');
- CRM_Core_DAO::executeQuery('INSERT INTO civicrm_setting (name, contact_id, domain_id, value, is_domain, created_id, created_date)
- SELECT name, contact_id, domain_id, value, 0, contact_id, %1
+ CRM_Core_DAO::executeQuery("INSERT INTO civicrm_setting (name, contact_id, domain_id, value, is_domain, created_id, created_date)
+ SELECT name, contact_id, domain_id, value, 0, contact_id,'$date'
FROM civicrm_activity_setting
- WHERE name = "activity_tab_filter"
- AND value is not NULL', array(
- 1 => CRM_Utils_Time::getTime('Y-m-d H:i:s'),
+ WHERE name = 'activity_tab_filter'
+ AND value is not NULL"
);
CRM_Core_DAO::executeQuery('DROP TABLE civicrm_activity_setting');