Cascader"
From Documentation
Line 19: | Line 19: | ||
Arrays.asList(new DefaultTreeNode[]{ | Arrays.asList(new DefaultTreeNode[]{ | ||
new DefaultTreeNode("David", Arrays.asList(new TreeNode[]{new DefaultTreeNode("David-1"), | new DefaultTreeNode("David", Arrays.asList(new TreeNode[]{new DefaultTreeNode("David-1"), | ||
− | new DefaultTreeNode("David-2")})), new DefaultTreeNode("Thomas",new ArrayList()), | + | new DefaultTreeNode("David-2")})), |
+ | new DefaultTreeNode("Thomas",new ArrayList()), | ||
new DefaultTreeNode("Steven",new ArrayList())}))); | new DefaultTreeNode("Steven",new ArrayList())}))); | ||
]]></zscript> | ]]></zscript> |
Revision as of 09:54, 12 November 2019
Cascader
Employment/Purpose
Cascader is a tree-based selectbox.
Example
<source lang="xml" >
<zscript><![CDATA[
DefaultTreeModel tm = new DefaultTreeModel(new DefaultTreeNode("ROOT",
Arrays.asList(new DefaultTreeNode[]{
new DefaultTreeNode("David", Arrays.asList(new TreeNode[]{new DefaultTreeNode("David-1"),
new DefaultTreeNode("David-2")})),
new DefaultTreeNode("Thomas",new ArrayList()),
new DefaultTreeNode("Steven",new ArrayList())})));
]]></zscript>
<cascader width="300px" model="${tm}" />
Users can select in layers, and the selection path would be converted into text. (Default is joining by slashes, i.g. "A/B/C")
Properties
Model
Placeholder
Open
Renderer
ItemConverter
Supported Events
Event: SelectEvent
Represents an event caused by user's the selection changed at the client. | |
Event: OpenEvent
Represents an event that indicates an open state that is changed at the client. |
- Inherited Supported Events: HtmlBasedComponent
Supported Children
* None
Use Cases
Version | Description | Example Location |
---|---|---|
Version History
Version | Date | Content |
---|---|---|
9.0.0 | November, 2019 | Anchornav was introduced. |