TreeViewModel
Interface representing the TreeView class.
Properties
allowDragAndDrop Boolean
Specifies whether the tree view nodes can be dragged and dropped.
Default: false
allowEditing Boolean
Specifies whether the tree view nodes can be edited or not.
Default: false
allowMultiSelect Boolean
Specifies whether only one node can be selected at once or to allow multiple to be selected.
Default: false
allowTextWrap Boolean
Specifies whether to allow text wrapping on the tree view nodes.
Default: false
animation NodeAnimationSettingsModel
Specifies the animation effects that will be applied to expanding and collapsing nodes.
Default: {expand: { effect: 'SlideDown', duration: 400, easing: 'linear' }, collapse: { effect: 'SlideUp', duration: 400, easing: 'linear' }}
autoCheck Boolean
Specifies whether parent nodes should be automatically checked when a child node gets checked.
Default: true
checkedNodes String[]
Specifies a list of node ids that are checked in the tree view.
Default: []
cssClass String
Specifies CSS classes to customize the appearance of the control.
Default: ""
disabled Boolean
Specifies whether the control is enabled or disabled, disabled will prevent user interaction.
Default: false
dragArea String HTMLElement
Specifies the target area in which a draggable element can be dragged and dropped.
Default: null
enableHtmlSanitizer Boolean
Specifies whether to allow the rendering of untrusted HTML and JavaScript values withing the control. When true, any untrusted strings or scripts will be remote before rendering.
Default: true
enableRtl Boolean
Specifies whether to render the control in right to left direction.
Default: false
enableState Boolean
Specifies whether to persist the state of the control between page loads.
- expandedNodes
- checkedNodes
- selectedNodes
Default: false
expandedNodes String[]
Specifies a list of node ids that are expanded on the tree view.
Default: []
expandOn ExpandOnSettings
Specifies the action on which the node will expand or collapse.
Default: Auto
fullRowNavigable Boolean
Specifies whether the entire node can be used for navigation or just the node's text element.
Default: false
fullRowSelect Boolean
Specifies whether the entire node will be selected of just the node's text element.
Default: true
items NodeItemSettingsModel
Specifies the field mappings between data store and the tree view nodes.
Default: {id: 'id', text: 'text', dataStore: [], child: 'child', parentID: 'parentID', hasChildren: 'hasChildren', expanded: 'expanded', htmlAttributes: 'htmlAttributes', iconCss: 'iconCss', imageUrl: 'imageUrl', isChecked: 'isChecked', query: null, selected: 'selected', tableName: null, tooltip: 'tooltip', navigateUrl: 'navigateUrl'}
loadOnDemand Boolean
Specifies whether the use lazy loading, nodes are only rendered when expanded. If false, all nodes will be rendered on load.
Default: true
locale String
Specifies the culture and localization value for this control, overriding the globally defined value.
Default: en-US
nodeTemplate Function
Specifies a template to be used to customize the rendering a tree view node.
Default: ''
selectedNodes String[]
Specifies a list of node ids that are selected on the tree view.
Default: []
showCheckbox Boolean
Specifies whether the checkbox should appear for selection in the tree view node.
Default: true
sortOrder SortOrder
Specifies the sort order for the nodes.
Default: None
Events
actionFailure EmitType<FailureEventArgs>
Event callback that is raised when a failure occurs on retrieving data from the data store.
created EmitType<CreatedEventArgs>
Event callback that is raised when the control has been created.
dataBound EmitType<DataBoundEventArgs>
Event callback that is raised when data is loaded into the tree view.
dataStoreChanged EmitType<DataStoreChangedEventArgs>
Event callback that is raised when the data store is changed. For example, after editing, adding and removing nodes.
destroyed EmitType<Object>
Event callback that is raised when the control has been destroyed.
drawNode EmitType<DrawNodeEventArgs>
Event callback that is raised before a node is appended to the control.
keyPress EmitType<NodeKeyPressEventArgs>
Event callback that is raised when key press occurs.
nodeChecked EmitType<NodeCheckEventArgs>
Event callback that is raised when a node is checked or unchecked.
nodeChecking EmitType<NodeCheckEventArgs>
Event callback that is raised before a node is checked or unchecked.
nodeClicked EmitType<NodeClickEventArgs>
Event callback that is raised when a node is clicked.
nodeCollapsed EmitType<NodeExpandCollapseEventArgs>
Event callback that is raised when a node is collapsed.
nodeCollapsing EmitType<NodeExpandCollapseEventArgs>
Event callback that is raised before a node is collapsed.
nodeDragging EmitType<DragAndDropEventArgs>
Event callback that is raised while a node is being dragged.
nodeDragStart EmitType<DragAndDropEventArgs>
Event callback that is raised when a node starts to be dragged.
nodeDragStop EmitType<DragAndDropEventArgs>
Event callback that is raised when a node has stopped dragging.
nodeDropped EmitType<DragAndDropEventArgs>
Event callback that is raised when a node has been dropped on the target element.
nodeEdited EmitType<NodeEditEventArgs>
Event callback that is raised when a node has been edited.
nodeEditing EmitType<NodeEditEventArgs>
Event callback that is raised before a node is edited.
nodeExpanded EmitType<NodeExpandCollapseEventArgs>
Event callback that is raised when a node is expanded.
nodeExpanding EmitType<NodeExpandCollapseEventArgs>
Event callback that is raised before a node is expanded.
nodeSelected EmitType<NodeSelectEventArgs>
Event callback that is raised when a node is selected.
nodeSelecting EmitType<NodeSelectEventArgs>
Event callback that is raised before a node is selected.