|
|
|
@ -164,6 +164,7 @@
|
|
|
|
|
<div class="butnbox" >
|
|
|
|
|
<div class="butnlist jscheckbutn" style="margin-left: 2px">
|
|
|
|
|
<a class='butn' id='customerExport'>导出所选记录</a>
|
|
|
|
|
<a class='butn' style="background-color: red;" id='batchDel'>批量删除</a>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
@ -380,6 +381,47 @@
|
|
|
|
|
$("body").append(iframeExcel);
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
$("#batchDel").click(function () {
|
|
|
|
|
var flag = false;
|
|
|
|
|
var text = $("input:checkbox[name='ids[]']:checked").map(function(index,elem) {
|
|
|
|
|
return $(elem).data("verify_id");
|
|
|
|
|
}).get();
|
|
|
|
|
|
|
|
|
|
if(text.length < 1){
|
|
|
|
|
layer.msg("<font style='color:white'>" + '请先选择要删除的数据' + "</font>");
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
layer.confirm('【警告】删除后将不可回退,请慎重选择', {
|
|
|
|
|
btn: ['确认','取消'],
|
|
|
|
|
title:false
|
|
|
|
|
}, function(index){
|
|
|
|
|
layer.close(index);
|
|
|
|
|
_del();
|
|
|
|
|
});
|
|
|
|
|
function _del(){
|
|
|
|
|
var id = text.join(",");
|
|
|
|
|
$.ajax({
|
|
|
|
|
type: "POST",
|
|
|
|
|
url: "{:U('batchDel')}",
|
|
|
|
|
dataType: 'json',
|
|
|
|
|
async: true,
|
|
|
|
|
data: {ids:id},
|
|
|
|
|
success:function(data){
|
|
|
|
|
if(data.status==1){
|
|
|
|
|
layer.msg("<font style='color:white'>" + data.msg + "</font>");
|
|
|
|
|
setTimeout(function(){
|
|
|
|
|
window.location.reload();
|
|
|
|
|
},1500);
|
|
|
|
|
}else{
|
|
|
|
|
layer.msg("<font style='color:white'>" + data.msg + "</font>");
|
|
|
|
|
return false;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
$("#search").click(function(){
|
|
|
|
|
var url = $(this).attr('url');
|
|
|
|
|
var query = $('.jssearch').find('input').serialize();
|
|
|
|
|