mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-01-07 14:39:56 +01:00
feature to enable to be notified of events you created/modified/deleted yourself; That is most helpful if you get a notification eMail with the ics attached, and thus be able to import the event somewhere else (another EGroupware/Outlook/...)
This commit is contained in:
parent
54cf94c4a5
commit
dd4328a422
@ -642,6 +642,9 @@ class calendar_boupdate extends calendar_bo
|
||||
}
|
||||
}
|
||||
}
|
||||
//$currentPrefs = CreateObject('phpgwapi.preferences',$GLOBALS['egw_info']['user']['account_id']);
|
||||
//$user_prefs = $currentPrefs->read_repository();
|
||||
$user_prefs = $GLOBALS['egw_info']['user']['preferences'];
|
||||
foreach($to_notify as $userid => $statusid)
|
||||
{
|
||||
if ($this->debug > 0) error_log(__METHOD__." trying to notify $userid, with $statusid");
|
||||
@ -656,7 +659,8 @@ class calendar_boupdate extends calendar_bo
|
||||
{
|
||||
continue; // dont notify rejected participants or groups
|
||||
}
|
||||
if($userid != $GLOBALS['egw_info']['user']['account_id'] || $msg_type == MSG_ALARM)
|
||||
|
||||
if($userid != $GLOBALS['egw_info']['user']['account_id'] || $user_prefs['calendar']['receive_own_updates']==1 || $msg_type == MSG_ALARM)
|
||||
{
|
||||
$preferences = CreateObject('phpgwapi.preferences',$userid);
|
||||
$part_prefs = $preferences->read_repository();
|
||||
@ -1513,4 +1517,4 @@ class calendar_boupdate extends calendar_bo
|
||||
}
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -167,7 +167,7 @@ class calendar_hooks
|
||||
'5' => lang('Weekview without weekend'),
|
||||
'7' => lang('Weekview with weekend'),
|
||||
);
|
||||
$mainpage = array(
|
||||
$mainpage = $yesno = array(
|
||||
'1' => lang('Yes'),
|
||||
'0' => lang('No'),
|
||||
);
|
||||
@ -404,6 +404,16 @@ class calendar_hooks
|
||||
'admin' => False,
|
||||
'default'=> 'time_change',
|
||||
),
|
||||
'receive_own_updates' => array(
|
||||
'type' => 'select',
|
||||
'label' => 'Receive notifications about events you created/modified/deleted',
|
||||
'name' => 'receive_own_updates',
|
||||
'values' => $yesno,
|
||||
'help' => "Do you want to be notified about changes of appointments you modified?",
|
||||
'xmlrpc' => True,
|
||||
'admin' => False,
|
||||
'default'=> 'false',
|
||||
),
|
||||
'update_format' => array(
|
||||
'type' => 'select',
|
||||
'label' => 'Format of event updates',
|
||||
|
Loading…
Reference in New Issue
Block a user