CheckList extends CompositeTreeItem
Class CheckList
Table of Contents
Methods
- __construct() : mixed
- CheckList constructor.
- add() : mixed
- addAttachments() : mixed
- Adds attachments to checklist.
- addMembers() : mixed
- Adds members to checklist.
- checkFields() : Result
- Checks checklist data fields.
- copy() : CheckList
- Returns new item copied from current item.
- findById() : CheckList|null
- Finds and returns checklist with given id if it is a part of current checklist subtree (or root itself), otherwise returns null.
- findChild() : $this|TreeItem|null
- getAction() : array<string|int, mixed>
- getDescendants() : array<string|int, mixed>
- getDescendantsCount() : int
- getFields() : array<string|int, mixed>
- Returns checklist fields.
- getNodeId() : mixed
- getParent() : mixed
- getSkipMembers() : bool
- isComposite() : bool
- remove() : mixed
- removeAttachments() : mixed
- Removes attachments from checklist.
- removeMembers() : mixed
- Removes members from checklist.
- save() : Result
- Saves checklist and it's whole subtree.
- setFields() : mixed
- Sets new values to checklist fields.
- setNodeId() : mixed
- setParent() : mixed
- setSkipMembers() : void
- toItemsArray() : array<string|int, mixed>
- Transforms current item object tree structure to array of items.
- toTreeArray() : array<string|int, mixed>
- Transforms current item object tree structure to array tree structure.
Methods
__construct()
CheckList constructor.
public
__construct(mixed $nodeId, int $userId, CheckListFacade|string $facade[, array<string|int, mixed> $fields = [] ]) : mixed
Parameters
- $nodeId : mixed
- $userId : int
- $facade : CheckListFacade|string
- $fields : array<string|int, mixed> = []
Tags
add()
public
add(TreeItem $item) : mixed
Parameters
- $item : TreeItem
addAttachments()
Adds attachments to checklist.
public
addAttachments(mixed $filesIds) : mixed
Parameters
- $filesIds : mixed
addMembers()
Adds members to checklist.
public
addMembers(mixed $members) : mixed
Parameters
- $members : mixed
checkFields()
Checks checklist data fields.
public
checkFields() : Result
Return values
Resultcopy()
Returns new item copied from current item.
public
copy() : CheckList
Tags
Return values
CheckListfindById()
Finds and returns checklist with given id if it is a part of current checklist subtree (or root itself), otherwise returns null.
public
findById(mixed $id) : CheckList|null
Parameters
- $id : mixed
Return values
CheckList|nullfindChild()
public
findChild(mixed $nodeId) : $this|TreeItem|null
Parameters
- $nodeId : mixed
Return values
$this|TreeItem|nullgetAction()
public
getAction() : array<string|int, mixed>
Return values
array<string|int, mixed>getDescendants()
public
getDescendants() : array<string|int, mixed>
Return values
array<string|int, mixed>getDescendantsCount()
public
getDescendantsCount() : int
Return values
intgetFields()
Returns checklist fields.
public
getFields() : array<string|int, mixed>
Return values
array<string|int, mixed>getNodeId()
public
getNodeId() : mixed
getParent()
public
getParent() : mixed
getSkipMembers()
public
getSkipMembers() : bool
Return values
boolisComposite()
public
isComposite() : bool
Return values
boolremove()
public
remove(TreeItem $item) : mixed
Parameters
- $item : TreeItem
removeAttachments()
Removes attachments from checklist.
public
removeAttachments(mixed $attachmentsIds) : mixed
Parameters
- $attachmentsIds : mixed
removeMembers()
Removes members from checklist.
public
removeMembers(mixed $membersIds) : mixed
Parameters
- $membersIds : mixed
save()
Saves checklist and it's whole subtree.
public
save() : Result
Updates existing item's fields or adds new item if ID is not set.
Tags
Return values
ResultsetFields()
Sets new values to checklist fields.
public
setFields(mixed $data) : mixed
Parameters
- $data : mixed
setNodeId()
public
setNodeId(mixed $nodeId) : mixed
Parameters
- $nodeId : mixed
setParent()
public
setParent(TreeItem $parent) : mixed
Parameters
- $parent : TreeItem
setSkipMembers()
public
setSkipMembers() : void
toItemsArray()
Transforms current item object tree structure to array of items.
public
toItemsArray() : array<string|int, mixed>
Return values
array<string|int, mixed>toTreeArray()
Transforms current item object tree structure to array tree structure.
public
toTreeArray() : array<string|int, mixed>