5 include_once
"Services/Cron/classes/class.ilCronJob.php";
17 return "mem_min_members";
24 return $lng->txt(
"mem_cron_min_members");
31 return $lng->txt(
"mem_cron_min_members_info");
36 return self::SCHEDULE_TYPE_DAILY;
59 $recipients_map =
array();
64 if (
sizeof($recipients_map)) {
65 foreach ($recipients_map as $reci_id => $items) {
70 $message =
sizeof($recipients_map) .
" notifications sent";
82 include_once
"Modules/Course/classes/class.ilObjCourse.php";
84 $too_few = (bool) $item[0];
94 foreach ($item[1] as $reci_id) {
95 $a_recipients_map[$reci_id][] =
array(
"crs", $obj_id, $item[0]);
107 include_once
"Modules/Group/classes/class.ilObjGroup.php";
109 $too_few = (bool) $item[0];
119 foreach ($item[1] as $reci_id) {
120 $a_recipients_map[$reci_id][] =
array(
"grp", $obj_id, $item[0]);
134 include_once
"Services/Link/classes/class.ilLink.php";
135 include_once
"./Services/Notification/classes/class.ilSystemNotification.php";
137 $ntf->setLangModules(
array(
"crs"));
140 $ntf->setReasonLangId(
"mem_cron_min_members_reason");
141 $ntf->setTaskLangId(
"mem_cron_min_members_task");
144 $lng = $ntf->getUserLanguage($a_reci_id);
147 foreach ($a_items as $item) {
148 $obj_type = $item[0];
157 $list = implode($ntf->getBlockBorder(),
$list);
159 $ntf->addAdditionalInfo(
"mem_cron_min_members_intro",
$list,
true);
161 $mail =
new ilMail(ANONYMOUS_USER_ID);
162 $mail->enableSOAP(
false);
167 $lng->txt(
"mem_cron_min_members_subject"),
168 $ntf->composeAndGetMessage($a_reci_id, null,
"read",
true),
static _lookupLogin($a_user_id)
lookup login
if(isset($_REQUEST['delete'])) $list
Cron job application base class.
static _lookupTitle($a_id)
lookup object title
static _getAllReferences($a_id)
get all reference ids of object
Cron for course/group minimum members.
static findGroupsWithNotEnoughMembers()
Minimum members check $ilDB $ilDB.
catch(Exception $e) $message
This class handles base functions for mail handling.
sendMessage($a_reci_id, array $a_items)
Create styles array
The data for the language used.
getDefaultScheduleValue()
static findCoursesWithNotEnoughMembers()
Minimum members check type $ilDB.
Cron job result data container.
getGroups(array &$a_recipients_map)
Wrapper classes for system notifications.
static _getLink($a_ref_id, $a_type='', $a_params=array(), $append="")
getCourses(array &$a_recipients_map)