Commit 545bdf34 authored by 18083's avatar 18083

修改茂甲销项税发票邮件发送逻辑

parent b429cede
......@@ -92,19 +92,25 @@
Leaf.showMessage('提示','请勾选认领状态为已确认的单据');
return;
}
if(records[i].get('invoice_type') != 'ECT'){
//18083 2022/11/24
if(records[i].get('invoice_kind_type') != 'ELECTRONIC_GENERAL' && records[i].get('invoice_kind_type') != 'ELECTRONIC_SPECIAL'){
Leaf.showMessage('提示','请勾选电子发票进行发送');
return;
}
if(records[i].get('division') == '70'){
if(!r_map.has(records[i].get('bp_id_agent_level1'))){
var arr = new Array();
arr.add(records[i].get('invoice_hd_id'));
r_map.set(records[i].get('bp_id_agent_level1'),arr);
}else{
r_map.get(records[i].get('bp_id_agent_level1')).add(records[i].get('invoice_hd_id'));
}
} else if(!r_map.has(records[i].get('invoice_bp_id'))){
// if(records[i].get('invoice_type') != 'ECT'){
//Leaf.showMessage('提示','请勾选电子发票进行发送');
//return;
//}
//if(records[i].get('division') == '70'){
// if(!r_map.has(records[i].get('bp_id_agent_level1'))){
//var arr = new Array();
// arr.add(records[i].get('invoice_hd_id'));
// r_map.set(records[i].get('bp_id_agent_level1'),arr);
// }else{
// r_map.get(records[i].get('bp_id_agent_level1')).add(records[i].get('invoice_hd_id'));
//}
//} else
if(!r_map.has(records[i].get('invoice_bp_id'))){
var arr = new Array();
arr.add(records[i].get('invoice_hd_id'));
r_map.set(records[i].get('invoice_bp_id'),arr);
......
......@@ -43,7 +43,6 @@
// $('acr517_invoice_result_ds').setSubmitUrl('${/request/@context_path}/autocrud/acr.ACR605.acr_invoice_claim_confirm_new/batch_update');
var records=$('acr517_invoice_result_ds').getSelected();
debugger;
var datas = [];
var r_map = new Map();
for (var i = 0;i < records.length;i++) {
......@@ -51,15 +50,17 @@
'invoice_hd_id':records[i].get('invoice_hd_id'),
'_status': 'update'
})
if(records[i].get('division') == '70'){
if(!r_map.has(records[i].get('bp_id_agent_level1'))){
var arr = new Array();
arr.add(records[i].get('invoice_hd_id'));
r_map.set(records[i].get('bp_id_agent_level1'),arr);
}else{
r_map.get(records[i].get('bp_id_agent_level1')).add(records[i].get('invoice_hd_id'));
}
} else if(records[i].get('invoice_type') == 'ECT'){
//铁甲业务去掉特殊处理,与非铁甲业务保持一致 18083 2022/12/8
//if(records[i].get('division') == '70'){
// if(!r_map.has(records[i].get('bp_id_agent_level1'))){
// var arr = new Array();
// arr.add(records[i].get('invoice_hd_id'));
// r_map.set(records[i].get('bp_id_agent_level1'),arr);
// }else{
// r_map.get(records[i].get('bp_id_agent_level1')).add(records[i].get('invoice_hd_id'));
// }
// } else if(records[i].get('invoice_type') == 'ECT'){
if(records[i].get('invoice_kind_type') == 'ELECTRONIC_GENERAL' || records[i].get('invoice_kind_type') == 'ELECTRONIC_SPECIAL'){
if(!r_map.has(records[i].get('invoice_bp_id'))){
var arr = new Array();
arr.add(records[i].get('invoice_hd_id'));
......@@ -67,7 +68,7 @@
}else{
r_map.get(records[i].get('invoice_bp_id')).add(records[i].get('invoice_hd_id'));
}
}
}
}
var result_map = MapTOJson(r_map);
$L.showConfirm("提示",'确认执行该操作?',function(){
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment