<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 功能強大 支持多語言、二開方便! 廣告
                ## 頭部工具欄 > 圖片演示: ![](https://img.kancloud.cn/db/63/db63bac454bb3072756aa5e2db2740a4_1617x575.png) > 說明: 設置頭部工具欄。 > 注意!依賴cols的設置 方法:`toolbar($toolbar)` * 參數 **toolbar** (必須) * 類型一:callable 閉包,例: ```php // state設置時$state為狀態key值,其余情況為null toolbar(function($state){ $toolbar=[ 'add'=>['type'=>'openPopup','title'=>'添加','class'=>'layui-icon layui-icon-add-circle','url'=>url('add')] ]; switch($state){ case 11: $toolbar+= [ 22=>['title'=>'移入回收站','dropdown'=>true], ... ]; break; ... } return $toolbar; }); ``` * 類型二:array,例: ```php toolbar([ 'add'=>['type'=>'openPopup','title'=>'添加','class'=>'layui-icon layui-icon-add-circle','url'=>url('add')], ... ]); > 配置項 | key | 類型 | 是否必須 | 說明 | | --- | --- | --- | --- | | type | string | 否 | 觸發事件類型,可選值:<br>openTab 打開子頁面、<br>openPopup 打開彈出層頁面<br>其他情況默認為asyncEvent 異步事件 | | title | string | 否 | 標題 | | class | string | 否 | 額外的class,可含圖標的`class` | | url | string | 是 | 觸發事件執行的url | | confirmText | string | 否 | 確認彈窗提示 | | dropdown | bool | 否 | 是否下拉操作,默認`false` | > 提示:觸發事件名為配置項key,主要用于type=asyncEvent的異步請求。 > 示例: 設置`正常(11)`狀態頭部工具欄為`添加`+`操作(移入回收站)`;`回收站(22)`狀態篩選條件為`添加`+`操作(還原、永久刪除)` * 方法如下: ```php $builder=YT('general_example')->toolbar(function($state){ $toolbar=['add'=>['type'=>'openTab','title'=>'添加','class'=>'layui-icon layui-icon-add-circle','url'=>url('add')]]; switch ($state){ case 11: $toolbar+=[ 22=>['title'=>'移入回收站','batch'=>true], ]; break; case 22: $toolbar+=[ 11=>['title'=>'還原','batch'=>true], 99=>['title'=>'永久刪除','batch'=>true], ]; break; } return $toolbar; }) ```
                  <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>

                              哎呀哎呀视频在线观看