teampage
class teampage implements groupposition_interface
Teampage group position class
Teampage position is an ascending list 1, 2, ..., n for items which are displayed. 1 is the first item, n the last.
Constants
GROUP_DISABLED |
Group is not displayed |
NO_PARENT |
No parent item |
Properties
protected driver_interface | $db | Database object |
|
protected user | $user | User object |
|
protected driver_interface | $cache | Cache object |
Methods
Returns the teampage position for a given group, if the group exists.
Returns the row for a given group, if the group exists.
Returns the teampage position for a given teampage item, if the item exists.
Returns the teampage row for a given teampage item, if the item exists.
Get number of groups displayed
Addes a group by group_id
Adds a group by group_id
Adds a new category
Deletes a group from the list and closes the gap in the position list.
Deletes an item from the list and closes the gap in the position list.
Moves a group up by group_id
Moves an item up by teampage_id
Moves a group down by group_id
Moves an item down by teampage_id
Moves a group up/down
Moves an item up/down
Get group type language var
Details
at line 58
__construct(driver_interface $db, user $user, driver_interface $cache)
Constructor
at line 72
int
get_group_value(int $group_id)
Returns the teampage position for a given group, if the group exists.
at line 100
array
get_group_values(int $group_id)
Returns the row for a given group, if the group exists.
at line 128
int
get_teampage_value(int $teampage_id)
Returns the teampage position for a given teampage item, if the item exists.
at line 153
array
get_teampage_values(int $teampage_id)
Returns the teampage row for a given teampage item, if the item exists.
at line 175
int
get_group_count()
Get number of groups displayed
at line 190
bool
add_group(int $group_id)
Addes a group by group_id
at line 202
bool
add_group_teampage(int $group_id, int $parent_id)
Adds a group by group_id
at line 266
bool
add_category_teampage(string $category_name)
Adds a new category
at line 296
bool
delete_group(int $group_id, bool $skip_group = false)
Deletes a group from the list and closes the gap in the position list.
at line 326
bool
delete_teampage(int $teampage_id, bool $skip_group = false)
Deletes an item from the list and closes the gap in the position list.
at line 355
bool
move_up(int $group_id)
Moves a group up by group_id
at line 366
bool
move_up_teampage(int $teampage_id)
Moves an item up by teampage_id
at line 374
bool
move_down(int $group_id)
Moves a group down by group_id
at line 385
bool
move_down_teampage(int $teampage_id)
Moves an item down by teampage_id
at line 393
bool
move(int $group_id, int $delta)
Moves a group up/down
at line 481
bool
move_teampage(int $teampage_id, int $delta)
Moves an item up/down
at line 581
static string
group_type_language(int $group_type)
Get group type language var