/** * add given recurrence to given set and to nessesary adoptions * * @param Calendar_Model_Event $_recurrence * @param Tinebase_Record_RecordSet $_eventSet */ protected static function addRecurrence($_recurrence, $_eventSet) { $_recurrence->setId('fakeid' . $_recurrence->uid . $_recurrence->dtstart->getTimeStamp()); // adjust alarms if ($_recurrence->alarms instanceof Tinebase_Record_RecordSet) { foreach ($_recurrence->alarms as $alarm) { $alarm->alarm_time = clone $_recurrence->dtstart; $alarm->alarm_time->subMinute($alarm->getOption('minutes_before')); } } $_eventSet->addRecord($_recurrence); }