66 lines
1.8 KiB
JavaScript
66 lines
1.8 KiB
JavaScript
/**
|
||
* 发票勾选
|
||
*/
|
||
function checkInvoice(){
|
||
let ids = ModeList.getCheckedID();
|
||
if(!ids || ids === ""){
|
||
ModeList.showConfirm("请勾选发票!");
|
||
return;
|
||
}
|
||
let requestParam = {
|
||
ids:ids,
|
||
checkInvoiceUniqueCode:""
|
||
};
|
||
console.log("请求参数 ==>",requestParam)
|
||
ModeList.showLoading(true,'large','发票勾选中...');
|
||
$.ajax({
|
||
url:"/api/xbk/dz_invoice/checkInvoice",
|
||
type:"POST",
|
||
headers:{'Content-Type':'application/json'},
|
||
data:JSON.stringify(requestParam),
|
||
success:function(res){
|
||
console.log("result==>",res);
|
||
ModeList.showLoading(false);
|
||
ModeList.showMessage("操作成功", 3, 2); //提示信息,2s后消失
|
||
ModeList.reloadTable();
|
||
},
|
||
error:function(err){
|
||
console.log(err);
|
||
ModeList.showLoading(false);
|
||
}
|
||
})
|
||
}
|
||
|
||
/**
|
||
* 取消勾选
|
||
*/
|
||
function unCheckInvoice(){
|
||
let ids = ModeList.getCheckedID();
|
||
if(!ids || ids === ""){
|
||
ModeList.showConfirm("请勾选发票!");
|
||
return;
|
||
}
|
||
let requestParam = {
|
||
ids:ids,
|
||
checkInvoiceUniqueCode:""
|
||
};
|
||
console.log("请求参数 ==>",requestParam)
|
||
ModeList.showLoading(true,'large','发票取消勾选中...');
|
||
$.ajax({
|
||
url:"/api/xbk/dz_invoice/unCheckInvoice",
|
||
type:"POST",
|
||
headers:{'Content-Type':'application/json'},
|
||
data:JSON.stringify(requestParam),
|
||
success:function(res){
|
||
console.log("result==>",res);
|
||
ModeList.showLoading(false);
|
||
ModeList.showMessage("操作成功", 3, 2); //提示信息,2s后消失
|
||
ModeList.reloadTable();
|
||
},
|
||
error:function(err){
|
||
console.log(err);
|
||
ModeList.showLoading(false);
|
||
}
|
||
})
|
||
}
|