rbac\ManagerInterface getRolesByUser()

getRolesByUser() public abstract method

Returns the roles that are assigned to the user via assign().

Note that child roles that are not assigned directly to the user will not be returned.

public abstract yii\rbac\Role[] getRolesByUser ( $userId )
$userId string|integer

The user ID (see yii\web\User::$id)

return yii\rbac\Role[]

All roles directly assigned to the user. The array is indexed by the role names.

doc_Yii
2016-10-30 17:10:13
Comments
Leave a Comment

Please login to continue.