package | CONTENIDO Core |
---|---|
subpackage | Permission |
getGroupsForUser(string $userId) : array
string
array
List of group idsgetIDForAction(string | int $action) : int
If passed action is numeric, it will returned directly.
string
int
int
getIDForArea(string | int $area) : int
If passed area is numeric, it will returned directly.
string
int
int
getParentAreaId($area)
hasClientPermission(int $iClient, object $oUser) : bool
int
idclient to check, or false for the current client
object
User object to check against, or false for the current user
bool
have_perm(string $p) : bool
string
Permissions (comma separated list of perms) to check
bool
have_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
string
int
int
bool
isClientAdmin(integer $iClient, object $oUser) : bool
integer
idclient to check
object
User object to check against
bool
isClientGroup(int $iClient, object $oGroup) : bool
int
idclient to check
object
Group object to check against
bool
isClientUser(int $iClient, object $oUser) : bool
int
idclient to check
object
User object to check against
bool
isSysadmin(object $oUser)
object
User 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.
object
User object
\cInvalidArgumentException |
if the given or constructed user is not a cApiUser object |
---|
object
$actioncache : array
$areacache : array
$classname : string
$db : \cDb