actually set owner notified user, not the logged in user, check if notified user has access on document not currently logged in user.

This commit is contained in:
Uwe Steinmann 2020-08-25 15:53:29 +02:00
parent 27d22771d7
commit e3dea1073c

View File

@ -123,11 +123,11 @@ class SeedDMS_Controller_AddDocument extends SeedDMS_Controller_Common {
/* Add a default notification for the owner of the document */
if($settings->_enableOwnerNotification) {
$res = $document->addNotify($user->getID(), true);
$res = $document->addNotify($owner->getID(), true);
}
/* Check if additional notification shall be added */
foreach($notificationusers as $notuser) {
if($document->getAccessMode($user) >= M_READ)
if($document->getAccessMode($notuser) >= M_READ)
$res = $document->addNotify($notuser->getID(), true);
}
foreach($notificationgroups as $notgroup) {