| package | CONTENIDO Core |
|---|---|
| subpackage | Permission |
getGroupsForUser(string $userId) : array
string
arrayList of group idsgetIDForAction(string | int $action) : int
If passed action is numeric, it will returned directly.
stringint
intgetIDForArea(string | int $area) : int
If passed area is numeric, it will returned directly.
stringint
intgetParentAreaId($area)
hasClientPermission(int $iClient, object $oUser) : bool
intidclient to check, or false for the current client
objectUser object to check against, or false for the current user
boolhave_perm(string $p) : bool
stringPermissions (comma separated list of perms) to check
boolhave_perm_area_action($area, $action)
have_perm_area_action_anyitem($area, $action)
have_perm_area_action_item($area, $action, $itemid)
have_perm_client($p)
have_perm_client_lang($client, $lang)
have_perm_item(string | int $mainarea, int $itemid) : bool
stringint
int
boolisClientAdmin(integer $iClient, object $oUser) : bool
integeridclient to check
objectUser object to check against
boolisClientGroup(int $iClient, object $oGroup) : bool
intidclient to check
objectGroup object to check against
boolisClientUser(int $iClient, object $oUser) : bool
intidclient to check
objectUser object to check against
boolisSysadmin(object $oUser)
objectUser object to check against
showareas($mainarea)
_checkUserObject(object $oUser) : object
If oUser is false, initialize the object from the currently logged in user. If oUser is not an object of the class cApiUser, throw an exception.
objectUser object
\cInvalidArgumentException |
if the given or constructed user is not a cApiUser object |
|---|
object$actioncache : array
$areacache : array
$classname : string
$db : \cDb