19 declare(strict_types=1);
34 $this->
lng = $DIC->language();
35 $this->
logger = $DIC->logger()->cal();
41 return 'cal_remote_reader';
46 $this->
lng->loadLanguageModule(
'dateplaner');
47 return $this->
lng->txt(
'cal_cronjob_remote_title');
52 $this->
lng->loadLanguageModule(
'dateplaner');
53 return $this->
lng->txt(
'cal_cronjob_remote_description');
70 $a_fields[
'cal_webcal_sync'] = $a_is_active ?
71 $this->
lng->txt(
'enabled') :
72 $this->
lng->txt(
'disabled');
84 return self::SCHEDULE_TYPE_IN_HOURS;
89 if ($this->calendar_settings === null) {
90 return self::DEFAULT_SYNC_HOURS;
92 return $this->calendar_settings->getWebCalSyncHours();
104 $reader->
setUser($remoteCalendar->getRemoteUser());
105 $reader->setPass($remoteCalendar->getRemotePass());
108 $reader->import($remoteCalendar);
110 $this->
logger->warning(
'Remote Calendar: ' . $remoteCalendar->getCategoryID());
111 $this->
logger->warning(
'Reading remote calendar failed with message: ' . $e->getMessage());
114 $remoteCalendar->update();
119 $result->setStatus($status);
getDefaultScheduleValue()
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
ilCalendarSettings $calendar_settings
static lookupRemoteCalendars()
addToExternalSettingsForm(int $a_form_id, array &$a_fields, bool $a_is_active)