<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>

                ThinkChat2.0新版上線,更智能更精彩,支持會話、畫圖、視頻、閱讀、搜索等,送10W Token,即刻開啟你的AI之旅 廣告
                列表上很多時候需要添加操作按鈕, ## 1. 第一種,表格右上角按鈕 這里可以用到 ui/table/*.php中的ops 格式如下: ``` class DemoTable extends TableInterface { public function ops() { return [ 'edit' => [ 'type' => 'link', 'label' => '編輯', 'icon' => 'el - icon - edit', 'url' => '/thinkadmin/user/edit', 'vars' => ['id'], ], 'del' => [ 'type' => 'ajax', 'label' => '刪除', 'icon' => 'el - icon - delete', 'url' => '/thinkadmin/user/delete', 'vars' => ['id'], 'confirm' => '是否刪除管理員?', ] ]; } } ``` 配置項目 - type 操作類型,link是打開新窗口,ajax是調用一個ajax操作 - label 標題 - icon 操作圖標 - url 連接地址 - vars 鏈接地址上需要的參數,會自動從行數據中獲取對應的值 ## 2. 第二種,列表數據中的按鈕 很多時候列表中的數據是需要增加鏈接,這個時候處理是,在table文件中header相應字段type設置為link,格式如下 ``` ~~~ class NewsTable extends TableInterface { public function header() { return [ 'has_child'=> ['label' => '子菜單', 'type' => 'link', 'linkConfig' => [ ['key' => 'has_child', 'value' => true, 'showValue' => false, 'label' => '管理子分類', 'icon' => 'fa fa-level-down', 'url' => '/mall/admin/mallCate', 'vars' =>['id@parent_id']], ] ]; } } ``` linkConfig 配置 - key 數據對應的字段 - value 過濾值,行數據的數據等于 value的值的時候才顯示 - showValue 是否顯示數據所包含的值 - label 鏈接名稱 - icon 鏈接圖標 - url,vars 鏈接的地址和參數
                  <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>

                              哎呀哎呀视频在线观看