ILIAS  release_5-3 Revision v5.3.23-19-g915713cf615
ilContactAppEventListener Class Reference

Class ilContactAppEventListener. More...

+ Inheritance diagram for ilContactAppEventListener:
+ Collaboration diagram for ilContactAppEventListener:

Static Public Member Functions

static handleEvent ($a_component, $a_event, $a_parameter)
 {Handle an event in a listener.
Parameters
string$a_componentcomponent, e.g. "Modules/Forum" or "Services/User"
string$a_eventevent e.g. "createUser", "updateUser", "deleteUser", ...
array$a_parameterparameter array (assoc), array("name" => ..., "phone_office" => ...)
} More...
 
static handleEvent ($a_component, $a_event, $a_parameter)
 Handle an event in a listener. More...
 

Detailed Description

Member Function Documentation

◆ handleEvent()

static ilContactAppEventListener::handleEvent (   $a_component,
  $a_event,
  $a_parameter 
)
static

{Handle an event in a listener.

Parameters
string$a_componentcomponent, e.g. "Modules/Forum" or "Services/User"
string$a_eventevent e.g. "createUser", "updateUser", "deleteUser", ...
array$a_parameterparameter array (assoc), array("name" => ..., "phone_office" => ...)
}

Implements ilAppEventListener.

Definition at line 15 of file class.ilContactAppEventListener.php.

16 {
17 global $DIC;
18
19 if ('Services/User' == $a_component && 'deleteUser' == $a_event) {
20 require_once 'Services/Contact/BuddySystem/classes/class.ilBuddyList.php';
21 ilBuddyList::getInstanceByUserId($a_parameter['usr_id'])->destroy();
22
23 require_once 'Services/Contact/classes/class.ilMailingList.php';
24 ilMailingList::removeAssignmentsByUserId($a_parameter['usr_id']);
25 }
26
27 if ('Services/Contact' == $a_component && 'contactRequested' == $a_event) {
28 $notification = new ilBuddySystemNotification($DIC->user(), $DIC->settings());
29 $notification->setRecipientIds(array($a_parameter['usr_id']));
30 $notification->send();
31 }
32 }
static getInstanceByUserId($usr_id)
global $DIC
Definition: saml.php:7

References $DIC, and ilBuddyList\getInstanceByUserId().

+ Here is the call graph for this function:

The documentation for this class was generated from the following file: