diff --git a/js/aq_demand_plan/child/choose_tool_type_list.js b/js/aq_demand_plan/child/choose_tool_type_list.js index 5066711..538e30c 100644 --- a/js/aq_demand_plan/child/choose_tool_type_list.js +++ b/js/aq_demand_plan/child/choose_tool_type_list.js @@ -86,7 +86,7 @@ function initTable() { limitName: 'pageSize' }, parseData: function (res) { // res 即为原始返回的数据 - if(res.code === 401){ + if(res.code === 401) { closeWindowOpen(); } if (jjDetailArr && res.list) { diff --git a/js/aq_demand_plan/child/send_out_edit_form.js b/js/aq_demand_plan/child/send_out_edit_form.js index e57b3b5..af1f639 100644 --- a/js/aq_demand_plan/child/send_out_edit_form.js +++ b/js/aq_demand_plan/child/send_out_edit_form.js @@ -219,7 +219,8 @@ function beforeSubmitApply() { let l = list[j]; cgNum += (l.cgNum ? parseInt(l.cgNum) : 0); lkNum += (l.lkNum ? parseInt(l.lkNum) : 0); - if (!l.supId) { + if (!l.supId && cgNum > 0) { + // 采购才需要填写供应商 return layer.msg('序号为' + (i + 1) + '的数据,未选择供应商', { icon: 7 }); } if (!l.ccDay) { diff --git a/js/aq_demand_plan/child/send_out_form.js b/js/aq_demand_plan/child/send_out_form.js index 1f53398..1eb875d 100644 --- a/js/aq_demand_plan/child/send_out_form.js +++ b/js/aq_demand_plan/child/send_out_form.js @@ -152,7 +152,7 @@ function beforeSubmitApply() { let l = list[j]; cgNum += (l.cgNum ? parseInt(l.cgNum) : 0); lkNum += (l.lkNum ? parseInt(l.lkNum) : 0); - if (!l.supId) { + if (!l.supId && cgNum > 0) { return layer.msg('序号为' + (i + 1) + '的数据,未选择供应商', { icon: 7 }); } } diff --git a/js/aq_demand_plan/child/send_out_form_device.js b/js/aq_demand_plan/child/send_out_form_device.js index 5ad36af..28c1b7c 100644 --- a/js/aq_demand_plan/child/send_out_form_device.js +++ b/js/aq_demand_plan/child/send_out_form_device.js @@ -152,7 +152,8 @@ function beforeSubmitApply() { let l = list[j]; cgNum += (l.cgNum ? parseInt(l.cgNum) : 0); lkNum += (l.lkNum ? parseInt(l.lkNum) : 0); - if (!l.supId) { + if (!l.supId && cgNum > 0) { + // 采购的才需要选择供应商 return layer.msg('序号为' + (i + 1) + '的数据,未选择供应商', { icon: 7 }); } if (!l.ccDay) { diff --git a/js/aq_demand_plan/child/send_out_unplanned_form.js b/js/aq_demand_plan/child/send_out_unplanned_form.js index 3fa1926..83916b0 100644 --- a/js/aq_demand_plan/child/send_out_unplanned_form.js +++ b/js/aq_demand_plan/child/send_out_unplanned_form.js @@ -157,7 +157,7 @@ function beforeSubmitApply() { let l = list[j]; cgNum += (l.cgNum ? parseInt(l.cgNum) : 0); lkNum += (l.lkNum ? parseInt(l.lkNum) : 0); - if (!l.supId) { + if (!l.supId && cgNum > 0) { return layer.msg('序号为' + (i + 1) + '的数据,未选择供应商', { icon: 7 }); } }