diff --git a/src/components/Common/CommonBillEvent.js b/src/components/Common/CommonBillEvent.js index 3121020..c675720 100644 --- a/src/components/Common/CommonBillEvent.js +++ b/src/components/Common/CommonBillEvent.js @@ -2792,7 +2792,7 @@ export default (ChildComponent) => { if (dataReturn.code === 1) { // eslint-disable-next-line no-underscore-dangle const _this = this; // 解决confirm中this指向问题; - if (dataReturn.dataset.rows.length > 0) { + if (dataReturn?.dataset?.rows?.length > 0) { confirm({ title: commonFunc.showMessage(app.commonConst, 'beUsedToNew'), /* 单据已存在,是否填写新单据 */ onOk() { diff --git a/src/components/Manufacture/ProcessCardPackTableTreeNew/index.js b/src/components/Manufacture/ProcessCardPackTableTreeNew/index.js index 5fe0d36..1bcb54c 100644 --- a/src/components/Manufacture/ProcessCardPackTableTreeNew/index.js +++ b/src/components/Manufacture/ProcessCardPackTableTreeNew/index.js @@ -1048,7 +1048,7 @@ const ProcessCardPackTableTreeNewEvent = props => { const values = { sSlaveId: sId }; const dataReturn = (await commonServices.postValueService(token, values, dataUrl)).data; if (dataReturn.code === 1) { - if (dataReturn.dataset.rows.length > 0) { + if (dataReturn?.dataset?.rows?.length > 0) { Modal.confirm({ title: commonFunc.showMessage(app.commonConst, "beUsedToNew") /* 单据已存在,是否填写新单据 */, onOk() { diff --git a/src/components/Manufacture/WorkOrderPackTableTreeNew/index.js b/src/components/Manufacture/WorkOrderPackTableTreeNew/index.js index b8224db..dccdf34 100644 --- a/src/components/Manufacture/WorkOrderPackTableTreeNew/index.js +++ b/src/components/Manufacture/WorkOrderPackTableTreeNew/index.js @@ -1679,7 +1679,7 @@ const WorkOrderPackTableTreeNewEvent = props => { const values = { sSlaveId: sId }; const dataReturn = (await commonServices.postValueService(token, values, dataUrl)).data; if (dataReturn.code === 1) { - if (dataReturn.dataset.rows.length > 0) { + if (dataReturn?.dataset?.rows?.length > 0) { Modal.confirm({ title: commonFunc.showMessage(app.commonConst, "beUsedToNew") /* 单据已存在,是否填写新单据 */, onOk() { diff --git a/src/components/QuoQuotation/QuotationPackTableTree/QuotationPackTableTree.js b/src/components/QuoQuotation/QuotationPackTableTree/QuotationPackTableTree.js index 2f0ac99..599cd03 100644 --- a/src/components/QuoQuotation/QuotationPackTableTree/QuotationPackTableTree.js +++ b/src/components/QuoQuotation/QuotationPackTableTree/QuotationPackTableTree.js @@ -2842,7 +2842,7 @@ class QuotationPackTableTree extends Component { if (dataReturn.code === 1) { // eslint-disable-next-line no-underscore-dangle const _this = this; // 解决confirm中this指向问题; - if (dataReturn.dataset.rows.length > 0) { + if (dataReturn?.dataset?.rows?.length > 0) { confirm({ title: commonFunc.showMessage(app.commonConst, 'beUsedToNew'), /* 单据已存在,是否填写新单据 */ onOk() {