>[danger] 友情提示:构建器目前只支持HisiPHP Pro版本([我要升级](https://www.hisiphp.com/authorize.html)) ## 树形组件(tree) | 参数 | 类型 | 必须 | 默认 | 说明 | --- | --- | --- | --- | --- | | type | string | Y | | 固定值:tree | | name | string | Y | | 字段名称 | | title | string | Y | | 标题 | | tips | string | N | | 提示说明 | | options | array | Y | | 配置参数,详细配置[请点此查看](https://www.layui.com/doc/modules/tree.html#options) | >[info] ![](https://img.kancloud.cn/80/81/8081655e035563691ffd90ac54b5bb51_529x231.png) >[]示例代码: ``` $assign['buildForm']['items'] = [ [ 'type' => 'tree', 'title' => '树形组件', 'name' => 'tree', 'options' => [ 'showCheckbox' => true, 'data' => [ [ 'title' => '一级1', 'id' => 1, 'children' => [ [ 'title' => '二级1', 'id' => 11, ], [ 'title' => '二级2', 'id' => 12, ], [ 'title' => '二级3', 'id' => 13, ], ], ], [ 'title' => '一级2', 'id' => 2, 'children' => [ [ 'title' => '二级1', 'id' => 21, ], [ 'title' => '二级2', 'id' => 22, ], [ 'title' => '二级3', 'id' => 23, ], ], ], ] ] ], // 更多表单项..... ]; ```