4 include_once
'./Services/Mail/classes/class.ilMailNotification.php';
41 self::TYPE_NOTIFICATION_REGISTRATION,
42 self::TYPE_NOTIFICATION_REGISTRATION_REQUEST,
43 self::TYPE_NOTIFICATION_UNSUBSCRIBE
54 parent::__construct();
63 $this->force_sending_mail = $a_status;
74 in_array($this->
getType(), array(self::TYPE_ADMISSION_MEMBER))) {
77 if ($obj->getAutoNotification() ==
false) {
78 if (!$this->force_sending_mail) {
92 case self::TYPE_ADMISSION_MEMBER:
109 $this->
getMail()->appendInstallationSignature(
true);
111 $this->
sendMail(array($rcp), array(
'system'));
116 case self::TYPE_ACCEPTED_SUBSCRIPTION_MEMBER:
133 $this->
getMail()->appendInstallationSignature(
true);
135 $this->
sendMail(array($rcp), array(
'system'));
139 case self::TYPE_REFUSED_SUBSCRIPTION_MEMBER:
153 $this->
getMail()->appendInstallationSignature(
true);
155 $this->
sendMail(array($rcp), array(
'system'));
159 case self::TYPE_STATUS_CHANGED:
180 $this->
getMail()->appendInstallationSignature(
true);
182 $this->
sendMail(array($rcp), array(
'system'));
187 case self::TYPE_DISMISS_MEMBER:
200 $this->
getMail()->appendInstallationSignature(
true);
201 $this->
sendMail(array($rcp), array(
'system'));
206 case self::TYPE_BLOCKED_MEMBER:
219 $this->
getMail()->appendInstallationSignature(
true);
220 $this->
sendMail(array($rcp), array(
'system'));
224 case self::TYPE_UNBLOCKED_MEMBER:
242 $this->
getMail()->appendInstallationSignature(
true);
244 $this->
sendMail(array($rcp), array(
'system'));
248 case self::TYPE_NOTIFICATION_REGISTRATION:
275 $this->
getMail()->appendInstallationSignature(
true);
276 $this->
sendMail(array($rcp), array(
'system'));
280 case self::TYPE_NOTIFICATION_REGISTRATION_REQUEST:
307 $this->
getMail()->appendInstallationSignature(
true);
308 $this->
sendMail(array($rcp), array(
'system'));
312 case self::TYPE_NOTIFICATION_UNSUBSCRIBE:
339 $this->
getMail()->appendInstallationSignature(
true);
340 $this->
sendMail(array($rcp), array(
'system'));
344 case self::TYPE_UNSUBSCRIBE_MEMBER:
358 $this->
getMail()->appendInstallationSignature(
true);
359 $this->
sendMail(array($rcp), array(
'system'));
363 case self::TYPE_SUBSCRIBE_MEMBER:
381 $this->
getMail()->appendInstallationSignature(
true);
383 $this->
sendMail(array($rcp), array(
'system'));
387 case self::TYPE_WAITING_LIST_MEMBER:
406 $this->
getMail()->appendInstallationSignature(
true);
407 $this->
sendMail(array($rcp), array(
'system'));
421 parent::initLanguage($a_usr_id);
438 if ($part->isAdmin($a_usr_id)) {
440 } elseif ($part->isTutor($a_usr_id)) {
446 if ($part->isAdmin($a_usr_id)
or $part->isTutor($a_usr_id)) {
449 if ($part->isNotificationEnabled($a_usr_id)) {
457 if ($part->isBlocked($a_usr_id)) {
466 if ($part->hasPassed($a_usr_id)) {
488 $this->force_sending_mail ||
489 $ilSetting->get(
'mail_crs_member_notification',
true) ||
490 in_array(
$a_type, $this->permanent_enabled_notifications);
getType()
Get notification type.
const TYPE_NOTIFICATION_UNSUBSCRIBE
const TYPE_ADMISSION_MEMBER
const TYPE_STATUS_CHANGED
const TYPE_BLOCKED_MEMBER
const TYPE_ACCEPTED_SUBSCRIPTION_MEMBER
const TYPE_WAITING_LIST_MEMBER
const TYPE_DISMISS_MEMBER
const TYPE_REFUSED_SUBSCRIPTION_MEMBER
getLanguageText($a_keyword)
const TYPE_NOTIFICATION_REGISTRATION_REQUEST
static _getInstanceByObjId($a_obj_id)
Get singleton instance.
const TYPE_UNBLOCKED_MEMBER
forceSendingMail($a_status)
Force sending mail independent from global setting.
initLanguage($a_usr_id)
Add language module crs.
getAdditionalInformation()
Base class for course/group mail notifications.
getObjectTitle($a_shorten=false)
createCourseStatus($a_usr_id)
Get course status body.
const TYPE_NOTIFICATION_REGISTRATION
sendMail(array $a_rcp, $a_type, $a_parse_recipients=true)
getRecipients()
get array of recipients
createPermanentLink($a_params=array(), $a_append='')
send()
Send notifications.
isNotificationTypeEnabled($a_type)
get setting "mail_crs_member_notification" and excludes types which are not affected by this setting ...
appendBody($a_body)
Append body text.
static getInstanceByRefId($a_ref_id, $stop_on_error=true)
get an instance of an Ilias object by reference id
$permanent_enabled_notifications
Notifications which are not affected by "mail_crs_member_notification" setting because they addresses...
const TYPE_UNSUBSCRIBE_MEMBER
const TYPE_SUBSCRIBE_MEMBER
static getSalutation($a_usr_id, ilLanguage $a_language=null)