mirror of
https://git.code.sf.net/p/seeddms/code
synced 2025-05-09 21:16:07 +00:00
getNotifyList() returns only users which are not disabled
This commit is contained in:
parent
7576bbf298
commit
cb17de44fc
|
@ -967,10 +967,15 @@ class SeedDMS_Core_Document extends SeedDMS_Core_Object { /* {{{ */
|
||||||
$this->_notifyList = array("groups" => array(), "users" => array());
|
$this->_notifyList = array("groups" => array(), "users" => array());
|
||||||
foreach ($resArr as $row)
|
foreach ($resArr as $row)
|
||||||
{
|
{
|
||||||
if ($row["userID"] != -1)
|
if ($row["userID"] != -1) {
|
||||||
array_push($this->_notifyList["users"], $this->_dms->getUser($row["userID"]) );
|
$u = $this->_dms->getUser($row["userID"]);
|
||||||
else //if ($row["groupID"] != -1)
|
if($u && !$u->isDisabled())
|
||||||
array_push($this->_notifyList["groups"], $this->_dms->getGroup($row["groupID"]) );
|
array_push($this->_notifyList["users"], $u);
|
||||||
|
} else { //if ($row["groupID"] != -1)
|
||||||
|
$g = $this->_dms->getGroup($row["groupID"]);
|
||||||
|
if($g)
|
||||||
|
array_push($this->_notifyList["groups"], $g);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return $this->_notifyList;
|
return $this->_notifyList;
|
||||||
|
|
|
@ -1245,10 +1245,15 @@ class SeedDMS_Core_Folder extends SeedDMS_Core_Object {
|
||||||
$this->_notifyList = array("groups" => array(), "users" => array());
|
$this->_notifyList = array("groups" => array(), "users" => array());
|
||||||
foreach ($resArr as $row)
|
foreach ($resArr as $row)
|
||||||
{
|
{
|
||||||
if ($row["userID"] != -1)
|
if ($row["userID"] != -1) {
|
||||||
array_push($this->_notifyList["users"], $this->_dms->getUser($row["userID"]) );
|
$u = $this->_dms->getUser($row["userID"]);
|
||||||
else //if ($row["groupID"] != -1)
|
if($u && !$u->isDisabled())
|
||||||
array_push($this->_notifyList["groups"], $this->_dms->getGroup($row["groupID"]) );
|
array_push($this->_notifyList["users"], $u);
|
||||||
|
} else {//if ($row["groupID"] != -1)
|
||||||
|
$g = $this->_dms->getGroup($row["groupID"]);
|
||||||
|
if($g)
|
||||||
|
array_push($this->_notifyList["groups"], $g);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return $this->_notifyList;
|
return $this->_notifyList;
|
||||||
|
|
Loading…
Reference in New Issue
Block a user