Commit 7e6a348a048b5386e2d3b056ef383e31f68bf8f9

Authored by Min
1 parent 92a0d63a

1.处理工艺卡,工单单据复制到报错

src/components/Common/CommonBillEvent.js
... ... @@ -2792,7 +2792,7 @@ export default (ChildComponent) => {
2792 2792 if (dataReturn.code === 1) {
2793 2793 // eslint-disable-next-line no-underscore-dangle
2794 2794 const _this = this; // 解决confirm中this指向问题;
2795   - if (dataReturn.dataset.rows.length > 0) {
  2795 + if (dataReturn?.dataset?.rows?.length > 0) {
2796 2796 confirm({
2797 2797 title: commonFunc.showMessage(app.commonConst, 'beUsedToNew'), /* 单据已存在,是否填写新单据 */
2798 2798 onOk() {
... ...
src/components/Manufacture/ProcessCardPackTableTreeNew/index.js
... ... @@ -1048,7 +1048,7 @@ const ProcessCardPackTableTreeNewEvent = props => {
1048 1048 const values = { sSlaveId: sId };
1049 1049 const dataReturn = (await commonServices.postValueService(token, values, dataUrl)).data;
1050 1050 if (dataReturn.code === 1) {
1051   - if (dataReturn.dataset.rows.length > 0) {
  1051 + if (dataReturn?.dataset?.rows?.length > 0) {
1052 1052 Modal.confirm({
1053 1053 title: commonFunc.showMessage(app.commonConst, "beUsedToNew") /* 单据已存在,是否填写新单据 */,
1054 1054 onOk() {
... ...
src/components/Manufacture/WorkOrderPackTableTreeNew/index.js
... ... @@ -1679,7 +1679,7 @@ const WorkOrderPackTableTreeNewEvent = props => {
1679 1679 const values = { sSlaveId: sId };
1680 1680 const dataReturn = (await commonServices.postValueService(token, values, dataUrl)).data;
1681 1681 if (dataReturn.code === 1) {
1682   - if (dataReturn.dataset.rows.length > 0) {
  1682 + if (dataReturn?.dataset?.rows?.length > 0) {
1683 1683 Modal.confirm({
1684 1684 title: commonFunc.showMessage(app.commonConst, "beUsedToNew") /* 单据已存在,是否填写新单据 */,
1685 1685 onOk() {
... ...
src/components/QuoQuotation/QuotationPackTableTree/QuotationPackTableTree.js
... ... @@ -2842,7 +2842,7 @@ class QuotationPackTableTree extends Component {
2842 2842 if (dataReturn.code === 1) {
2843 2843 // eslint-disable-next-line no-underscore-dangle
2844 2844 const _this = this; // 解决confirm中this指向问题;
2845   - if (dataReturn.dataset.rows.length > 0) {
  2845 + if (dataReturn?.dataset?.rows?.length > 0) {
2846 2846 confirm({
2847 2847 title: commonFunc.showMessage(app.commonConst, 'beUsedToNew'), /* 单据已存在,是否填写新单据 */
2848 2848 onOk() {
... ...