26 $this->user_id = $a_user_id;
36 $this->ref_id = $a_val;
57 if (!isset(self::$instances[$a_user_id]))
62 return self::$instances[$a_user_id];
72 include_once(
"./Services/Awareness/classes/class.ilAwarenessData.php");
75 $data->setFilter($a_filter);
76 return $data->getData();
86 include_once(
"./Services/Awareness/classes/class.ilAwarenessData.php");
89 return $data->getUserCounter();
100 if (!$awrn_set->get(
"use_osd",
true))
109 $d =
$data->getOnlineUserData($ts);
111 $new_online_users =
array();
115 $uname =
"[".$u->login.
"]";
116 if ($u->public_profile)
118 $uname =
"<a href='./goto.php?target=usr_".$u->id.
"'>".$u->lastname.
", ".$u->firstname.
" ".$uname.
"</a>";
120 if (!in_array($u->id, $no_ids))
122 $new_online_users[] = $uname;
127 if (count($new_online_users) == 0)
132 $lng->loadLanguageModule(
'mail');
134 include_once(
"./Services/Object/classes/class.ilObjectFactory.php");
137 'online_user_names' => implode(
"<br />", $new_online_users)
140 require_once
'Services/Notifications/classes/class.ilNotificationConfig.php';
142 $notification->setTitleVar(
'awareness_now_online', $bodyParams,
'awrn');
143 $notification->setShortDescriptionVar(
'awareness_now_online_users', $bodyParams,
'awrn');
144 $notification->setLongDescriptionVar(
'', $bodyParams,
'');
145 $notification->setAutoDisable(
false);
147 $notification->setIconPath(
'templates/default/images/icon_usr.svg');
155 $notification->notifyByUsers(
array($this->user_id));
static getInstance($a_user_id)
Get instance (for a user)
static get($a_var)
Get a value.
static set($a_var, $a_val)
Set a value.
for($col=0; $col< 50; $col++) $d
Describes a notification and provides methods for publishing this notification.
date( 'd-M-Y', $objPHPExcel->getProperties() ->getCreated())
Create styles array
The data for the language used.
High level business class, interface to front ends.
getAwarenessUserCounter()
Get awareness data.
static getInstance($a_user_id)
Get instance (for a user)
Add data(end) time
Method that wraps PHPs time in order to allow simulations with the workflow.
setRefId($a_val)
Set ref id.
__construct($a_user_id)
Constructor.
notifyOnNewOnlineContacts()
Send OSD notification on new users.
getAwarenessData($a_filter)
Get awareness data.