mirror of
https://git.code.sf.net/p/seeddms/code
synced 2025-02-06 15:14:58 +00:00
sync call of getReadAccessList() with SeedDMS_Core_Document::getReadAccessList()
This commit is contained in:
parent
f02e0ca977
commit
f2c376cadc
|
@ -1778,11 +1778,12 @@ class SeedDMS_Core_Folder extends SeedDMS_Core_Object {
|
|||
* administrators and the owner of the folder unless $listadmin resp.
|
||||
* $listowner is set to true.
|
||||
*
|
||||
* @param bool|int $listadmin if set to true any admin will be listed too
|
||||
* @param bool|int $listowner if set to true the owner will be listed too
|
||||
* @param boolean $listadmin if set to true any admin will be listed too
|
||||
* @param boolean $listowner if set to true the owner will be listed too
|
||||
* @param boolean $listguest if set to true any guest will be listed too
|
||||
* @return array list of users and groups
|
||||
*/
|
||||
function getReadAccessList($listadmin=0, $listowner=0) { /* {{{ */
|
||||
function getReadAccessList($listadmin=0, $listowner=0, $listguest=0) { /* {{{ */
|
||||
$db = $this->_dms->getDB();
|
||||
|
||||
if (!isset($this->_readAccessList)) {
|
||||
|
@ -1817,7 +1818,7 @@ class SeedDMS_Core_Folder extends SeedDMS_Core_Object {
|
|||
$user = $userAccess->getUser();
|
||||
if (!$listadmin && $user->isAdmin()) continue;
|
||||
if (!$listowner && $user->getID() == $this->_ownerID) continue;
|
||||
if ($user->isGuest()) continue;
|
||||
if (!$listguest && $user->isGuest()) continue;
|
||||
$userIDs .= (strlen($userIDs)==0 ? "" : ", ") . $userAccess->getUserID();
|
||||
}
|
||||
|
||||
|
@ -1844,7 +1845,7 @@ class SeedDMS_Core_Folder extends SeedDMS_Core_Object {
|
|||
(strlen($userIDs) == 0 ? "" : " OR (`tblUsers`.`id` IN (". $userIDs ."))").
|
||||
") ORDER BY `login`";
|
||||
}
|
||||
/* If default access is equal or greate then read, $userIDs and
|
||||
/* If default access is equal or greater than M_READ, $userIDs and
|
||||
* $groupIDs contains a list of user without read access
|
||||
*/
|
||||
else {
|
||||
|
|
Loading…
Reference in New Issue
Block a user