amis2/docs/zh-CN/components/form/treeselect.md
吴多益 c8c4b6efa3
文档文字小调整;统一删掉 schema 中的高度设置;修复 tinymce 弹窗可能被遮挡问题 (#1336)
* 文档优化

* 文档细节调整,删除示例的 height 设置,使用自动撑开

* sdk 使用完整例子,因为新版没发布

* 修复官网语言不正确问题

* 增加 icon 调整颜色及大小的例子

* 修复文字错误

* 补充 each 的文档

* 修复 zh-CN 大写问题
2021-01-07 23:35:03 +08:00

1.2 KiB
Executable File

title description type group menuName icon order
TreeSelect 树形选择器 0 null TreeSelect 树形选择器 60

基本使用

{
  "type": "form",
  "api": "https://houtai.baidu.com/api/mock2/form/saveForm",
  "controls": [
    {
      "type": "tree-select",
      "name": "tree",
      "label": "Tree",
      "options": [
        {
          "label": "Folder A",
          "value": 1,
          "children": [
            {
              "label": "file A",
              "value": 2
            },
            {
              "label": "file B",
              "value": 3
            }
          ]
        },
        {
          "label": "file C",
          "value": 4
        },
        {
          "label": "file D",
          "value": 5
        },
        {
          "label": "Folder E",
          "children": [
            {
              "label": "Folder G",
              "children": [
                {
                  "label": "file H",
                  "value": 6
                },
                {
                  "label": "file I",
                  "value": 7
                }
              ]
            }
          ]
        }
      ]
    }
  ]
}

更多用法,见 Tree