久久久久久久视色,久久电影免费精品,中文亚洲欧美乱码在线观看,在线免费播放AV片

<center id="vfaef"><input id="vfaef"><table id="vfaef"></table></input></center>

    <p id="vfaef"><kbd id="vfaef"></kbd></p>

    
    
    <pre id="vfaef"><u id="vfaef"></u></pre>

      <thead id="vfaef"><input id="vfaef"></input></thead>

    1. 站長資訊網(wǎng)
      最全最豐富的資訊網(wǎng)站

      layui的table如何做批量刪除

      layui的table如何做批量刪除

      layui的table做批量刪除實現(xiàn)代碼如下:

      // 批量刪除功能     // 1.得到table選中行內(nèi)容     // 2.得到刪除需要的唯一值,一般是id;     // 3.將所要刪除的項加入到數(shù)組中;     // 4.判斷是否選中;     // 5.發(fā)送ajax請求,并附帶參數(shù)id;      var $=layui.$,active={          deLink:function () {              var checkStatus=table.checkStatus('idTest'),                  data=checkStatus.data,                  deList=[];              data.forEach(function(n,i){                  delList.push(n.id);              });              if(delList!=''){                  layer.comfirm('確定刪除所選項嗎?',function (index) {                      $.ajax({                          url: '/cd/workPlatform/tool/remove.afca',                          type:'post',                          dataType:'json',                          data:"id="+delList,                          success:function (data,statusText) {                              if(data.code==='0'){                                  layer.msg('刪除成功');                                  table.reload('idTest',{});                              }else{                                  layer.msg('刪除失敗');                              }                          },                          'error':function () {                              layer.msg('系統(tǒng)錯誤');                          }                      })                  })              }else{                  layer.tips('請選擇需要刪除的行',$('#batchDel'),{                      tips:[3,'#5fb878']                  })              }          }      }

      推薦:layui框架教程

      贊(0)
      分享到: 更多 (0)
      網(wǎng)站地圖   滬ICP備18035694號-2    滬公網(wǎng)安備31011702889846號