Hierarchy
class Hierarchy
Helper for Data from Sys::Hierarchy
Methods
Get Context ID
evaluate_result
Get current hierarchy position for current user in specific context
Get Default Hierarchy Context
Get Hierarchy
Get a single hierarchy node (uses caching)
Get Subordinates from Context ID You can apply additional filters which will limit the applicable users
Get Superior Users from Context ID You can apply additional filters which will limit the applicable users
Helper for get_superiors
Initialize a hierarchy tree Loads all hierarchy nodes as collection into internal array
Details
at line 56
int
convert_context_id(mixed $short_id)
Get Context ID
at line 252
int[]
evaluate_result(array $superiors_by_level, string $evaluation_method)
evaluate_result
at line 76
Hierarchy
get_current(mixed $context_id = 1, int $user_id = null)
Get current hierarchy position for current user in specific context
at line 41
bool|mixed
get_default_context()
Get Default Hierarchy Context
at line 233
Hierarchy[]|ModelCollection
get_hierarchy(mixed $context_id = 1)
Get Hierarchy
at line 289
Hierarchy
get_hierarchy_node(int $node_id, mixed $context_id = false)
Get a single hierarchy node (uses caching)
at line 184
array
get_subordinates(int $context_id = 1, int $context_filter = null, int $user_id = null, bool $include_hierarchy_level = false)
Get Subordinates from Context ID You can apply additional filters which will limit the applicable users
at line 98
User[][]|ModelCollection[]
get_superiors(int $context_id = 1, int $context_filter = null, int $user_id = null)
Get Superior Users from Context ID You can apply additional filters which will limit the applicable users
at line 152
ModelCollection[]|User[][]
get_users_by_level(mixed $context_id, mixed $user_id, mixed $include_own_level = false, Hierarchy[] $hierarchy_per_level = [])
Helper for get_superiors
at line 28
init_tree(mixed $context_id = 1)
Initialize a hierarchy tree Loads all hierarchy nodes as collection into internal array