- Модуль: calendar
- Путь к файлу: ~/bitrix/modules/calendar/lib/sync/icloud/eventbuilder.php
- Класс: BitrixCalendarSyncIcloudEventBuilder
- Вызов: EventBuilder::prepareReminders
private function prepareReminders(Event $event): array
{
$result = [];
/** @var Remind $remind */
foreach ($event->getRemindCollection()->getCollection() as $remind)
{
[$value, $valueType] = $this->prepareReminderValue(
$remind,
$event->isFullDayEvent()
);
if (!$value || !$valueType)
{
continue;
}
$uuId = VendorSyncService::generateUuid();
$result[] = [
'X-WR-ALARMUID' => $uuId,
'UID' => $uuId,
'TYPE' => 'VALARM',
'ACTION' => 'DISPLAY',
'TRIGGER' => [
'PARAMETERS' => ['VALUE' => $valueType],
'VALUE' => $value,
],
];
}
return $result;
}