3 declare(strict_types=1);
37 $this->
lng = $DIC->language();
38 $this->tree = $DIC->repositoryTree();
39 $this->objDefinition = $DIC[
'objDefinition'];
40 $this->
lng->loadLanguageModule(
'sysc');
50 return $this->
lng->txt(
'sysc_cron_empty_trash');
55 return $this->
lng->txt(
'sysc_cron_empty_trash_desc');
60 return CronJobScheduleType::SCHEDULE_TYPE_WEEKLY;
66 CronJobScheduleType::SCHEDULE_TYPE_DAILY,
67 CronJobScheduleType::SCHEDULE_TYPE_WEEKLY,
68 CronJobScheduleType::SCHEDULE_TYPE_MONTHLY,
69 CronJobScheduleType::SCHEDULE_TYPE_QUARTERLY,
96 $this->
lng->loadLanguageModule(
'sysc');
102 $num->allowDecimals(
false);
103 $num->setInfo($this->
lng->txt(
'purge_count_limit_desc'));
105 $num->setMinValue(1);
106 $num->setValue(
$settings->get(
'num',
''));
110 $age->allowDecimals(
false);
111 $age->setInfo($this->
lng->txt(
'purge_age_limit_desc'));
113 $age->setMinValue(1);
114 $age->setMaxLength(4);
117 $age->setValue(
$settings->get(
'age',
''));
124 $sub_objects = $this->tree->lookupTrashedObjectTypes();
128 foreach ($sub_objects as $obj_type) {
129 if (!$this->objDefinition->isRBACObject($obj_type) || !$this->objDefinition->isAllowedInRepository($obj_type)) {
132 $options[$obj_type] = $this->
lng->txt(
'obj_' . $obj_type);
135 $types->setOptions($options);
136 $types->setValue(
$settings->get(
'types',
''));
144 if ((
string) $a_form->
getInput(
'number') ===
'') {
150 if ((
string) $a_form->
getInput(
'age') ===
'') {
156 if ($a_form->
getInput(
'types') ===
'') {
172 $trash->setNumberLimit((
int)
$settings->get(
'num',
'0'));
173 $trash->setTypesLimit(array_filter([
$settings->get(
'types',
'')]));
179 $trash->setAgeLimit($date);
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
ilObjectDefinition $objDefinition
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
saveCustomSettings(ilPropertyFormGUI $a_form)
parses the objects.xml it handles the xml-description of all ilias objects
getDefaultScheduleValue()
addCustomSettingsToForm(ilPropertyFormGUI $a_form)