jAcl2DbAdminUIManager
in package
Tags
Table of Contents
- FILTER_BY_GROUP = 0
- FILTER_GROUP_ALL_USERS = -2
- FILTER_USERS_NO_IN_GROUP = -1
- addUserToGroup() : mixed
- canRemoveUser() : bool
- getGroupRights() : array<string|int, mixed>
- getGroupRightsWithResources() : array<string|int, mixed>
- getUserRessourceRights() : mixed
- getUserRights() : array<string|int, mixed>
- getUsersList() : array<string|int, mixed>
- removeGroup() : mixed
- delete a group of user.
- removeGroupRightsWithResources() : mixed
- removeUserFromGroup() : mixed
- removeUserRessourceRights() : mixed
- saveGroupRights() : mixed
- Save authorizations for all groups.
- saveUserRights() : mixed
- Save rights of the given user.
- getLabel() : mixed
Constants
FILTER_BY_GROUP
public
mixed
FILTER_BY_GROUP
= 0
FILTER_GROUP_ALL_USERS
public
mixed
FILTER_GROUP_ALL_USERS
= -2
FILTER_USERS_NO_IN_GROUP
public
mixed
FILTER_USERS_NO_IN_GROUP
= -1
Methods
addUserToGroup()
public
addUserToGroup(string $login, string $groupId[, null|string $sessionUser = null ]) : mixed
Parameters
- $login : string
- $groupId : string
- $sessionUser : null|string = null
-
the login name of the user who initiates the change It is mandatory although null is accepted for API compatibility. Null value is deprecated.
Tags
Return values
mixed —canRemoveUser()
public
canRemoveUser(string $login) : bool
Parameters
- $login : string
Return values
bool —true if is safe to remove the user
getGroupRights()
public
getGroupRights() : array<string|int, mixed>
Return values
array<string|int, mixed> —'groups' : list of jacl2group objects (id_aclgrp, name, grouptype, ownerlogin)
'rights' : array(
getGroupRightsWithResources()
public
getGroupRightsWithResources(mixed $groupid) : array<string|int, mixed>
Parameters
- $groupid : mixed
Return values
array<string|int, mixed> —'rightsLabels' : list of labels of each rights
'rightsWithResources': array(
getUserRessourceRights()
public
getUserRessourceRights(mixed $user) : mixed
Parameters
- $user : mixed
Return values
mixed —getUserRights()
public
getUserRights(string $user) : array<string|int, mixed>
Parameters
- $user : string
Tags
Return values
array<string|int, mixed> —getUsersList()
public
getUsersList(int $groupFilter[, null|int $groupId = null ][, string $userFilter = '' ], int $offset[, int $listPageSize = 15 ]) : array<string|int, mixed>
Parameters
- $groupFilter : int
-
one of FILTER_* const
- $groupId : null|int = null
- $userFilter : string = ''
- $offset : int
- $listPageSize : int = 15
Return values
array<string|int, mixed> —'users': list of objects representing users ( login, and his groups in groups) 'usersCount': total number of users
removeGroup()
delete a group of user.
public
removeGroup(string $groupId[, null|string $sessionUser = null ]) : mixed
Parameters
- $groupId : string
-
the id of the group to remove
- $sessionUser : null|string = null
-
the login name of the user who initiate the change It is mandatory although null is accepted for API compatibility. Null value is deprecated.
Tags
Return values
mixed —removeGroupRightsWithResources()
public
removeGroupRightsWithResources(string $groupid, array<string|int, mixed> $rights) : mixed
Parameters
- $groupid : string
- $rights : array<string|int, mixed>
-
array(
=> (true (remove), 'on'(remove) or '' (not touch)) true or 'on' means 'to remove'
Return values
mixed —removeUserFromGroup()
public
removeUserFromGroup(string $login, string $groupId[, null|string $sessionUser = null ]) : mixed
Parameters
- $login : string
-
the login of the user to remove from the given group
- $groupId : string
-
the group name from which the user should be removed
- $sessionUser : null|string = null
-
the login name of the user who initiates the change It is mandatory although null is accepted for API compatibility. Null value is deprecated.
Tags
Return values
mixed —removeUserRessourceRights()
public
removeUserRessourceRights( $user, mixed $rights) : mixed
Parameters
Return values
mixed —saveGroupRights()
Save authorizations for all groups.
public
saveGroupRights(array<string|int, mixed> $rights[, string $sessionUser = null ]) : mixed
Only authorizations on given subjects are changed. Existing authorizations not given in parameters are deleted from the corresponding group (i.e: marked as inherited).
If authorizations of a group are missing, all authorizations for this group are deleted.
Parameters
- $rights : array<string|int, mixed>
-
array(<id_aclgrp> => array( <id_aclsbj> => (bool, 'y', 'n' or '')))
- $sessionUser : string = null
-
the user login who initiates the change. It is mandatory although null is accepted for API compatibility. Null value is deprecated
Tags
Return values
mixed —saveUserRights()
Save rights of the given user.
public
saveUserRights(string $login, array<string|int, mixed> $userRights[, null|string $sessionUser = null ]) : mixed
Only rights on given subjects are changed. Existing rights not given in parameters are deleted from the private group of the user (i.e: marked as inherited).
Rights with resources are not changed.
Parameters
- $login : string
-
the login of the user on who rights will be changed
- $userRights : array<string|int, mixed>
-
list of rights key=subject, value=false(inherit)/''(inherit)/true(add)/'y'(add)/'n'(remove)
- $sessionUser : null|string = null
-
the login name of the user who initiate the change It is mandatory although null is accepted for API compatibility. Null value is deprecated.
Tags
Return values
mixed —getLabel()
protected
getLabel(mixed $id, mixed $labelKey) : mixed
Parameters
- $id : mixed
- $labelKey : mixed