|
|
|
@@ -1532,7 +1532,7 @@ class Login
|
|
|
|
$this->acl['page'] = $_SESSION['LOGIN_PAGES_ACL_LEVEL'][$this->page_name];
|
|
|
|
$this->acl['page'] = $_SESSION['LOGIN_PAGES_ACL_LEVEL'][$this->page_name];
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
$this->acl['unit_id'] = null;
|
|
|
|
$this->acl['unit_cuid'] = null;
|
|
|
|
$this->acl['unit_name'] = null;
|
|
|
|
$this->acl['unit_name'] = null;
|
|
|
|
$this->acl['unit_uid'] = null;
|
|
|
|
$this->acl['unit_uid'] = null;
|
|
|
|
$this->acl['unit'] = [];
|
|
|
|
$this->acl['unit'] = [];
|
|
|
|
@@ -3217,7 +3217,7 @@ HTML;
|
|
|
|
* @return int|null same edit access id if ok
|
|
|
|
* @return int|null same edit access id if ok
|
|
|
|
* or the default edit access id
|
|
|
|
* or the default edit access id
|
|
|
|
* if given one is not valid
|
|
|
|
* if given one is not valid
|
|
|
|
* @deprecated Please switch to using edit access cuid check with ->loginCheckEditAccessValidCuid()
|
|
|
|
* @#deprecated Please switch to using edit access cuid check with ->loginCheckEditAccessValidCuid()
|
|
|
|
*/
|
|
|
|
*/
|
|
|
|
public function loginCheckEditAccessId(?int $edit_access_id): ?int
|
|
|
|
public function loginCheckEditAccessId(?int $edit_access_id): ?int
|
|
|
|
{
|
|
|
|
{
|
|
|
|
@@ -3290,10 +3290,24 @@ HTML;
|
|
|
|
*/
|
|
|
|
*/
|
|
|
|
public function loginGetEditAccessCuidFromId(int $id): string|false
|
|
|
|
public function loginGetEditAccessCuidFromId(int $id): string|false
|
|
|
|
{
|
|
|
|
{
|
|
|
|
if (!isset($_SESSION['LOGIN_UNIT_ACL_LEVEL'][$id])) {
|
|
|
|
if (!isset($_SESSION['LOGIN_UNIT_LEGACY'][$id])) {
|
|
|
|
return false;
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
return (string)$_SESSION['LOGIN_UNIT_ACL_LEVEL'][$id]['cuid'];
|
|
|
|
return (string)$_SESSION['LOGIN_UNIT_LEGACY'][$id]['cuid'];
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
|
|
|
* This is a Legacy lookup from the edit access id to cuid for further lookups in the normal list
|
|
|
|
|
|
|
|
*
|
|
|
|
|
|
|
|
* @param string $cuid edit access cuid
|
|
|
|
|
|
|
|
* @return int|false false on not found or edit access id PK
|
|
|
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
public function loginGetEditAccessIdFromCuid(string $cuid): int|false
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
if (!isset($_SESSION['LOGIN_UNIT'][$cuid])) {
|
|
|
|
|
|
|
|
return false;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
return $_SESSION['LOGIN_UNIT'][$cuid]['id'];
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
/**
|
|
|
|
|