Ejemplo n.º 1
0
 /**
  * @param Analyzer $analyzer
  *   The case being analyzed -- to which we want to add an activity.
  * @param \SimpleXMLElement $actXML the <ActivityType> tag which describes the new activity
  */
 public function createActivity(Analyzer $analyzer, \SimpleXMLElement $actXML)
 {
     $params = array('activity_type_id' => (string) $actXML->name, 'status_id' => 'Scheduled', 'activity_date_time' => \CRM_Utils_Time::getTime('YmdHis'), 'case_id' => $analyzer->getCaseId());
     $r = civicrm_api3('Activity', 'create', $params);
     $analyzer->flush();
 }