<ruby id="bdb3f"></ruby>

    <p id="bdb3f"><cite id="bdb3f"></cite></p>

      <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
        <p id="bdb3f"><cite id="bdb3f"></cite></p>

          <pre id="bdb3f"></pre>
          <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

          <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
          <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

          <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                <ruby id="bdb3f"></ruby>

                ??碼云GVP開源項目 12k star Uniapp+ElementUI 功能強大 支持多語言、二開方便! 廣告
                # 組件名`cap4-tree` ---- ### 引入 ```js import Cap4Tree from 'cap4-pc-ui/lib/cap4-tree'; import 'cap4-pc-ui/lib/cap4-tree/css/cap4-tree.css'; ``` ### 基礎用法 <template> <div class="demo-block" > <cap4-tree :treeData="treeData" :activeItem="activeItem" @childClick="childClick" @childDbClick="childDbClick" ></cap4-tree> </div> </template> <script> export default { data() { return { // 注意root虛擬節點不顯示 treeData: { name: 'root', id: 'root', level: 0, type: 'ul', show: true, branch: true, showChildren: true, children: [{ id: '0', name: '城市', parentId: 'root', type: 'ul', level: 1, show: true, branch: true, showChildren: true, children: [{ id: '1', level: 2, name: '北京', parentId: '0', show: true, branch: false }, { id: '2', level: 2, name: '上海', parentId: '0', show: true, branch: false }, { id: '3', level: 2, name: '廣州', parentId: '0', show: true, branch: false }] }] }, activeItem: [] }; }, methods: { childClick(item) { this.activeItem = [item]; console.log(item); }, childDbClick(item) { this.activeItem = [item]; console.log(item); }, listChoose(id, items) { console.log(id, items); } } }; </script> ::: demo ```html <template> <div class="demo-block" > <cap4-tree :treeData="treeData" :activeItem="activeItem" @childClick="childClick" @childDbClick="childDbClick" ></cap4-tree> </div> </template> <script> export default { data() { return { // 注意root虛擬節點不顯示 treeData: { name: 'root', id: 'root', level: 0, type: 'ul', show: true, branch: true, showChildren: true, children: [{ id: '0', name: '城市', parentId: 'root', type: 'ul', level: 1, show: true, branch: true, showChildren: true, children: [{ id: '1', level: 2, name: '北京', parentId: '0', show: true, branch: false }, { id: '2', level: 2, name: '上海', parentId: '0', show: true, branch: false }, { id: '3', level: 2, name: '廣州', parentId: '0', show: true, branch: false }] }] }, activeItem: [] }; }, methods: { childClick(item) { this.activeItem = [item]; console.log(item); }, childDbClick(item) { this.activeItem = [item]; console.log(item); }, listChoose(id, items) { console.log(id, items); } } }; </script> ``` ::: ### Attributes | 參數 | 說明 | 類型 | 可選值 | 默認值 | |---------- |------------------------------------ |---------- |------------- |-------- | |treeData | 數據 (必填)) | Object | — | '' | |activeItem | 選中項 (選填)) | Array | — | | |showFull | 全稱 (選填)) | Boolean | — | | |showFolderIcon | 顯示文件夾圖標 (選填)) | Boolean | — | | ### Event | 事件名稱 | 說明 | 回調參數 | |------------- |----------- |--------- | |childClick |單擊| item | |childDbClick |雙擊| item | |listChoose |多選| id, items |
                  <ruby id="bdb3f"></ruby>

                  <p id="bdb3f"><cite id="bdb3f"></cite></p>

                    <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
                      <p id="bdb3f"><cite id="bdb3f"></cite></p>

                        <pre id="bdb3f"></pre>
                        <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

                        <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
                        <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

                        <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                              <ruby id="bdb3f"></ruby>

                              哎呀哎呀视频在线观看