Commit bcfae90bb49dd15a162fed091295a06435ae9b22

Authored by Min
2 parents 2b0ac33d 49e8874c

Merge branch 'main' of http://git.xlyprint.cn/zhangz/xlyUmi

Showing 34 changed files with 111 additions and 111 deletions
src/components/AuditInformation/AuditInformation.js
@@ -33,7 +33,7 @@ class AuditInformation extends Component { @@ -33,7 +33,7 @@ class AuditInformation extends Component {
33 let { masterConfig, canSendMsg } = nextProps; 33 let { masterConfig, canSendMsg } = nextProps;
34 const { userinfo } = app; 34 const { userinfo } = app;
35 if (commonUtils.isEmptyArr(masterConfig) && formData.length > 0) { 35 if (commonUtils.isEmptyArr(masterConfig) && formData.length > 0) {
36 - const sId = currentId !== undefined ? currentId : ''; 36 + const sId = currentId || nextProps.masterData?.sId || '';
37 /* 数据Id */ 37 /* 数据Id */
38 masterConfig = formData.filter(item => !item.bGrd)[0]; 38 masterConfig = formData.filter(item => !item.bGrd)[0];
39 const checkConfig = formData.filter(item => item.bGrd && item.sTbName === 'sysbillcheckresult')[0]; 39 const checkConfig = formData.filter(item => item.bGrd && item.sTbName === 'sysbillcheckresult')[0];
@@ -58,7 +58,7 @@ class AuditInformation extends Component { @@ -58,7 +58,7 @@ class AuditInformation extends Component {
58 /** 获取主表数据 */ 58 /** 获取主表数据 */
59 handleGetData = async (masterConfig, checkConfig) => { 59 handleGetData = async (masterConfig, checkConfig) => {
60 const { currentId } = this.props; /* 当前页签数据 */ 60 const { currentId } = this.props; /* 当前页签数据 */
61 - const sId = currentId !== undefined ? currentId : ''; 61 + const sId = currentId || this.props.masterData?.sId || '';
62 await this.props.handleGetDataOne({ name: 'master', configData: masterConfig, condition: { sId, pageSize: '', pageNum: '' } }); 62 await this.props.handleGetDataOne({ name: 'master', configData: masterConfig, condition: { sId, pageSize: '', pageNum: '' } });
63 const { masterData } = this.props; 63 const { masterData } = this.props;
64 if (!commonUtils.isEmptyObject(checkConfig) && !commonUtils.isEmptyObject(masterData)) { 64 if (!commonUtils.isEmptyObject(checkConfig) && !commonUtils.isEmptyObject(masterData)) {
src/components/Common/CommonBillDeliverEvent.js
@@ -47,7 +47,7 @@ export default (ChildComponent) => { @@ -47,7 +47,7 @@ export default (ChildComponent) => {
47 employeeConfig: employeeConfigOld, 47 employeeConfig: employeeConfigOld,
48 } = nextProps; 48 } = nextProps;
49 if (commonUtils.isEmptyObject(slaveConfigOld) && formData.length > 0 && (sModelsType !== 'cashier/financialTransfer' && sModelsType !== 'cashier/financialAdjustment' && sModelsType !== 'quality/accident' && sModelsType !== 'purchase/purchaseEnquiry' && sModelsType !== 'complaint/complaint' && sModelsType !== 'print/printLabel' && sModelsType !== 'commonBill/onlyMaster' && formRoute.indexOf('indexOee') === -1)) { 49 if (commonUtils.isEmptyObject(slaveConfigOld) && formData.length > 0 && (sModelsType !== 'cashier/financialTransfer' && sModelsType !== 'cashier/financialAdjustment' && sModelsType !== 'quality/accident' && sModelsType !== 'purchase/purchaseEnquiry' && sModelsType !== 'complaint/complaint' && sModelsType !== 'print/printLabel' && sModelsType !== 'commonBill/onlyMaster' && formRoute.indexOf('indexOee') === -1)) {
50 - const sId = currentId !== undefined ? currentId : ''; 50 + const sId = currentId || nextProps.masterData?.sId || '';
51 /* 数据Id */ 51 /* 数据Id */
52 const masterConfig = formData.filter(item => !item.bGrd)[0]; 52 const masterConfig = formData.filter(item => !item.bGrd)[0];
53 const BtnDesignFunctionConfig = commonUtils.isNotEmptyObject(masterConfig) ? masterConfig.gdsconfigformslave.filter(item => item.sControlName === 'BtnBsOperation.BtnDesignFunction') : {}; 53 const BtnDesignFunctionConfig = commonUtils.isNotEmptyObject(masterConfig) ? masterConfig.gdsconfigformslave.filter(item => item.sControlName === 'BtnBsOperation.BtnDesignFunction') : {};
@@ -274,7 +274,7 @@ export default (ChildComponent) => { @@ -274,7 +274,7 @@ export default (ChildComponent) => {
274 }); 274 });
275 } else if (commonUtils.isEmptyObject(masterConfigOld) && formData.length === 1 && (sModelsType === 'cashier/financialTransfer' || sModelsType === 'purchase/purchaseEnquiry' || sModelsType === 'cashier/financialAdjustment' || sModelsType === 'print/printLabel' || sModelsType === 'complaint/complaint' || sModelsType === 'commonBill/onlyMaster') && formRoute.indexOf('indexOee') === -1) { 275 } else if (commonUtils.isEmptyObject(masterConfigOld) && formData.length === 1 && (sModelsType === 'cashier/financialTransfer' || sModelsType === 'purchase/purchaseEnquiry' || sModelsType === 'cashier/financialAdjustment' || sModelsType === 'print/printLabel' || sModelsType === 'complaint/complaint' || sModelsType === 'commonBill/onlyMaster') && formRoute.indexOf('indexOee') === -1) {
276 const config = {}; 276 const config = {};
277 - const sId = currentId !== undefined ? currentId : ''; 277 + const sId = currentId || nextProps.masterData?.sId || '';
278 /* 数据Id */ 278 /* 数据Id */
279 const masterConfig = formData.filter(item => !item.bGrd)[0]; 279 const masterConfig = formData.filter(item => !item.bGrd)[0];
280 let addState = {}; 280 let addState = {};
@@ -296,7 +296,7 @@ export default (ChildComponent) => { @@ -296,7 +296,7 @@ export default (ChildComponent) => {
296 masterConfig, sId, pageLoading: false, ...addState, 296 masterConfig, sId, pageLoading: false, ...addState,
297 }); 297 });
298 } else if (commonUtils.isEmptyObject(slaveConfigOld) && commonUtils.isEmptyObject(masterConfigOld) && formData.length === 2 && (sModelsType === 'quality/accident') && formRoute.indexOf('indexOee') === -1) { 298 } else if (commonUtils.isEmptyObject(slaveConfigOld) && commonUtils.isEmptyObject(masterConfigOld) && formData.length === 2 && (sModelsType === 'quality/accident') && formRoute.indexOf('indexOee') === -1) {
299 - const sId = currentId !== undefined ? currentId : ''; 299 + const sId = currentId || nextProps.masterData?.sId || '';
300 /* 数据Id */ 300 /* 数据Id */
301 const masterConfig = formData.filter(item => !item.bGrd)[0]; 301 const masterConfig = formData.filter(item => !item.bGrd)[0];
302 const slaveConfig = formData.filter(item => item.bGrd && item.sTbName === 'mftqualityaccidentSlave')[0]; 302 const slaveConfig = formData.filter(item => item.bGrd && item.sTbName === 'mftqualityaccidentSlave')[0];
@@ -319,7 +319,7 @@ export default (ChildComponent) => { @@ -319,7 +319,7 @@ export default (ChildComponent) => {
319 }); 319 });
320 } else if (formRoute.indexOf('indexOee') > -1 && commonUtils.isEmptyObject(employeeConfigOld) && commonUtils.isEmptyObject(slaveConfigOld) && formData.length > 0) { 320 } else if (formRoute.indexOf('indexOee') > -1 && commonUtils.isEmptyObject(employeeConfigOld) && commonUtils.isEmptyObject(slaveConfigOld) && formData.length > 0) {
321 if (formRoute === '/indexOee/labelPrint' && commonUtils.isEmpty(slaveConfigOld)) { /* 入库标签打印 */ 321 if (formRoute === '/indexOee/labelPrint' && commonUtils.isEmpty(slaveConfigOld)) { /* 入库标签打印 */
322 - const sId = currentId !== undefined ? currentId : ''; 322 + const sId = currentId || nextProps.masterData?.sId || '';
323 /* 数据Id */ 323 /* 数据Id */
324 const masterConfig = formData[0]; 324 const masterConfig = formData[0];
325 const slaveConfig = formData[0]; 325 const slaveConfig = formData[0];
@@ -507,7 +507,7 @@ export default (ChildComponent) => { @@ -507,7 +507,7 @@ export default (ChildComponent) => {
507 /** 获取主表、从表、审核表数据 */ 507 /** 获取主表、从表、审核表数据 */
508 handleGetData = async (masterConfig, slaveConfig, checkConfig, bEditClick) => { 508 handleGetData = async (masterConfig, slaveConfig, checkConfig, bEditClick) => {
509 const { currentId } = this.props; /* 当前页签数据 */ 509 const { currentId } = this.props; /* 当前页签数据 */
510 - const sId = currentId !== undefined ? currentId : ''; 510 + const sId = currentId || this.props.masterData?.sId || '';
511 await this.props.handleGetDataOne({ 511 await this.props.handleGetDataOne({
512 name: 'master', configData: masterConfig, condition: { sId, pageSize: '', pageNum: '' }, bEditClick, 512 name: 'master', configData: masterConfig, condition: { sId, pageSize: '', pageNum: '' }, bEditClick,
513 }); 513 });
@@ -544,7 +544,7 @@ export default (ChildComponent) => { @@ -544,7 +544,7 @@ export default (ChildComponent) => {
544 /* 获取表数据 */ 544 /* 获取表数据 */
545 handleGetMemoData = async (controlConfig, materialsConfig, processConfig, colorConfig, packConfig) => { 545 handleGetMemoData = async (controlConfig, materialsConfig, processConfig, colorConfig, packConfig) => {
546 const { currentId, sModelsType } = this.props; /* 当前页签数据 */ 546 const { currentId, sModelsType } = this.props; /* 当前页签数据 */
547 - const sId = currentId !== undefined ? currentId : ''; /* 数据Id */ 547 + const sId = currentId || this.props.masterData?.sId || ''; /* 数据Id */
548 const addStateControl = await this.props.handleGetDataSet({ 548 const addStateControl = await this.props.handleGetDataSet({
549 name: 'control', configData: controlConfig, condition: { sSqlCondition: { sParentId: sId } }, isWait: true, 549 name: 'control', configData: controlConfig, condition: { sSqlCondition: { sParentId: sId } }, isWait: true,
550 }); 550 });
@@ -597,7 +597,7 @@ export default (ChildComponent) => { @@ -597,7 +597,7 @@ export default (ChildComponent) => {
597 /* 获取单张表数据 */ 597 /* 获取单张表数据 */
598 handleGetOneMemoData = (memoName, memoConfig) => { 598 handleGetOneMemoData = (memoName, memoConfig) => {
599 const { currentId } = this.props; /* 当前页签数据 */ 599 const { currentId } = this.props; /* 当前页签数据 */
600 - const sId = currentId !== undefined ? currentId : ''; /* 数据Id */ 600 + const sId = currentId || this.props.masterData?.sId || ''; /* 数据Id */
601 if (commonUtils.isNotEmptyObject(sId)) { /* 解决detail数据没有问题 */ 601 if (commonUtils.isNotEmptyObject(sId)) { /* 解决detail数据没有问题 */
602 this.props.handleGetDataSet({ 602 this.props.handleGetDataSet({
603 name: memoName, configData: memoConfig, condition: { sSqlCondition: { sParentId: sId } }, 603 name: memoName, configData: memoConfig, condition: { sSqlCondition: { sParentId: sId } },
src/components/Common/CommonBillEvent.js
@@ -79,7 +79,7 @@ export default (ChildComponent) => { @@ -79,7 +79,7 @@ export default (ChildComponent) => {
79 slaveInfoList: slaveInfoListOld, 79 slaveInfoList: slaveInfoListOld,
80 } = nextProps; 80 } = nextProps;
81 if (commonUtils.isEmptyObject(slaveConfigOld) && formData.length > 0 && (sModelsId === '12710101117024321284220' || (sModelsType !== 'cashier/financialTransfer' && sModelsType !== 'cashier/financialAdjustment' && sModelsType !== 'quality/accident' && sModelsType !== 'purchase/purchaseEnquiry' && sModelsType !== 'complaint/complaint' && sModelsType !== 'print/printLabel' && sModelsType !== 'commonBill/onlyMaster' && (formRoute.indexOf('indexOee') === -1 || formRoute === '/indexOee/commonOeeBill')))) { 81 if (commonUtils.isEmptyObject(slaveConfigOld) && formData.length > 0 && (sModelsId === '12710101117024321284220' || (sModelsType !== 'cashier/financialTransfer' && sModelsType !== 'cashier/financialAdjustment' && sModelsType !== 'quality/accident' && sModelsType !== 'purchase/purchaseEnquiry' && sModelsType !== 'complaint/complaint' && sModelsType !== 'print/printLabel' && sModelsType !== 'commonBill/onlyMaster' && (formRoute.indexOf('indexOee') === -1 || formRoute === '/indexOee/commonOeeBill')))) {
82 - const sId = currentId !== undefined ? currentId : ''; 82 + const sId = currentId || nextProps.masterData?.sId || '';
83 /* 数据Id */ 83 /* 数据Id */
84 const masterConfig = formData.filter(item => !item.bGrd)[0]; 84 const masterConfig = formData.filter(item => !item.bGrd)[0];
85 const BtnDesignFunctionConfig = commonUtils.isNotEmptyObject(masterConfig) ? masterConfig.gdsconfigformslave.filter(item => item.sControlName === 'BtnBsOperation.BtnDesignFunction') : {}; 85 const BtnDesignFunctionConfig = commonUtils.isNotEmptyObject(masterConfig) ? masterConfig.gdsconfigformslave.filter(item => item.sControlName === 'BtnBsOperation.BtnDesignFunction') : {};
@@ -494,7 +494,7 @@ export default (ChildComponent) => { @@ -494,7 +494,7 @@ export default (ChildComponent) => {
494 }); 494 });
495 } else if (commonUtils.isEmptyObject(masterConfigOld) && formData.length === 1 && (sModelsType === 'cashier/financialTransfer' || sModelsType === 'purchase/purchaseEnquiry' || sModelsType === 'cashier/financialAdjustment' || sModelsType === 'print/printLabel' || sModelsType === 'complaint/complaint' || sModelsType === 'commonBill/onlyMaster') && formRoute.indexOf('indexOee') === -1) { 495 } else if (commonUtils.isEmptyObject(masterConfigOld) && formData.length === 1 && (sModelsType === 'cashier/financialTransfer' || sModelsType === 'purchase/purchaseEnquiry' || sModelsType === 'cashier/financialAdjustment' || sModelsType === 'print/printLabel' || sModelsType === 'complaint/complaint' || sModelsType === 'commonBill/onlyMaster') && formRoute.indexOf('indexOee') === -1) {
496 const config = {}; 496 const config = {};
497 - const sId = currentId !== undefined ? currentId : ''; 497 + const sId = currentId || nextProps.masterData?.sId || '';
498 /* 数据Id */ 498 /* 数据Id */
499 const masterConfig = formData.filter(item => !item.bGrd)[0]; 499 const masterConfig = formData.filter(item => !item.bGrd)[0];
500 let addState = {}; 500 let addState = {};
@@ -516,7 +516,7 @@ export default (ChildComponent) => { @@ -516,7 +516,7 @@ export default (ChildComponent) => {
516 masterConfig, sId, pageLoading: false, ...addState, 516 masterConfig, sId, pageLoading: false, ...addState,
517 }); 517 });
518 } else if (commonUtils.isEmptyObject(slaveConfigOld) && commonUtils.isEmptyObject(masterConfigOld) && formData.length === 2 && (sModelsType === 'quality/accident') && formRoute.indexOf('indexOee') === -1) { 518 } else if (commonUtils.isEmptyObject(slaveConfigOld) && commonUtils.isEmptyObject(masterConfigOld) && formData.length === 2 && (sModelsType === 'quality/accident') && formRoute.indexOf('indexOee') === -1) {
519 - const sId = currentId !== undefined ? currentId : ''; 519 + const sId = currentId || nextProps.masterData?.sId || '';
520 /* 数据Id */ 520 /* 数据Id */
521 const masterConfig = formData.filter(item => !item.bGrd)[0]; 521 const masterConfig = formData.filter(item => !item.bGrd)[0];
522 const slaveConfig = formData.filter(item => item.bGrd && item.sTbName === 'mftqualityaccidentSlave')[0]; 522 const slaveConfig = formData.filter(item => item.bGrd && item.sTbName === 'mftqualityaccidentSlave')[0];
@@ -551,7 +551,7 @@ export default (ChildComponent) => { @@ -551,7 +551,7 @@ export default (ChildComponent) => {
551 // employeeConfig, employeeColumn, masterConfig, ...addState, 551 // employeeConfig, employeeColumn, masterConfig, ...addState,
552 // }); 552 // });
553 if (formRoute === '/indexOee/labelPrint' && commonUtils.isEmpty(slaveConfigOld)) { /* 入库标签打印 */ 553 if (formRoute === '/indexOee/labelPrint' && commonUtils.isEmpty(slaveConfigOld)) { /* 入库标签打印 */
554 - const sId = currentId !== undefined ? currentId : ''; 554 + const sId = currentId || nextProps.masterData?.sId || '';
555 /* 数据Id */ 555 /* 数据Id */
556 const masterConfig = formData[0]; 556 const masterConfig = formData[0];
557 const slaveConfig = formData[0]; 557 const slaveConfig = formData[0];
@@ -801,7 +801,7 @@ export default (ChildComponent) => { @@ -801,7 +801,7 @@ export default (ChildComponent) => {
801 /* 获取表数据 */ 801 /* 获取表数据 */
802 handleGetMemoData = async (controlConfig, materialsConfig, processConfig, colorConfig, packConfig) => { 802 handleGetMemoData = async (controlConfig, materialsConfig, processConfig, colorConfig, packConfig) => {
803 const { currentId, sModelsType } = this.props; /* 当前页签数据 */ 803 const { currentId, sModelsType } = this.props; /* 当前页签数据 */
804 - const sId = currentId !== undefined ? currentId : ''; /* 数据Id */ 804 + const sId = currentId || this.props.masterData?.sId || ''; /* 数据Id */
805 const addStateControl = await this.props.handleGetDataSet({ 805 const addStateControl = await this.props.handleGetDataSet({
806 name: 'control', configData: controlConfig, condition: { sSqlCondition: { sParentId: sId } }, isWait: true, 806 name: 'control', configData: controlConfig, condition: { sSqlCondition: { sParentId: sId } }, isWait: true,
807 }); 807 });
@@ -860,7 +860,7 @@ export default (ChildComponent) => { @@ -860,7 +860,7 @@ export default (ChildComponent) => {
860 /* 获取单张表数据 */ 860 /* 获取单张表数据 */
861 handleGetOneMemoData = (memoName, memoConfig) => { 861 handleGetOneMemoData = (memoName, memoConfig) => {
862 const { currentId } = this.props; /* 当前页签数据 */ 862 const { currentId } = this.props; /* 当前页签数据 */
863 - const sId = currentId !== undefined ? currentId : ''; /* 数据Id */ 863 + const sId = currentId || this.props.masterData?.sId || ''; /* 数据Id */
864 if (commonUtils.isNotEmptyObject(sId)) { /* 解决detail数据没有问题 */ 864 if (commonUtils.isNotEmptyObject(sId)) { /* 解决detail数据没有问题 */
865 this.props.handleGetDataSet({ 865 this.props.handleGetDataSet({
866 name: memoName, configData: memoConfig, condition: { sSqlCondition: { sParentId: sId } }, 866 name: memoName, configData: memoConfig, condition: { sSqlCondition: { sParentId: sId } },
src/components/Common/CommonCheckBillEvent.js
@@ -72,7 +72,7 @@ export default (ChildComponent) => { @@ -72,7 +72,7 @@ export default (ChildComponent) => {
72 employeeConfig: employeeConfigOld, 72 employeeConfig: employeeConfigOld,
73 } = nextProps; 73 } = nextProps;
74 if (commonUtils.isEmptyObject(slaveConfigOld) && formData.length > 0 && (sModelsType !== 'cashier/financialTransfer' && sModelsType !== 'cashier/financialAdjustment' && sModelsType !== 'quality/accident' && sModelsType !== 'purchase/purchaseEnquiry' && sModelsType !== 'complaint/complaint' && sModelsType !== 'print/printLabel' && sModelsType !== 'commonBill/onlyMaster' && (formRoute.indexOf('indexOee') === -1 || formRoute === '/indexOee/commonOeeBill'))) { 74 if (commonUtils.isEmptyObject(slaveConfigOld) && formData.length > 0 && (sModelsType !== 'cashier/financialTransfer' && sModelsType !== 'cashier/financialAdjustment' && sModelsType !== 'quality/accident' && sModelsType !== 'purchase/purchaseEnquiry' && sModelsType !== 'complaint/complaint' && sModelsType !== 'print/printLabel' && sModelsType !== 'commonBill/onlyMaster' && (formRoute.indexOf('indexOee') === -1 || formRoute === '/indexOee/commonOeeBill'))) {
75 - const sId = currentId !== undefined ? currentId : ''; 75 + const sId = currentId || nextProps.masterData?.sId || '';
76 /* 数据Id */ 76 /* 数据Id */
77 const masterConfig = formData.filter(item => !item.bGrd)[0]; 77 const masterConfig = formData.filter(item => !item.bGrd)[0];
78 const BtnDesignFunctionConfig = commonUtils.isNotEmptyObject(masterConfig) ? masterConfig.gdsconfigformslave.filter(item => item.sControlName === 'BtnBsOperation.BtnDesignFunction') : {}; 78 const BtnDesignFunctionConfig = commonUtils.isNotEmptyObject(masterConfig) ? masterConfig.gdsconfigformslave.filter(item => item.sControlName === 'BtnBsOperation.BtnDesignFunction') : {};
@@ -373,7 +373,7 @@ export default (ChildComponent) => { @@ -373,7 +373,7 @@ export default (ChildComponent) => {
373 }); 373 });
374 } else if (commonUtils.isEmptyObject(masterConfigOld) && formData.length === 1 && (sModelsType === 'cashier/financialTransfer' || sModelsType === 'purchase/purchaseEnquiry' || sModelsType === 'cashier/financialAdjustment' || sModelsType === 'print/printLabel' || sModelsType === 'complaint/complaint' || sModelsType === 'commonBill/onlyMaster') && formRoute.indexOf('indexOee') === -1) { 374 } else if (commonUtils.isEmptyObject(masterConfigOld) && formData.length === 1 && (sModelsType === 'cashier/financialTransfer' || sModelsType === 'purchase/purchaseEnquiry' || sModelsType === 'cashier/financialAdjustment' || sModelsType === 'print/printLabel' || sModelsType === 'complaint/complaint' || sModelsType === 'commonBill/onlyMaster') && formRoute.indexOf('indexOee') === -1) {
375 const config = {}; 375 const config = {};
376 - const sId = currentId !== undefined ? currentId : ''; 376 + const sId = currentId || nextProps.masterData?.sId || '';
377 /* 数据Id */ 377 /* 数据Id */
378 const masterConfig = formData.filter(item => !item.bGrd)[0]; 378 const masterConfig = formData.filter(item => !item.bGrd)[0];
379 let addState = {}; 379 let addState = {};
@@ -395,7 +395,7 @@ export default (ChildComponent) => { @@ -395,7 +395,7 @@ export default (ChildComponent) => {
395 masterConfig, sId, pageLoading: false, ...addState, 395 masterConfig, sId, pageLoading: false, ...addState,
396 }); 396 });
397 } else if (commonUtils.isEmptyObject(slaveConfigOld) && commonUtils.isEmptyObject(masterConfigOld) && formData.length === 2 && (sModelsType === 'quality/accident') && formRoute.indexOf('indexOee') === -1) { 397 } else if (commonUtils.isEmptyObject(slaveConfigOld) && commonUtils.isEmptyObject(masterConfigOld) && formData.length === 2 && (sModelsType === 'quality/accident') && formRoute.indexOf('indexOee') === -1) {
398 - const sId = currentId !== undefined ? currentId : ''; 398 + const sId = currentId || nextProps.masterData?.sId || '';
399 /* 数据Id */ 399 /* 数据Id */
400 const masterConfig = formData.filter(item => !item.bGrd)[0]; 400 const masterConfig = formData.filter(item => !item.bGrd)[0];
401 const slaveConfig = formData.filter(item => item.bGrd && item.sTbName === 'mftqualityaccidentSlave')[0]; 401 const slaveConfig = formData.filter(item => item.bGrd && item.sTbName === 'mftqualityaccidentSlave')[0];
@@ -430,7 +430,7 @@ export default (ChildComponent) => { @@ -430,7 +430,7 @@ export default (ChildComponent) => {
430 // employeeConfig, employeeColumn, masterConfig, ...addState, 430 // employeeConfig, employeeColumn, masterConfig, ...addState,
431 // }); 431 // });
432 if (formRoute === '/indexOee/labelPrint' && commonUtils.isEmpty(slaveConfigOld)) { /* 入库标签打印 */ 432 if (formRoute === '/indexOee/labelPrint' && commonUtils.isEmpty(slaveConfigOld)) { /* 入库标签打印 */
433 - const sId = currentId !== undefined ? currentId : ''; 433 + const sId = currentId || nextProps.masterData?.sId || '';
434 /* 数据Id */ 434 /* 数据Id */
435 const masterConfig = formData[0]; 435 const masterConfig = formData[0];
436 const slaveConfig = formData[0]; 436 const slaveConfig = formData[0];
@@ -618,7 +618,7 @@ export default (ChildComponent) => { @@ -618,7 +618,7 @@ export default (ChildComponent) => {
618 /** 获取主表、从表、审核表数据 */ 618 /** 获取主表、从表、审核表数据 */
619 handleGetData = async (masterConfig, slaveConfig, checkConfig, bEditClick) => { 619 handleGetData = async (masterConfig, slaveConfig, checkConfig, bEditClick) => {
620 const { currentId } = this.props; /* 当前页签数据 */ 620 const { currentId } = this.props; /* 当前页签数据 */
621 - const sId = currentId !== undefined ? currentId : ''; 621 + const sId = currentId || this.props.masterData?.sId || '';
622 const addStateMaster = await this.props.handleGetDataOne({ 622 const addStateMaster = await this.props.handleGetDataOne({
623 name: 'master', configData: masterConfig, condition: { sId, pageSize: '', pageNum: '' }, isWait: true, bEditClick, 623 name: 'master', configData: masterConfig, condition: { sId, pageSize: '', pageNum: '' }, isWait: true, bEditClick,
624 }); 624 });
@@ -669,7 +669,7 @@ export default (ChildComponent) => { @@ -669,7 +669,7 @@ export default (ChildComponent) => {
669 /* 获取表数据 */ 669 /* 获取表数据 */
670 handleGetMemoData = async (controlConfig, materialsConfig, processConfig, colorConfig, packConfig) => { 670 handleGetMemoData = async (controlConfig, materialsConfig, processConfig, colorConfig, packConfig) => {
671 const { currentId, sModelsType } = this.props; /* 当前页签数据 */ 671 const { currentId, sModelsType } = this.props; /* 当前页签数据 */
672 - const sId = currentId !== undefined ? currentId : ''; /* 数据Id */ 672 + const sId = currentId || this.props.masterData?.sId || ''; /* 数据Id */
673 let addStateControl = {}; 673 let addStateControl = {};
674 if (commonUtils.isNotEmptyObject(controlConfig)) { 674 if (commonUtils.isNotEmptyObject(controlConfig)) {
675 addStateControl = await this.props.handleGetDataSet({ 675 addStateControl = await this.props.handleGetDataSet({
@@ -732,7 +732,7 @@ export default (ChildComponent) => { @@ -732,7 +732,7 @@ export default (ChildComponent) => {
732 /* 获取单张表数据 */ 732 /* 获取单张表数据 */
733 handleGetOneMemoData = (memoName, memoConfig) => { 733 handleGetOneMemoData = (memoName, memoConfig) => {
734 const { currentId } = this.props; /* 当前页签数据 */ 734 const { currentId } = this.props; /* 当前页签数据 */
735 - const sId = currentId !== undefined ? currentId : ''; /* 数据Id */ 735 + const sId = currentId || this.props.masterData?.sId || ''; /* 数据Id */
736 if (commonUtils.isNotEmptyObject(sId)) { /* 解决detail数据没有问题 */ 736 if (commonUtils.isNotEmptyObject(sId)) { /* 解决detail数据没有问题 */
737 this.props.handleGetDataSet({ 737 this.props.handleGetDataSet({
738 name: memoName, configData: memoConfig, condition: { sSqlCondition: { sParentId: sId } }, 738 name: memoName, configData: memoConfig, condition: { sSqlCondition: { sParentId: sId } },
src/components/Common/CommonCostomTabBill.js
@@ -2556,7 +2556,7 @@ class CommonNewBill extends Component { @@ -2556,7 +2556,7 @@ class CommonNewBill extends Component {
2556 // 刷新工单交期 2556 // 刷新工单交期
2557 handleRefreshGdjq = async() => { 2557 handleRefreshGdjq = async() => {
2558 const { currentId, slave2Child0Config, slave2Child0InfoConfig } = this.props; 2558 const { currentId, slave2Child0Config, slave2Child0InfoConfig } = this.props;
2559 - const sId = currentId !== undefined ? currentId : ''; 2559 + const sId = currentId || this.props.masterData?.sId || '';
2560 const conditonValues1 = this.props.onGetSqlConditionValues(slave2Child0Config); 2560 const conditonValues1 = this.props.onGetSqlConditionValues(slave2Child0Config);
2561 let returnData1 = await this.props.handleGetDataSet({ 2561 let returnData1 = await this.props.handleGetDataSet({
2562 name: "slave2Child0", 2562 name: "slave2Child0",
src/components/Common/CommonElementEvent.js
@@ -35,7 +35,7 @@ export default (ChildComponent) => { @@ -35,7 +35,7 @@ export default (ChildComponent) => {
35 eleknifemouldproductConfig: eleknifemouldOldproductConfig, eleteststandarditemConfig: eleteststandardOlditemConfig, 35 eleknifemouldproductConfig: eleknifemouldOldproductConfig, eleteststandarditemConfig: eleteststandardOlditemConfig,
36 } = nextProps; 36 } = nextProps;
37 if (commonUtils.isEmptyObject(contactOldConfig) && (sModelsType === 'element/supplyInfo' || sModelsType === 'element/customerInfo') && formData.length > 0) { 37 if (commonUtils.isEmptyObject(contactOldConfig) && (sModelsType === 'element/supplyInfo' || sModelsType === 'element/customerInfo') && formData.length > 0) {
38 - const sId = currentId || this.props.masterData?.sId || ''; 38 + const sId = currentId || nextProps.masterData?.sId || '';
39 /* 数据Id */ 39 /* 数据Id */
40 const masterConfig = formData.filter(item => !item.bGrd)[0]; 40 const masterConfig = formData.filter(item => !item.bGrd)[0];
41 if (sModelsType === 'element/customerInfo') { 41 if (sModelsType === 'element/customerInfo') {
@@ -91,7 +91,7 @@ export default (ChildComponent) => { @@ -91,7 +91,7 @@ export default (ChildComponent) => {
91 } 91 }
92 } 92 }
93 if (commonUtils.isEmptyObject(supplyOldConfig) && formData.length > 0 && sModelsType === 'element/materialsInfo') { 93 if (commonUtils.isEmptyObject(supplyOldConfig) && formData.length > 0 && sModelsType === 'element/materialsInfo') {
94 - const sId = currentId || this.props.masterData?.sId || ''; 94 + const sId = currentId || nextProps.masterData?.sId || '';
95 /* 数据Id */ 95 /* 数据Id */
96 const masterConfig = formData.filter(item => !item.bGrd)[0]; 96 const masterConfig = formData.filter(item => !item.bGrd)[0];
97 /* bGrd代表是否是表格 */ 97 /* bGrd代表是否是表格 */
@@ -122,7 +122,7 @@ export default (ChildComponent) => { @@ -122,7 +122,7 @@ export default (ChildComponent) => {
122 } 122 }
123 /* 印件分类 */ 123 /* 印件分类 */
124 if (commonUtils.isEmptyObject(sisproductclassifyProcessClassifyConfig) && formData.length > 0 && sModelsType === 'element/sisproductclassify') { 124 if (commonUtils.isEmptyObject(sisproductclassifyProcessClassifyConfig) && formData.length > 0 && sModelsType === 'element/sisproductclassify') {
125 - const sId = currentId || this.props.masterData?.sId || ''; 125 + const sId = currentId || nextProps.masterData?.sId || '';
126 /* 数据Id */ 126 /* 数据Id */
127 const masterConfig = formData.filter(item => !item.bGrd)[0]; 127 const masterConfig = formData.filter(item => !item.bGrd)[0];
128 /* bGrd代表是否是表格 */ 128 /* bGrd代表是否是表格 */
@@ -147,7 +147,7 @@ export default (ChildComponent) => { @@ -147,7 +147,7 @@ export default (ChildComponent) => {
147 }); 147 });
148 } 148 }
149 if (commonUtils.isEmptyObject(masterConfig) && formData.length > 0 && sModelsType === 'element/processInfo') { 149 if (commonUtils.isEmptyObject(masterConfig) && formData.length > 0 && sModelsType === 'element/processInfo') {
150 - const sId = currentId || this.props.masterData?.sId || ''; 150 + const sId = currentId || nextProps.masterData?.sId || '';
151 /* 数据Id */ 151 /* 数据Id */
152 const masterConfig = formData.filter(item => !item.bGrd)[0]; 152 const masterConfig = formData.filter(item => !item.bGrd)[0];
153 /* bGrd代表是否是表格 */ 153 /* bGrd代表是否是表格 */
@@ -214,7 +214,7 @@ export default (ChildComponent) => { @@ -214,7 +214,7 @@ export default (ChildComponent) => {
214 }); 214 });
215 } 215 }
216 if (commonUtils.isEmptyObject(picFileOldConfig) && formData.length > 0 && sModelsType === 'element/printInfo') { 216 if (commonUtils.isEmptyObject(picFileOldConfig) && formData.length > 0 && sModelsType === 'element/printInfo') {
217 - const sId = currentId || this.props.masterData?.sId || ''; 217 + const sId = currentId || nextProps.masterData?.sId || '';
218 /* 数据Id */ 218 /* 数据Id */
219 const masterConfig = formData.filter(item => !item.bGrd)[0]; 219 const masterConfig = formData.filter(item => !item.bGrd)[0];
220 /* bGrd代表是否是表格 */ 220 /* bGrd代表是否是表格 */
@@ -250,7 +250,7 @@ export default (ChildComponent) => { @@ -250,7 +250,7 @@ export default (ChildComponent) => {
250 } 250 }
251 // 常用规格信息 commonUtils.isEmptyArr(siscommonstyleproductclassifyColumn) 251 // 常用规格信息 commonUtils.isEmptyArr(siscommonstyleproductclassifyColumn)
252 if (commonUtils.isEmptyObject(siscommonstyleproductclassifyConfig) && formData.length > 0 && sModelsType === 'element/siscommonstyle') { 252 if (commonUtils.isEmptyObject(siscommonstyleproductclassifyConfig) && formData.length > 0 && sModelsType === 'element/siscommonstyle') {
253 - const sId = currentId || this.props.masterData?.sId || ''; 253 + const sId = currentId || nextProps.masterData?.sId || '';
254 /* 数据Id */ 254 /* 数据Id */
255 const masterConfig = formData.filter(item => !item.bGrd)[0]; 255 const masterConfig = formData.filter(item => !item.bGrd)[0];
256 /* bGrd代表是否是表格 */ 256 /* bGrd代表是否是表格 */
@@ -276,7 +276,7 @@ export default (ChildComponent) => { @@ -276,7 +276,7 @@ export default (ChildComponent) => {
276 } 276 }
277 // 班组信息 277 // 班组信息
278 if (commonUtils.isEmptyObject(eleemployeeOldConfig) && formData.length > 0 && sModelsType === 'element/teamInfo') { 278 if (commonUtils.isEmptyObject(eleemployeeOldConfig) && formData.length > 0 && sModelsType === 'element/teamInfo') {
279 - const sId = currentId || this.props.masterData?.sId || ''; 279 + const sId = currentId || nextProps.masterData?.sId || '';
280 const masterConfig = formData.filter(item => !item.bGrd && item.sTbName === 'eleteam')[0]; 280 const masterConfig = formData.filter(item => !item.bGrd && item.sTbName === 'eleteam')[0];
281 const eleemployeeConfig = formData.filter(item => item.bGrd && item.sTbName === 'eleteamemployee')[0]; 281 const eleemployeeConfig = formData.filter(item => item.bGrd && item.sTbName === 'eleteamemployee')[0];
282 const eleemployeeColumn = commonFunc.getHeaderConfig(eleemployeeConfig); 282 const eleemployeeColumn = commonFunc.getHeaderConfig(eleemployeeConfig);
@@ -306,7 +306,7 @@ export default (ChildComponent) => { @@ -306,7 +306,7 @@ export default (ChildComponent) => {
306 }); 306 });
307 } 307 }
308 if (commonUtils.isEmptyObject(jurgroupOldConfig) && formData.length > 0 && sModelsType === 'element/sftloginInfo') { 308 if (commonUtils.isEmptyObject(jurgroupOldConfig) && formData.length > 0 && sModelsType === 'element/sftloginInfo') {
309 - const sId = currentId || this.props.masterData?.sId || ''; 309 + const sId = currentId || nextProps.masterData?.sId || '';
310 /* 数据Id */ 310 /* 数据Id */
311 const masterConfig = formData.filter(item => !item.bGrd)[0]; 311 const masterConfig = formData.filter(item => !item.bGrd)[0];
312 /* bGrd代表是否是表格 */ 312 /* bGrd代表是否是表格 */
@@ -382,7 +382,7 @@ export default (ChildComponent) => { @@ -382,7 +382,7 @@ export default (ChildComponent) => {
382 }); 382 });
383 } 383 }
384 if ((bReceived === undefined || !bReceived) && formData.length > 0 && sModelsType === 'system/sisformulaInfo') { 384 if ((bReceived === undefined || !bReceived) && formData.length > 0 && sModelsType === 'system/sisformulaInfo') {
385 - const sId = currentId || this.props.masterData?.sId || ''; 385 + const sId = currentId || nextProps.masterData?.sId || '';
386 const masterConfig = formData.filter(item => !item.bGrd && item.sTbName === 'sisformula')[0]; 386 const masterConfig = formData.filter(item => !item.bGrd && item.sTbName === 'sisformula')[0];
387 const paramConfig = formData.filter(item => item.bGrd && item.sTbName === 'sisformulaparam')[0]; 387 const paramConfig = formData.filter(item => item.bGrd && item.sTbName === 'sisformulaparam')[0];
388 let customizeParamConfig = commonUtils.isNotEmptyArr(formData.filter(item => item.bGrd && item.sTbName === 'sisformulacustomizeparam')) ? formData.filter(item => item.bGrd && item.sTbName === 'sisformulacustomizeparam')[0] : {}; 388 let customizeParamConfig = commonUtils.isNotEmptyArr(formData.filter(item => item.bGrd && item.sTbName === 'sisformulacustomizeparam')) ? formData.filter(item => item.bGrd && item.sTbName === 'sisformulacustomizeparam')[0] : {};
@@ -553,7 +553,7 @@ export default (ChildComponent) => { @@ -553,7 +553,7 @@ export default (ChildComponent) => {
553 }); 553 });
554 } 554 }
555 if ((bReceived === undefined || !bReceived) && formData.length > 0 && sModelsType === 'element/machineInfo') { 555 if ((bReceived === undefined || !bReceived) && formData.length > 0 && sModelsType === 'element/machineInfo') {
556 - const sId = currentId || this.props.masterData?.sId || ''; 556 + const sId = currentId || nextProps.masterData?.sId || '';
557 const masterConfig = formData.filter(item => !item.bGrd && item.sTbName === 'elemachine')[0]; 557 const masterConfig = formData.filter(item => !item.bGrd && item.sTbName === 'elemachine')[0];
558 let addState = {}; 558 let addState = {};
559 let slaveConfig = {}; 559 let slaveConfig = {};
@@ -627,7 +627,7 @@ export default (ChildComponent) => { @@ -627,7 +627,7 @@ export default (ChildComponent) => {
627 }); 627 });
628 } 628 }
629 if (commonUtils.isEmptyObject(userOldConfig) && formData.length > 0 && sModelsType === 'element/checkModelInfo') { 629 if (commonUtils.isEmptyObject(userOldConfig) && formData.length > 0 && sModelsType === 'element/checkModelInfo') {
630 - const sId = currentId || this.props.masterData?.sId || ''; 630 + const sId = currentId || nextProps.masterData?.sId || '';
631 /* 数据Id */ 631 /* 数据Id */
632 const masterConfig = formData.filter(item => !item.bGrd && item.sTbName === 'elecheckmodel')[0]; 632 const masterConfig = formData.filter(item => !item.bGrd && item.sTbName === 'elecheckmodel')[0];
633 /* bGrd代表是否是表格 */ 633 /* bGrd代表是否是表格 */
@@ -662,7 +662,7 @@ export default (ChildComponent) => { @@ -662,7 +662,7 @@ export default (ChildComponent) => {
662 }); 662 });
663 } 663 }
664 if (commonUtils.isEmptyObject(sischeckphaselogininfoOldConfig) && formData.length > 0 && sModelsType === 'element/checkPhaseInfo') { 664 if (commonUtils.isEmptyObject(sischeckphaselogininfoOldConfig) && formData.length > 0 && sModelsType === 'element/checkPhaseInfo') {
665 - const sId = currentId || this.props.masterData?.sId || ''; 665 + const sId = currentId || nextProps.masterData?.sId || '';
666 /* 数据Id */ 666 /* 数据Id */
667 const masterConfig = formData.filter(item => !item.bGrd && item.sTbName === 'sischeckphase')[0]; 667 const masterConfig = formData.filter(item => !item.bGrd && item.sTbName === 'sischeckphase')[0];
668 /* bGrd代表是否是表格 */ 668 /* bGrd代表是否是表格 */
@@ -687,7 +687,7 @@ export default (ChildComponent) => { @@ -687,7 +687,7 @@ export default (ChildComponent) => {
687 }); 687 });
688 } 688 }
689 if ((bReceived === undefined || !bReceived) && formData.length > 0 && sModelsType === 'sis/paymentTerms') { 689 if ((bReceived === undefined || !bReceived) && formData.length > 0 && sModelsType === 'sis/paymentTerms') {
690 - const sId = currentId || this.props.masterData?.sId || ''; 690 + const sId = currentId || nextProps.masterData?.sId || '';
691 const masterConfig = formData.filter(item => !item.bGrd && item.sTbName === 'sispayment')[0]; 691 const masterConfig = formData.filter(item => !item.bGrd && item.sTbName === 'sispayment')[0];
692 692
693 const firstRow = masterConfig.gdsconfigformslave.filter(item => item.bVisible && item.sName === 'sName'); 693 const firstRow = masterConfig.gdsconfigformslave.filter(item => item.bVisible && item.sName === 'sName');
@@ -713,7 +713,7 @@ export default (ChildComponent) => { @@ -713,7 +713,7 @@ export default (ChildComponent) => {
713 }); 713 });
714 } 714 }
715 if (commonUtils.isEmptyObject(employeeConfig) && formData.length > 0 && sModelsType === 'element/employeeInfo') { 715 if (commonUtils.isEmptyObject(employeeConfig) && formData.length > 0 && sModelsType === 'element/employeeInfo') {
716 - const sId = currentId || this.props.masterData?.sId || ''; 716 + const sId = currentId || nextProps.masterData?.sId || '';
717 /* 数据Id */ 717 /* 数据Id */
718 const masterConfig = formData.filter(item => !item.bGrd)[0]; 718 const masterConfig = formData.filter(item => !item.bGrd)[0];
719 /* bGrd代表是否是表格 */ 719 /* bGrd代表是否是表格 */
@@ -735,7 +735,7 @@ export default (ChildComponent) => { @@ -735,7 +735,7 @@ export default (ChildComponent) => {
735 }); 735 });
736 } 736 }
737 if (formData.length > 0 && commonUtils.isEmptyObject(sysmsguserOldConfig) && sModelsType === 'smg/sendMailMsg') { 737 if (formData.length > 0 && commonUtils.isEmptyObject(sysmsguserOldConfig) && sModelsType === 'smg/sendMailMsg') {
738 - const sId = currentId || this.props.masterData?.sId || ''; 738 + const sId = currentId || nextProps.masterData?.sId || '';
739 /* 数据Id */ 739 /* 数据Id */
740 const masterConfig = formData.filter(item => !item.bGrd)[0]; 740 const masterConfig = formData.filter(item => !item.bGrd)[0];
741 741
@@ -762,7 +762,7 @@ export default (ChildComponent) => { @@ -762,7 +762,7 @@ export default (ChildComponent) => {
762 }); 762 });
763 } 763 }
764 if (formData.length > 0 && commonUtils.isEmptyObject(masterConfig) && sModelsType === 'sis/monthEndingClosing') { 764 if (formData.length > 0 && commonUtils.isEmptyObject(masterConfig) && sModelsType === 'sis/monthEndingClosing') {
765 - const sId = currentId || this.props.masterData?.sId || ''; 765 + const sId = currentId || nextProps.masterData?.sId || '';
766 masterConfig = formData.filter(item => !item.bGrd)[0]; 766 masterConfig = formData.filter(item => !item.bGrd)[0];
767 767
768 const firstRow = masterConfig.gdsconfigformslave[0]; 768 const firstRow = masterConfig.gdsconfigformslave[0];
@@ -784,7 +784,7 @@ export default (ChildComponent) => { @@ -784,7 +784,7 @@ export default (ChildComponent) => {
784 } 784 }
785 /* 刀模信息 */ 785 /* 刀模信息 */
786 if (commonUtils.isEmptyObject(eleknifemouldOldproductConfig) && formData.length > 0 && sModelsType === 'element/knifemouldInfo') { 786 if (commonUtils.isEmptyObject(eleknifemouldOldproductConfig) && formData.length > 0 && sModelsType === 'element/knifemouldInfo') {
787 - const sId = currentId || this.props.masterData?.sId || ''; 787 + const sId = currentId || nextProps.masterData?.sId || '';
788 /* 数据Id */ 788 /* 数据Id */
789 const masterConfig = formData.filter(item => !item.bGrd)[0]; 789 const masterConfig = formData.filter(item => !item.bGrd)[0];
790 /* bGrd代表是否是表格 */ 790 /* bGrd代表是否是表格 */
@@ -821,7 +821,7 @@ export default (ChildComponent) => { @@ -821,7 +821,7 @@ export default (ChildComponent) => {
821 } 821 }
822 /* 检验标准 */ 822 /* 检验标准 */
823 if (commonUtils.isEmptyObject(eleteststandardOlditemConfig) && formData.length > 0 && sModelsType === 'element/eleteststandInfo') { 823 if (commonUtils.isEmptyObject(eleteststandardOlditemConfig) && formData.length > 0 && sModelsType === 'element/eleteststandInfo') {
824 - const sId = currentId || this.props.masterData?.sId || ''; 824 + const sId = currentId || nextProps.masterData?.sId || '';
825 /* 数据Id */ 825 /* 数据Id */
826 const masterConfig = formData.filter(item => !item.bGrd)[0]; 826 const masterConfig = formData.filter(item => !item.bGrd)[0];
827 /* bGrd代表是否是表格 */ 827 /* bGrd代表是否是表格 */
src/components/Common/CommonGroupBillEvent.js
@@ -64,7 +64,7 @@ export default (ChildComponent) => { @@ -64,7 +64,7 @@ export default (ChildComponent) => {
64 } = nextProps; 64 } = nextProps;
65 const { masterConfig: masterConfigOld, app } = nextProps; 65 const { masterConfig: masterConfigOld, app } = nextProps;
66 if (commonUtils.isEmptyObject(masterConfigOld) && formData.length > 0) { 66 if (commonUtils.isEmptyObject(masterConfigOld) && formData.length > 0) {
67 - const sId = currentId !== undefined ? currentId : ''; 67 + const sId = currentId || nextProps.masterData?.sId || '';
68 const masterConfig = formData.filter(item => !item.bGrd)[0]; 68 const masterConfig = formData.filter(item => !item.bGrd)[0];
69 69
70 const sReasonTitle = commonUtils.isNotEmptyObject(commonFunc.showMessage(app.commonConst, 'sReason'))? 70 const sReasonTitle = commonUtils.isNotEmptyObject(commonFunc.showMessage(app.commonConst, 'sReason'))?
@@ -360,7 +360,7 @@ export default (ChildComponent) => { @@ -360,7 +360,7 @@ export default (ChildComponent) => {
360 /** 获取主表、从表、审核表数据 */ 360 /** 获取主表、从表、审核表数据 */
361 handleGetData = async (masterConfig, slaveConfig, slave0Config, slave1Config, slave2Config, slave3Config, slave4Config, bEditClick, slave5Config, slave6Config, slave7Config, slave8Config, slave9Config, slave10Config) => { 361 handleGetData = async (masterConfig, slaveConfig, slave0Config, slave1Config, slave2Config, slave3Config, slave4Config, bEditClick, slave5Config, slave6Config, slave7Config, slave8Config, slave9Config, slave10Config) => {
362 const { currentId, app } = this.props; /* 当前页签数据 */ 362 const { currentId, app } = this.props; /* 当前页签数据 */
363 - const sId = currentId !== undefined ? currentId : ''; 363 + const sId = currentId || this.props.masterData?.sId || '';
364 const { sModelsId, masterData, sModelsType, slaveSelectedRowKeys } = this.props; 364 const { sModelsId, masterData, sModelsType, slaveSelectedRowKeys } = this.props;
365 await this.props.handleGetDataOne({ name: 'master', configData: masterConfig, condition: { sId, pageSize: '', pageNum: '' }, bEditClick }); 365 await this.props.handleGetDataOne({ name: 'master', configData: masterConfig, condition: { sId, pageSize: '', pageNum: '' }, bEditClick });
366 let addStateSlave = {}; 366 let addStateSlave = {};
@@ -530,7 +530,7 @@ export default (ChildComponent) => { @@ -530,7 +530,7 @@ export default (ChildComponent) => {
530 /* 获取表数据 */ 530 /* 获取表数据 */
531 handleGetMemoData = async (slaveConfig, slave0Config, slave1Config, slave2Config, slave3Config, slave4Config) => { 531 handleGetMemoData = async (slaveConfig, slave0Config, slave1Config, slave2Config, slave3Config, slave4Config) => {
532 const { currentId } = this.props; /* 当前页签数据 */ 532 const { currentId } = this.props; /* 当前页签数据 */
533 - const sId = currentId !== undefined ? currentId : ''; /* 数据Id */ 533 + const sId = currentId || this.props.masterData?.sId || ''; /* 数据Id */
534 const addStateSlave = slaveConfig ? await this.props.handleGetDataSet({ 534 const addStateSlave = slaveConfig ? await this.props.handleGetDataSet({
535 name: 'slave', configData: slaveConfig, condition: { sSqlCondition: { sParentId: sId } }, isWait: true, 535 name: 'slave', configData: slaveConfig, condition: { sSqlCondition: { sParentId: sId } }, isWait: true,
536 }) : ''; 536 }) : '';
@@ -564,7 +564,7 @@ export default (ChildComponent) => { @@ -564,7 +564,7 @@ export default (ChildComponent) => {
564 /* 获取单张表数据 */ 564 /* 获取单张表数据 */
565 handleGetOneMemoData = (memoName, memoConfig) => { 565 handleGetOneMemoData = (memoName, memoConfig) => {
566 const { currentId } = this.props; /* 当前页签数据 */ 566 const { currentId } = this.props; /* 当前页签数据 */
567 - const sId = currentId !== undefined ? currentId : ''; /* 数据Id */ 567 + const sId = currentId || this.props.masterData?.sId || ''; /* 数据Id */
568 if (commonUtils.isNotEmptyObject(sId)) { /* 解决detail数据没有问题 */ 568 if (commonUtils.isNotEmptyObject(sId)) { /* 解决detail数据没有问题 */
569 this.props.handleGetDataSet({ 569 this.props.handleGetDataSet({
570 name: memoName, configData: memoConfig, condition: { sSqlCondition: { sParentId: sId } }, 570 name: memoName, configData: memoConfig, condition: { sSqlCondition: { sParentId: sId } },
src/components/Common/CommonJurisdictionEvent.js
@@ -22,7 +22,7 @@ export default (ChildComponent) => { @@ -22,7 +22,7 @@ export default (ChildComponent) => {
22 formData, currentId, groupConfig, treeData, 22 formData, currentId, groupConfig, treeData,
23 } = nextProps; 23 } = nextProps;
24 let { bReceived } = nextProps; 24 let { bReceived } = nextProps;
25 - const sId = currentId !== undefined ? currentId : ''; 25 + const sId = currentId || nextProps.masterData?.sId || '';
26 26
27 if (commonUtils.isEmptyObject(groupConfig) && bReceived === undefined) { 27 if (commonUtils.isEmptyObject(groupConfig) && bReceived === undefined) {
28 const masterConfig = formData.filter(item => !item.bGrd)[0]; 28 const masterConfig = formData.filter(item => !item.bGrd)[0];
@@ -199,7 +199,7 @@ export default (ChildComponent) => { @@ -199,7 +199,7 @@ export default (ChildComponent) => {
199 handleGetSlaveData = (getType, sName, currConfig) => { 199 handleGetSlaveData = (getType, sName, currConfig) => {
200 const { currentId } = this.props; 200 const { currentId } = this.props;
201 /* 当前页签数据 */ 201 /* 当前页签数据 */
202 - const sId = currentId !== undefined ? currentId : ''; 202 + const sId = currentId || this.props.masterData?.sId || '';
203 if (getType === 'One') { 203 if (getType === 'One') {
204 this.props.handleGetDataOne({ 204 this.props.handleGetDataOne({
205 name: 'master', configData: currConfig, condition: { sId, pageSize: '', pageNum: '' }, 205 name: 'master', configData: currConfig, condition: { sId, pageSize: '', pageNum: '' },
src/components/Common/CommonJurisdictionNewEvent.js
@@ -23,7 +23,7 @@ export default (ChildComponent) => { @@ -23,7 +23,7 @@ export default (ChildComponent) => {
23 formData, currentId, groupConfig, treeData, formRoute, 23 formData, currentId, groupConfig, treeData, formRoute,
24 } = nextProps; 24 } = nextProps;
25 let { bReceived } = nextProps; 25 let { bReceived } = nextProps;
26 - const sId = currentId !== undefined ? currentId : ''; 26 + const sId = currentId || nextProps.masterData?.sId || '';
27 27
28 if (commonUtils.isEmptyObject(groupConfig) && bReceived === undefined) { 28 if (commonUtils.isEmptyObject(groupConfig) && bReceived === undefined) {
29 const masterConfig = formData.filter(item => !item.bGrd)[0]; 29 const masterConfig = formData.filter(item => !item.bGrd)[0];
@@ -228,7 +228,7 @@ export default (ChildComponent) => { @@ -228,7 +228,7 @@ export default (ChildComponent) => {
228 handleGetSlaveData = (getType, sName, currConfig) => { 228 handleGetSlaveData = (getType, sName, currConfig) => {
229 const { currentId } = this.props; 229 const { currentId } = this.props;
230 /* 当前页签数据 */ 230 /* 当前页签数据 */
231 - const sId = currentId !== undefined ? currentId : ''; 231 + const sId = currentId || this.props.masterData?.sId || '';
232 if (getType === 'One') { 232 if (getType === 'One') {
233 this.props.handleGetDataOne({ 233 this.props.handleGetDataOne({
234 name: 'master', configData: currConfig, condition: { sId, pageSize: '', pageNum: '' }, 234 name: 'master', configData: currConfig, condition: { sId, pageSize: '', pageNum: '' },
src/components/Common/CommonListEditEvent.js
@@ -65,7 +65,7 @@ export default (ChildComponent) => { @@ -65,7 +65,7 @@ export default (ChildComponent) => {
65 } 65 }
66 } 66 }
67 if (commonUtils.isEmptyObject(slaveConfigOld) && formData.length > 0 && (formRoute.indexOf('/indexOee') > -1 || searchSolution !== undefined)) { 67 if (commonUtils.isEmptyObject(slaveConfigOld) && formData.length > 0 && (formRoute.indexOf('/indexOee') > -1 || searchSolution !== undefined)) {
68 - const sId = currentId !== undefined ? currentId : ''; 68 + const sId = currentId || nextProps.masterData?.sId || '';
69 /* 数据Id */ 69 /* 数据Id */
70 const slaveConfig = formData[0]; 70 const slaveConfig = formData[0];
71 let addState = {}; 71 let addState = {};
src/components/Common/CommonListEvent.js
@@ -65,7 +65,7 @@ export default (ChildComponent) => { @@ -65,7 +65,7 @@ export default (ChildComponent) => {
65 } 65 }
66 } 66 }
67 if (commonUtils.isEmptyObject(slaveConfigOld) && formData.length > 0 && (formRoute.indexOf('/indexOee') > -1 || searchSolution !== undefined)) { 67 if (commonUtils.isEmptyObject(slaveConfigOld) && formData.length > 0 && (formRoute.indexOf('/indexOee') > -1 || searchSolution !== undefined)) {
68 - const sId = currentId !== undefined ? currentId : ''; 68 + const sId = currentId || nextProps.masterData?.sId || '';
69 /* 数据Id */ 69 /* 数据Id */
70 const slaveConfig = formData[0]; 70 const slaveConfig = formData[0];
71 let addState = {}; 71 let addState = {};
src/components/Common/CommonListTabEvent.js
@@ -65,7 +65,7 @@ export default (ChildComponent) => { @@ -65,7 +65,7 @@ export default (ChildComponent) => {
65 } 65 }
66 } 66 }
67 if (commonUtils.isEmptyObject(slaveConfigOld) && formData.length > 0 && (formRoute.indexOf('/indexOee') > -1 || searchSolution !== undefined)) { 67 if (commonUtils.isEmptyObject(slaveConfigOld) && formData.length > 0 && (formRoute.indexOf('/indexOee') > -1 || searchSolution !== undefined)) {
68 - const sId = currentId !== undefined ? currentId : ''; 68 + const sId = currentId || nextProps.masterData?.sId || '';
69 /* 数据Id */ 69 /* 数据Id */
70 const slaveConfig = formData[0]; 70 const slaveConfig = formData[0];
71 let addState = {}; 71 let addState = {};
src/components/Common/CommonListTreeEvent.js
@@ -58,7 +58,7 @@ export default (ChildComponent) => { @@ -58,7 +58,7 @@ export default (ChildComponent) => {
58 let { iPageSize } = nextProps; 58 let { iPageSize } = nextProps;
59 59
60 if (commonUtils.isEmptyObject(slaveConfigOld) && formData.length > 0 && (formRoute.indexOf('/indexOee') > -1 || searchSolution !== undefined)) { 60 if (commonUtils.isEmptyObject(slaveConfigOld) && formData.length > 0 && (formRoute.indexOf('/indexOee') > -1 || searchSolution !== undefined)) {
61 - const sId = currentId !== undefined ? currentId : ''; 61 + const sId = currentId || nextProps.masterData?.sId || '';
62 /* 数据Id */ 62 /* 数据Id */
63 const slaveConfig = formData[0]; 63 const slaveConfig = formData[0];
64 const addState = {}; 64 const addState = {};
src/components/Common/CommonNewBillEvent.js
@@ -66,7 +66,7 @@ export default (ChildComponent) => { @@ -66,7 +66,7 @@ export default (ChildComponent) => {
66 } = nextProps; 66 } = nextProps;
67 const { masterConfig: masterConfigOld, app } = nextProps; 67 const { masterConfig: masterConfigOld, app } = nextProps;
68 if (commonUtils.isEmptyObject(masterConfigOld) && formData.length > 0) { 68 if (commonUtils.isEmptyObject(masterConfigOld) && formData.length > 0) {
69 - const sId = currentId !== undefined ? currentId : ''; 69 + const sId = currentId || nextProps.masterData?.sId || '';
70 const masterConfig = formData.filter(item => !item.bGrd)[0]; 70 const masterConfig = formData.filter(item => !item.bGrd)[0];
71 71
72 const sReasonTitle = commonUtils.isNotEmptyObject(commonFunc.showMessage(app.commonConst, 'sReason'))? 72 const sReasonTitle = commonUtils.isNotEmptyObject(commonFunc.showMessage(app.commonConst, 'sReason'))?
@@ -593,7 +593,7 @@ export default (ChildComponent) => { @@ -593,7 +593,7 @@ export default (ChildComponent) => {
593 /* 获取表数据 */ 593 /* 获取表数据 */
594 handleGetMemoData = async (slaveConfig, slave0Config, slave1Config, slave2Config, slave3Config, slave4Config) => { 594 handleGetMemoData = async (slaveConfig, slave0Config, slave1Config, slave2Config, slave3Config, slave4Config) => {
595 const { currentId } = this.props; /* 当前页签数据 */ 595 const { currentId } = this.props; /* 当前页签数据 */
596 - const sId = currentId !== undefined ? currentId : ''; /* 数据Id */ 596 + const sId = currentId || this.props.masterData?.sId || ''; /* 数据Id */
597 const addStateSlave = slaveConfig ? await this.props.handleGetDataSet({ 597 const addStateSlave = slaveConfig ? await this.props.handleGetDataSet({
598 name: 'slave', configData: slaveConfig, condition: { sSqlCondition: { sParentId: sId } }, isWait: true, 598 name: 'slave', configData: slaveConfig, condition: { sSqlCondition: { sParentId: sId } }, isWait: true,
599 }) : ''; 599 }) : '';
@@ -627,7 +627,7 @@ export default (ChildComponent) => { @@ -627,7 +627,7 @@ export default (ChildComponent) => {
627 /* 获取单张表数据 */ 627 /* 获取单张表数据 */
628 handleGetOneMemoData = (memoName, memoConfig) => { 628 handleGetOneMemoData = (memoName, memoConfig) => {
629 const { currentId } = this.props; /* 当前页签数据 */ 629 const { currentId } = this.props; /* 当前页签数据 */
630 - const sId = currentId !== undefined ? currentId : ''; /* 数据Id */ 630 + const sId = currentId || this.props.masterData?.sId || ''; /* 数据Id */
631 if (commonUtils.isNotEmptyObject(sId)) { /* 解决detail数据没有问题 */ 631 if (commonUtils.isNotEmptyObject(sId)) { /* 解决detail数据没有问题 */
632 this.props.handleGetDataSet({ 632 this.props.handleGetDataSet({
633 name: memoName, configData: memoConfig, condition: { sSqlCondition: { sParentId: sId } }, 633 name: memoName, configData: memoConfig, condition: { sSqlCondition: { sParentId: sId } },
src/components/Common/CommonNewTabBillEvent.js
@@ -65,7 +65,7 @@ export default (ChildComponent) => { @@ -65,7 +65,7 @@ export default (ChildComponent) => {
65 } = nextProps; 65 } = nextProps;
66 const { masterConfig: masterConfigOld, app } = nextProps; 66 const { masterConfig: masterConfigOld, app } = nextProps;
67 if (commonUtils.isEmptyObject(masterConfigOld) && formData.length > 0) { 67 if (commonUtils.isEmptyObject(masterConfigOld) && formData.length > 0) {
68 - const sId = currentId !== undefined ? currentId : ''; 68 + const sId = currentId || nextProps.masterData?.sId || '';
69 const masterConfig = formData.filter(item => !item.bGrd)[0]; 69 const masterConfig = formData.filter(item => !item.bGrd)[0];
70 70
71 const sReasonTitle = commonUtils.isNotEmptyObject(commonFunc.showMessage(app.commonConst, 'sReason'))? 71 const sReasonTitle = commonUtils.isNotEmptyObject(commonFunc.showMessage(app.commonConst, 'sReason'))?
@@ -514,7 +514,7 @@ export default (ChildComponent) => { @@ -514,7 +514,7 @@ export default (ChildComponent) => {
514 } 514 }
515 515
516 const { currentId, app } = this.props; /* 当前页签数据 */ 516 const { currentId, app } = this.props; /* 当前页签数据 */
517 - const sId = currentId !== undefined ? currentId : ''; 517 + const sId = currentId || this.props.masterData?.sId || '';
518 const { sModelsId, masterData, sModelsType, slaveSelectedRowKeys } = this.props; 518 const { sModelsId, masterData, sModelsType, slaveSelectedRowKeys } = this.props;
519 const conditonValues = this.handleGetSqlConditionValues(masterConfig) 519 const conditonValues = this.handleGetSqlConditionValues(masterConfig)
520 await this.props.handleGetDataOne({ name: 'master', configData: masterConfig, condition: { sSqlCondition: { ...conditonValues }, sId, pageSize: '', pageNum: '' }, bEditClick }); 520 await this.props.handleGetDataOne({ name: 'master', configData: masterConfig, condition: { sSqlCondition: { ...conditonValues }, sId, pageSize: '', pageNum: '' }, bEditClick });
@@ -707,7 +707,7 @@ export default (ChildComponent) => { @@ -707,7 +707,7 @@ export default (ChildComponent) => {
707 707
708 handleGetData1 = async (configArr, bEditClick, other, isWait) => { 708 handleGetData1 = async (configArr, bEditClick, other, isWait) => {
709 const { currentId } = this.props; /* 当前页签数据 */ 709 const { currentId } = this.props; /* 当前页签数据 */
710 - const sId = currentId !== undefined ? currentId : ''; 710 + const sId = currentId || this.props.masterData?.sId || '';
711 711
712 let addState = {}; 712 let addState = {};
713 713
@@ -846,7 +846,7 @@ export default (ChildComponent) => { @@ -846,7 +846,7 @@ export default (ChildComponent) => {
846 /* 获取表数据 */ 846 /* 获取表数据 */
847 handleGetMemoData = async (slaveConfig, slave0Config, slave1Config, slave2Config, slave3Config, slave4Config) => { 847 handleGetMemoData = async (slaveConfig, slave0Config, slave1Config, slave2Config, slave3Config, slave4Config) => {
848 const { currentId } = this.props; /* 当前页签数据 */ 848 const { currentId } = this.props; /* 当前页签数据 */
849 - const sId = currentId !== undefined ? currentId : ''; /* 数据Id */ 849 + const sId = currentId || this.props.masterData?.sId || ''; /* 数据Id */
850 const addStateSlave = slaveConfig ? await this.props.handleGetDataSet({ 850 const addStateSlave = slaveConfig ? await this.props.handleGetDataSet({
851 name: 'slave', configData: slaveConfig, condition: { sSqlCondition: { ...this.handleGetSqlConditionValues(slaveConfig), sParentId: sId } }, isWait: true, 851 name: 'slave', configData: slaveConfig, condition: { sSqlCondition: { ...this.handleGetSqlConditionValues(slaveConfig), sParentId: sId } }, isWait: true,
852 }) : ''; 852 }) : '';
@@ -880,7 +880,7 @@ export default (ChildComponent) => { @@ -880,7 +880,7 @@ export default (ChildComponent) => {
880 /* 获取单张表数据 */ 880 /* 获取单张表数据 */
881 handleGetOneMemoData = (memoName, memoConfig) => { 881 handleGetOneMemoData = (memoName, memoConfig) => {
882 const { currentId } = this.props; /* 当前页签数据 */ 882 const { currentId } = this.props; /* 当前页签数据 */
883 - const sId = currentId !== undefined ? currentId : ''; /* 数据Id */ 883 + const sId = currentId || this.props.masterData?.sId || ''; /* 数据Id */
884 if (commonUtils.isNotEmptyObject(sId)) { /* 解决detail数据没有问题 */ 884 if (commonUtils.isNotEmptyObject(sId)) { /* 解决detail数据没有问题 */
885 this.props.handleGetDataSet({ 885 this.props.handleGetDataSet({
886 name: memoName, configData: memoConfig, condition: { sSqlCondition: { ...this.handleGetSqlConditionValues(memoConfig), sParentId: sId } }, 886 name: memoName, configData: memoConfig, condition: { sSqlCondition: { ...this.handleGetSqlConditionValues(memoConfig), sParentId: sId } },
src/components/Common/CommonProductionPlanEvent.js
@@ -34,7 +34,7 @@ export default (ChildComponent) => { @@ -34,7 +34,7 @@ export default (ChildComponent) => {
34 const { otherCondition } = currentPane; 34 const { otherCondition } = currentPane;
35 if (formData.length > 0 && commonUtils.isEmptyObject(teamConfig) && commonUtils.isEmptyArr(searchSolution)) { 35 if (formData.length > 0 && commonUtils.isEmptyObject(teamConfig) && commonUtils.isEmptyArr(searchSolution)) {
36 isReceive = false; 36 isReceive = false;
37 - const sId = currentId !== undefined ? currentId : ''; 37 + const sId = currentId || nextProps.masterData?.sId || '';
38 const masterConfig = formData.filter(item => !item.bGrd && item.sTbName === 'eleteam')[0]; 38 const masterConfig = formData.filter(item => !item.bGrd && item.sTbName === 'eleteam')[0];
39 39
40 teamConfig = formData.filter(item => item.sTbName === 'Sp_Manufacture_ProductionPlanInfo_WorkCenter')[0]; 40 teamConfig = formData.filter(item => item.sTbName === 'Sp_Manufacture_ProductionPlanInfo_WorkCenter')[0];
src/components/Common/CommonProductionPlanOutsideEvent.js
@@ -36,7 +36,7 @@ export default (ChildComponent) => { @@ -36,7 +36,7 @@ export default (ChildComponent) => {
36 const { otherCondition } = currentPane; 36 const { otherCondition } = currentPane;
37 if (formData.length > 0 && commonUtils.isEmptyObject(teamConfig) && commonUtils.isEmptyArr(searchSolution)) { 37 if (formData.length > 0 && commonUtils.isEmptyObject(teamConfig) && commonUtils.isEmptyArr(searchSolution)) {
38 isReceive = false; 38 isReceive = false;
39 - const sId = currentId !== undefined ? currentId : ''; 39 + const sId = currentId || nextProps.masterData?.sId || '';
40 const masterConfig = formData.filter(item => !item.bGrd && item.sTbName === 'eleteam')[0]; 40 const masterConfig = formData.filter(item => !item.bGrd && item.sTbName === 'eleteam')[0];
41 41
42 teamConfig = formData.filter(item => item.sTbName === 'Sp_Manufacture_ProductionPlanInfo_WorkCenter2')[0]; 42 teamConfig = formData.filter(item => item.sTbName === 'Sp_Manufacture_ProductionPlanInfo_WorkCenter2')[0];
src/components/Common/CommonProductionPlanTreeEvent.js
@@ -102,7 +102,7 @@ export default (ChildComponent) => { @@ -102,7 +102,7 @@ export default (ChildComponent) => {
102 const { otherCondition } = currentPane; 102 const { otherCondition } = currentPane;
103 if (formData.length > 0 && !treeLoaded && searchSolution !== undefined) { 103 if (formData.length > 0 && !treeLoaded && searchSolution !== undefined) {
104 isReceive = false; 104 isReceive = false;
105 - const sId = currentId !== undefined ? currentId : ''; 105 + const sId = currentId || nextProps.masterData?.sId || '';
106 const masterConfig = formData.filter(item => !item.bGrd && item.sTbName === 'eleteam')[0]; 106 const masterConfig = formData.filter(item => !item.bGrd && item.sTbName === 'eleteam')[0];
107 treeLoaded = true; 107 treeLoaded = true;
108 // teamConfig = formData.filter(item => item.sTbName === 'Sp_Manufacture_ProductionPlanInfo_WorkCenter')[0]; 108 // teamConfig = formData.filter(item => item.sTbName === 'Sp_Manufacture_ProductionPlanInfo_WorkCenter')[0];
src/components/Common/CommonSubBillEvent.js
@@ -51,7 +51,7 @@ export default (ChildComponent) => { @@ -51,7 +51,7 @@ export default (ChildComponent) => {
51 employeeConfig: employeeConfigOld, 51 employeeConfig: employeeConfigOld,
52 } = nextProps; 52 } = nextProps;
53 if (commonUtils.isEmptyObject(slaveConfigOld) && formData.length > 0 && (sModelsType !== 'cashier/financialTransfer' && sModelsType !== 'cashier/financialAdjustment' && sModelsType !== 'quality/accident' && sModelsType !== 'purchase/purchaseEnquiry' && sModelsType !== 'complaint/complaint' && sModelsType !== 'print/printLabel' && sModelsType !== 'commonBill/onlyMaster' && formRoute.indexOf('indexOee') === -1)) { 53 if (commonUtils.isEmptyObject(slaveConfigOld) && formData.length > 0 && (sModelsType !== 'cashier/financialTransfer' && sModelsType !== 'cashier/financialAdjustment' && sModelsType !== 'quality/accident' && sModelsType !== 'purchase/purchaseEnquiry' && sModelsType !== 'complaint/complaint' && sModelsType !== 'print/printLabel' && sModelsType !== 'commonBill/onlyMaster' && formRoute.indexOf('indexOee') === -1)) {
54 - const sId = currentId !== undefined ? currentId : ''; 54 + const sId = currentId || nextProps.masterData?.sId || '';
55 /* 数据Id */ 55 /* 数据Id */
56 const masterConfig = formData.filter(item => !item.bGrd)[0]; 56 const masterConfig = formData.filter(item => !item.bGrd)[0];
57 const BtnDesignFunctionConfig = commonUtils.isNotEmptyObject(masterConfig) ? masterConfig.gdsconfigformslave.filter(item => item.sControlName === 'BtnBsOperation.BtnDesignFunction') : {}; 57 const BtnDesignFunctionConfig = commonUtils.isNotEmptyObject(masterConfig) ? masterConfig.gdsconfigformslave.filter(item => item.sControlName === 'BtnBsOperation.BtnDesignFunction') : {};
@@ -506,7 +506,7 @@ export default (ChildComponent) => { @@ -506,7 +506,7 @@ export default (ChildComponent) => {
506 }); 506 });
507 } else if (commonUtils.isEmptyObject(masterConfigOld) && formData.length === 1 && (sModelsType === 'cashier/financialTransfer' || sModelsType === 'purchase/purchaseEnquiry' || sModelsType === 'cashier/financialAdjustment' || sModelsType === 'print/printLabel' || sModelsType === 'complaint/complaint' || sModelsType === 'commonBill/onlyMaster') && formRoute.indexOf('indexOee') === -1) { 507 } else if (commonUtils.isEmptyObject(masterConfigOld) && formData.length === 1 && (sModelsType === 'cashier/financialTransfer' || sModelsType === 'purchase/purchaseEnquiry' || sModelsType === 'cashier/financialAdjustment' || sModelsType === 'print/printLabel' || sModelsType === 'complaint/complaint' || sModelsType === 'commonBill/onlyMaster') && formRoute.indexOf('indexOee') === -1) {
508 const config = {}; 508 const config = {};
509 - const sId = currentId !== undefined ? currentId : ''; 509 + const sId = currentId || nextProps.masterData?.sId || '';
510 /* 数据Id */ 510 /* 数据Id */
511 const masterConfig = formData.filter(item => !item.bGrd)[0]; 511 const masterConfig = formData.filter(item => !item.bGrd)[0];
512 let addState = {}; 512 let addState = {};
@@ -528,7 +528,7 @@ export default (ChildComponent) => { @@ -528,7 +528,7 @@ export default (ChildComponent) => {
528 masterConfig, sId, pageLoading: false, ...addState, 528 masterConfig, sId, pageLoading: false, ...addState,
529 }); 529 });
530 } else if (commonUtils.isEmptyObject(slaveConfigOld) && commonUtils.isEmptyObject(masterConfigOld) && formData.length === 2 && (sModelsType === 'quality/accident') && formRoute.indexOf('indexOee') === -1) { 530 } else if (commonUtils.isEmptyObject(slaveConfigOld) && commonUtils.isEmptyObject(masterConfigOld) && formData.length === 2 && (sModelsType === 'quality/accident') && formRoute.indexOf('indexOee') === -1) {
531 - const sId = currentId !== undefined ? currentId : ''; 531 + const sId = currentId || nextProps.masterData?.sId || '';
532 /* 数据Id */ 532 /* 数据Id */
533 const masterConfig = formData.filter(item => !item.bGrd)[0]; 533 const masterConfig = formData.filter(item => !item.bGrd)[0];
534 const slaveConfig = formData.filter(item => item.bGrd && item.sTbName === 'mftqualityaccidentSlave')[0]; 534 const slaveConfig = formData.filter(item => item.bGrd && item.sTbName === 'mftqualityaccidentSlave')[0];
@@ -551,7 +551,7 @@ export default (ChildComponent) => { @@ -551,7 +551,7 @@ export default (ChildComponent) => {
551 }); 551 });
552 } else if (formRoute.indexOf('indexOee') > -1 && commonUtils.isEmptyObject(employeeConfigOld) && commonUtils.isEmptyObject(slaveConfigOld) && formData.length > 0) { 552 } else if (formRoute.indexOf('indexOee') > -1 && commonUtils.isEmptyObject(employeeConfigOld) && commonUtils.isEmptyObject(slaveConfigOld) && formData.length > 0) {
553 if (formRoute === '/indexOee/labelPrint' && commonUtils.isEmpty(slaveConfigOld)) { /* 入库标签打印 */ 553 if (formRoute === '/indexOee/labelPrint' && commonUtils.isEmpty(slaveConfigOld)) { /* 入库标签打印 */
554 - const sId = currentId !== undefined ? currentId : ''; 554 + const sId = currentId || nextProps.masterData?.sId || '';
555 /* 数据Id */ 555 /* 数据Id */
556 const masterConfig = formData[0]; 556 const masterConfig = formData[0];
557 const slaveConfig = formData[0]; 557 const slaveConfig = formData[0];
@@ -745,7 +745,7 @@ export default (ChildComponent) => { @@ -745,7 +745,7 @@ export default (ChildComponent) => {
745 /** 获取主表、从表、审核表数据 */ 745 /** 获取主表、从表、审核表数据 */
746 handleGetData = async (masterConfig, slaveConfig, checkConfig, bEditClick) => { 746 handleGetData = async (masterConfig, slaveConfig, checkConfig, bEditClick) => {
747 const { currentId, sModelsId } = this.props; /* 当前页签数据 */ 747 const { currentId, sModelsId } = this.props; /* 当前页签数据 */
748 - const sId = currentId !== undefined ? currentId : ''; 748 + const sId = currentId || this.props.masterData?.sId || '';
749 await this.props.handleGetDataOne({ 749 await this.props.handleGetDataOne({
750 name: 'master', configData: masterConfig, condition: { sId, pageSize: '', pageNum: '' }, bEditClick, 750 name: 'master', configData: masterConfig, condition: { sId, pageSize: '', pageNum: '' }, bEditClick,
751 }); 751 });
@@ -786,7 +786,7 @@ export default (ChildComponent) => { @@ -786,7 +786,7 @@ export default (ChildComponent) => {
786 /* 获取表数据 */ 786 /* 获取表数据 */
787 handleGetMemoData = async (controlConfig, materialsConfig, processConfig, colorConfig, packConfig) => { 787 handleGetMemoData = async (controlConfig, materialsConfig, processConfig, colorConfig, packConfig) => {
788 const { currentId, sModelsType } = this.props; /* 当前页签数据 */ 788 const { currentId, sModelsType } = this.props; /* 当前页签数据 */
789 - const sId = currentId !== undefined ? currentId : ''; /* 数据Id */ 789 + const sId = currentId || this.props.masterData?.sId || ''; /* 数据Id */
790 const addStateControl = await this.props.handleGetDataSet({ 790 const addStateControl = await this.props.handleGetDataSet({
791 name: 'control', configData: controlConfig, condition: { sSqlCondition: { sParentId: sId } }, isWait: true, 791 name: 'control', configData: controlConfig, condition: { sSqlCondition: { sParentId: sId } }, isWait: true,
792 }); 792 });
@@ -839,7 +839,7 @@ export default (ChildComponent) => { @@ -839,7 +839,7 @@ export default (ChildComponent) => {
839 /* 获取单张表数据 */ 839 /* 获取单张表数据 */
840 handleGetOneMemoData = (memoName, memoConfig) => { 840 handleGetOneMemoData = (memoName, memoConfig) => {
841 const { currentId } = this.props; /* 当前页签数据 */ 841 const { currentId } = this.props; /* 当前页签数据 */
842 - const sId = currentId !== undefined ? currentId : ''; /* 数据Id */ 842 + const sId = currentId || this.props.masterData?.sId || ''; /* 数据Id */
843 if (commonUtils.isNotEmptyObject(sId)) { /* 解决detail数据没有问题 */ 843 if (commonUtils.isNotEmptyObject(sId)) { /* 解决detail数据没有问题 */
844 this.props.handleGetDataSet({ 844 this.props.handleGetDataSet({
845 name: memoName, configData: memoConfig, condition: { sSqlCondition: { sParentId: sId } }, 845 name: memoName, configData: memoConfig, condition: { sSqlCondition: { sParentId: sId } },
@@ -849,7 +849,7 @@ export default (ChildComponent) => { @@ -849,7 +849,7 @@ export default (ChildComponent) => {
849 849
850 handleGetMemoData1 = async (memoDataList, isWait) => { 850 handleGetMemoData1 = async (memoDataList, isWait) => {
851 const { currentId, sModelsType, sModelsId } = this.props; /* 当前页签数据 */ 851 const { currentId, sModelsType, sModelsId } = this.props; /* 当前页签数据 */
852 - const sId = currentId !== undefined ? currentId : ''; /* 数据Id */ 852 + const sId = currentId || this.props.masterData?.sId || ''; /* 数据Id */
853 let addState = {}; 853 let addState = {};
854 // eslint-disable-next-line no-plusplus 854 // eslint-disable-next-line no-plusplus
855 for (let i = 0; i < memoDataList.length; i++) { 855 for (let i = 0; i < memoDataList.length; i++) {
src/components/Common/CommonSystemSettingEvent.js
@@ -23,7 +23,7 @@ export default (ChildComponent) =&gt; { @@ -23,7 +23,7 @@ export default (ChildComponent) =&gt; {
23 const { formData, currentId } = nextProps; 23 const { formData, currentId } = nextProps;
24 let { masterConfig } = nextProps; 24 let { masterConfig } = nextProps;
25 if (commonUtils.isEmptyArr(masterConfig) && formData.length > 0) { 25 if (commonUtils.isEmptyArr(masterConfig) && formData.length > 0) {
26 - const sId = currentId !== undefined ? currentId : ''; 26 + const sId = currentId || nextProps.masterData?.sId || '';
27 masterConfig = formData.filter(item => !item.bGrd)[0]; 27 masterConfig = formData.filter(item => !item.bGrd)[0];
28 const sysaccountperiodConfig = formData.filter(item => item.bGrd && item.sTbName === 'sysaccountperiod')[0]; 28 const sysaccountperiodConfig = formData.filter(item => item.bGrd && item.sTbName === 'sysaccountperiod')[0];
29 const sysaccountperiodColumn = commonFunc.getHeaderConfig(sysaccountperiodConfig); 29 const sysaccountperiodColumn = commonFunc.getHeaderConfig(sysaccountperiodConfig);
@@ -58,7 +58,7 @@ export default (ChildComponent) =&gt; { @@ -58,7 +58,7 @@ export default (ChildComponent) =&gt; {
58 } 58 }
59 handleGetData = (masterConfig, sysaccountperiodConfig, sysbillnosettingsConfig, syspushMsgConfig) => { 59 handleGetData = (masterConfig, sysaccountperiodConfig, sysbillnosettingsConfig, syspushMsgConfig) => {
60 const { currentId, year } = this.props; 60 const { currentId, year } = this.props;
61 - const sId = currentId !== undefined ? currentId : ''; 61 + const sId = currentId || this.props.masterData?.sId || '';
62 const condition = { 62 const condition = {
63 sSqlCondition: { 63 sSqlCondition: {
64 sParentId: masterConfig.sId, 64 sParentId: masterConfig.sId,
src/components/Manufacture/ProcessCard/ProcessCard.js
@@ -55,7 +55,7 @@ class ProcessCard extends Component { @@ -55,7 +55,7 @@ class ProcessCard extends Component {
55 } = nextProps; 55 } = nextProps;
56 const { formData, currentId } = nextProps; 56 const { formData, currentId } = nextProps;
57 if (commonUtils.isEmptyArr(controlColumn) && formData.length > 0) { 57 if (commonUtils.isEmptyArr(controlColumn) && formData.length > 0) {
58 - const sId = currentId !== undefined ? currentId : ''; 58 + const sId = currentId || nextProps.masterData?.sId || '';
59 /* 数据Id */ 59 /* 数据Id */
60 const masterConfig = formData.filter(item => !item.bGrd)[0]; 60 const masterConfig = formData.filter(item => !item.bGrd)[0];
61 /* bGrd代表是否是表格 */ 61 /* bGrd代表是否是表格 */
@@ -136,7 +136,7 @@ class ProcessCard extends Component { @@ -136,7 +136,7 @@ class ProcessCard extends Component {
136 } 136 }
137 137
138 // // 未清复制到时,产品ID需要再获取动态部件 138 // // 未清复制到时,产品ID需要再获取动态部件
139 - // const sId = currentId !== undefined ? currentId : ''; 139 + // const sId = currentId || nextProps.masterData?.sId || '';
140 // if (sId === '' && commonUtils.isNotEmptyObject(this.props.masterData) && !this.props.bGetPartsData) { 140 // if (sId === '' && commonUtils.isNotEmptyObject(this.props.masterData) && !this.props.bGetPartsData) {
141 // const { sAllPartsName } = this.props.masterData; 141 // const { sAllPartsName } = this.props.masterData;
142 // if (sAllPartsName !== undefined) { 142 // if (sAllPartsName !== undefined) {
@@ -164,7 +164,7 @@ class ProcessCard extends Component { @@ -164,7 +164,7 @@ class ProcessCard extends Component {
164 /* 获取表数据 */ 164 /* 获取表数据 */
165 handleGetData = async (controlConfig, materialsConfig, processConfig, colorConfig, dailyConfig, extraState = {}) => { 165 handleGetData = async (controlConfig, materialsConfig, processConfig, colorConfig, dailyConfig, extraState = {}) => {
166 const { currentId } = this.props; /* 当前页签数据 */ 166 const { currentId } = this.props; /* 当前页签数据 */
167 - const sId = currentId !== undefined ? currentId : ''; /* 数据Id */ 167 + const sId = currentId || this.props.masterData?.sId || ''; /* 数据Id */
168 const addStateControl = await this.props.handleGetDataSet({ 168 const addStateControl = await this.props.handleGetDataSet({
169 name: 'control', configData: controlConfig, condition: { sSqlCondition: { sParentId: sId } }, isWait: true, 169 name: 'control', configData: controlConfig, condition: { sSqlCondition: { sParentId: sId } }, isWait: true,
170 }); 170 });
src/components/Manufacture/ProcessCardPack/ProcessCardPack.js
@@ -80,7 +80,7 @@ class ProcessCardPack extends Component { @@ -80,7 +80,7 @@ class ProcessCardPack extends Component {
80 } = nextProps; 80 } = nextProps;
81 const { formData, currentId } = nextProps; 81 const { formData, currentId } = nextProps;
82 if (commonUtils.isEmptyArr(controlColumn) && formData.length > 0) { 82 if (commonUtils.isEmptyArr(controlColumn) && formData.length > 0) {
83 - const sId = currentId !== undefined ? currentId : ''; 83 + const sId = currentId || nextProps.masterData?.sId || '';
84 /* 数据Id */ 84 /* 数据Id */
85 const masterConfig = formData.filter(item => !item.bGrd)[0]; 85 const masterConfig = formData.filter(item => !item.bGrd)[0];
86 /* bGrd代表是否是表格 */ 86 /* bGrd代表是否是表格 */
@@ -210,7 +210,7 @@ class ProcessCardPack extends Component { @@ -210,7 +210,7 @@ class ProcessCardPack extends Component {
210 } 210 }
211 } 211 }
212 // // 未清复制到时,产品ID需要再获取动态部件; 212 // // 未清复制到时,产品ID需要再获取动态部件;
213 - // const sId = currentId !== undefined ? currentId : ''; 213 + // const sId = currentId || nextProps.masterData?.sId || '';
214 // if (sId === '' && commonUtils.isNotEmptyObject(this.props.masterData) && !this.props.bGetPartsData) { 214 // if (sId === '' && commonUtils.isNotEmptyObject(this.props.masterData) && !this.props.bGetPartsData) {
215 // const { sAllPartsName } = this.props.masterData; 215 // const { sAllPartsName } = this.props.masterData;
216 // if (sAllPartsName !== undefined) { 216 // if (sAllPartsName !== undefined) {
@@ -287,7 +287,7 @@ class ProcessCardPack extends Component { @@ -287,7 +287,7 @@ class ProcessCardPack extends Component {
287 /* 获取表数据 */ 287 /* 获取表数据 */
288 handleGetData = async (controlConfig, materialsConfig, processConfig, colorConfig, dailyConfig, packConfig, extraState = {}) => { 288 handleGetData = async (controlConfig, materialsConfig, processConfig, colorConfig, dailyConfig, packConfig, extraState = {}) => {
289 const { currentId, slaveData } = this.props; /* 当前页签数据 */ 289 const { currentId, slaveData } = this.props; /* 当前页签数据 */
290 - const sId = currentId !== undefined ? currentId : ''; /* 数据Id */ 290 + const sId = currentId || this.props.masterData?.sId || ''; /* 数据Id */
291 const addStateControl = await this.props.handleGetDataSet({ 291 const addStateControl = await this.props.handleGetDataSet({
292 name: 'control', configData: controlConfig, condition: { sSqlCondition: { sParentId: sId } }, isWait: true, 292 name: 'control', configData: controlConfig, condition: { sSqlCondition: { sParentId: sId } }, isWait: true,
293 }); 293 });
src/components/Manufacture/ProcessCardPack/ProcessCardPackTableTree.js
@@ -98,7 +98,7 @@ class ProcessCardPackTableTree extends Component { @@ -98,7 +98,7 @@ class ProcessCardPackTableTree extends Component {
98 } = nextProps; 98 } = nextProps;
99 const { formData, currentId } = nextProps; 99 const { formData, currentId } = nextProps;
100 if (commonUtils.isEmptyArr(controlColumn) && formData.length > 0) { 100 if (commonUtils.isEmptyArr(controlColumn) && formData.length > 0) {
101 - const sId = currentId !== undefined ? currentId : ''; 101 + const sId = currentId || nextProps.masterData?.sId || '';
102 /* 数据Id */ 102 /* 数据Id */
103 const masterConfig = formData.filter(item => !item.bGrd)[0]; 103 const masterConfig = formData.filter(item => !item.bGrd)[0];
104 if(masterConfig && masterConfig.gdsconfigformslave.filter(item => item.sControlName === 'bLayout')[0]) { 104 if(masterConfig && masterConfig.gdsconfigformslave.filter(item => item.sControlName === 'bLayout')[0]) {
@@ -273,7 +273,7 @@ class ProcessCardPackTableTree extends Component { @@ -273,7 +273,7 @@ class ProcessCardPackTableTree extends Component {
273 }); 273 });
274 } 274 }
275 // // 未清复制到时,产品ID需要再获取动态部件; 275 // // 未清复制到时,产品ID需要再获取动态部件;
276 - // const sId = currentId !== undefined ? currentId : ''; 276 + // const sId = currentId || nextProps.masterData?.sId || '';
277 // if (sId === '' && commonUtils.isNotEmptyObject(this.props.masterData) && !this.props.bGetPartsData) { 277 // if (sId === '' && commonUtils.isNotEmptyObject(this.props.masterData) && !this.props.bGetPartsData) {
278 // const { sAllPartsName } = this.props.masterData; 278 // const { sAllPartsName } = this.props.masterData;
279 // if (sAllPartsName !== undefined) { 279 // if (sAllPartsName !== undefined) {
@@ -426,7 +426,7 @@ class ProcessCardPackTableTree extends Component { @@ -426,7 +426,7 @@ class ProcessCardPackTableTree extends Component {
426 /* 获取表数据 */ 426 /* 获取表数据 */
427 handleGetData1 = async (controlConfig, materialsConfig, processConfig, colorConfig, dailyConfig, packConfig, extraState = {}, configMap) => { 427 handleGetData1 = async (controlConfig, materialsConfig, processConfig, colorConfig, dailyConfig, packConfig, extraState = {}, configMap) => {
428 const { currentId, slaveData, masterData } = this.props; /* 当前页签数据 */ 428 const { currentId, slaveData, masterData } = this.props; /* 当前页签数据 */
429 - const sId = currentId !== undefined ? currentId : ''; /* 数据Id */ 429 + const sId = currentId || this.props.masterData?.sId || ''; /* 数据Id */
430 const addStateControl = await this.props.handleGetDataSet({ 430 const addStateControl = await this.props.handleGetDataSet({
431 name: 'control', configData: controlConfig, condition: { sSqlCondition: { sParentId: sId } }, isWait: true, 431 name: 'control', configData: controlConfig, condition: { sSqlCondition: { sParentId: sId } }, isWait: true,
432 }); 432 });
@@ -703,7 +703,7 @@ class ProcessCardPackTableTree extends Component { @@ -703,7 +703,7 @@ class ProcessCardPackTableTree extends Component {
703 /* 获取表数据 */ 703 /* 获取表数据 */
704 handleGetData = async (controlConfig, materialsConfig, processConfig, colorConfig, dailyConfig, packConfig, extraState = {}, configMap) => { 704 handleGetData = async (controlConfig, materialsConfig, processConfig, colorConfig, dailyConfig, packConfig, extraState = {}, configMap) => {
705 const { currentId, slaveData } = this.props; /* 当前页签数据 */ 705 const { currentId, slaveData } = this.props; /* 当前页签数据 */
706 - const sId = currentId !== undefined ? currentId : ''; /* 数据Id */ 706 + const sId = currentId || this.props.masterData?.sId || ''; /* 数据Id */
707 707
708 this.handleGetAllData(controlConfig, processConfig, sId, materialsConfig, colorConfig, dailyConfig, packConfig, extraState, configMap); 708 this.handleGetAllData(controlConfig, processConfig, sId, materialsConfig, colorConfig, dailyConfig, packConfig, extraState, configMap);
709 }; 709 };
@@ -711,7 +711,7 @@ class ProcessCardPackTableTree extends Component { @@ -711,7 +711,7 @@ class ProcessCardPackTableTree extends Component {
711 711
712 handleGetOtherData = async (tableList, childTableList, configMap) => { 712 handleGetOtherData = async (tableList, childTableList, configMap) => {
713 const { currentId, slaveData, sModelsType, masterData } = this.props; /* 当前页签数据 */ 713 const { currentId, slaveData, sModelsType, masterData } = this.props; /* 当前页签数据 */
714 - const sId = currentId !== undefined ? currentId : ''; /* 数据Id */ 714 + const sId = currentId || this.props.masterData?.sId || ''; /* 数据Id */
715 if(commonUtils.isNotEmptyObject(configMap)){ 715 if(commonUtils.isNotEmptyObject(configMap)){
716 for (const configName of Object.keys(configMap)) { 716 for (const configName of Object.keys(configMap)) {
717 const tableName = configName.replace('Config', '').trim(); 717 const tableName = configName.replace('Config', '').trim();
src/components/Manufacture/WorkOrder/WorkOrder.js
@@ -100,7 +100,7 @@ class WorkOrder extends Component { @@ -100,7 +100,7 @@ class WorkOrder extends Component {
100 } = nextProps; 100 } = nextProps;
101 const { formData, currentId } = nextProps; 101 const { formData, currentId } = nextProps;
102 if (commonUtils.isEmptyArr(controlColumn) && formData.length > 0) { 102 if (commonUtils.isEmptyArr(controlColumn) && formData.length > 0) {
103 - const sId = currentId !== undefined ? currentId : ''; 103 + const sId = currentId || nextProps.masterData?.sId || '';
104 /* 数据Id */ 104 /* 数据Id */
105 const masterConfig = formData.filter(item => !item.bGrd)[0]; 105 const masterConfig = formData.filter(item => !item.bGrd)[0];
106 /* bGrd代表是否是表格 */ 106 /* bGrd代表是否是表格 */
@@ -167,7 +167,7 @@ class WorkOrder extends Component { @@ -167,7 +167,7 @@ class WorkOrder extends Component {
167 } 167 }
168 168
169 // // 未清复制到时,产品ID需要再获取动态部件 169 // // 未清复制到时,产品ID需要再获取动态部件
170 - // const sId = currentId !== undefined ? currentId : ''; 170 + // const sId = currentId || nextProps.masterData?.sId || '';
171 // if (sId === '' && commonUtils.isNotEmptyObject(this.props.masterData) && !this.props.bGetPartsData) { 171 // if (sId === '' && commonUtils.isNotEmptyObject(this.props.masterData) && !this.props.bGetPartsData) {
172 // const { sAllPartsName } = this.props.masterData; 172 // const { sAllPartsName } = this.props.masterData;
173 // if (sAllPartsName !== undefined) { 173 // if (sAllPartsName !== undefined) {
@@ -220,7 +220,7 @@ class WorkOrder extends Component { @@ -220,7 +220,7 @@ class WorkOrder extends Component {
220 /* 获取表数据 */ 220 /* 获取表数据 */
221 handleGetData = async (controlConfig, materialsConfig, processConfig, colorConfig, extraState = {}) => { 221 handleGetData = async (controlConfig, materialsConfig, processConfig, colorConfig, extraState = {}) => {
222 const { currentId } = this.props; /* 当前页签数据 */ 222 const { currentId } = this.props; /* 当前页签数据 */
223 - const sId = currentId !== undefined ? currentId : ''; /* 数据Id */ 223 + const sId = currentId || this.props.masterData?.sId || ''; /* 数据Id */
224 const addStateControl = await this.props.handleGetDataSet({ 224 const addStateControl = await this.props.handleGetDataSet({
225 name: 'control', configData: controlConfig, condition: { sSqlCondition: { sParentId: sId } }, isWait: true, 225 name: 'control', configData: controlConfig, condition: { sSqlCondition: { sParentId: sId } }, isWait: true,
226 }); 226 });
src/components/Manufacture/WorkOrderPack/WorkOrderPack.js
@@ -95,7 +95,7 @@ class WorkOrderPack extends Component { @@ -95,7 +95,7 @@ class WorkOrderPack extends Component {
95 } = nextProps; 95 } = nextProps;
96 const { formData, currentId } = nextProps; 96 const { formData, currentId } = nextProps;
97 if (commonUtils.isEmptyArr(controlColumn) && formData.length > 0) { 97 if (commonUtils.isEmptyArr(controlColumn) && formData.length > 0) {
98 - const sId = currentId !== undefined ? currentId : ''; 98 + const sId = currentId || nextProps.masterData?.sId || '';
99 /* 数据Id */ 99 /* 数据Id */
100 const masterConfig = formData.filter(item => !item.bGrd)[0]; 100 const masterConfig = formData.filter(item => !item.bGrd)[0];
101 /* bGrd代表是否是表格 */ 101 /* bGrd代表是否是表格 */
@@ -300,7 +300,7 @@ class WorkOrderPack extends Component { @@ -300,7 +300,7 @@ class WorkOrderPack extends Component {
300 /* 获取表数据 */ 300 /* 获取表数据 */
301 handleGetData = async (controlConfig, materialsConfig, processConfig, colorConfig, packConfig, extraState = {}) => { 301 handleGetData = async (controlConfig, materialsConfig, processConfig, colorConfig, packConfig, extraState = {}) => {
302 const { currentId, slaveData, sModelsType } = this.props; /* 当前页签数据 */ 302 const { currentId, slaveData, sModelsType } = this.props; /* 当前页签数据 */
303 - const sId = currentId !== undefined ? currentId : ''; /* 数据Id */ 303 + const sId = currentId || this.props.masterData?.sId || ''; /* 数据Id */
304 const addStateControl = await this.props.handleGetDataSet({ 304 const addStateControl = await this.props.handleGetDataSet({
305 name: 'control', configData: controlConfig, condition: { sSqlCondition: { sParentId: sId } }, isWait: true, 305 name: 'control', configData: controlConfig, condition: { sSqlCondition: { sParentId: sId } }, isWait: true,
306 }); 306 });
src/components/Manufacture/WorkOrderPack/WorkOrderPackTableTree.js
@@ -140,7 +140,7 @@ class WorkOrderPack extends Component { @@ -140,7 +140,7 @@ class WorkOrderPack extends Component {
140 } = nextProps; 140 } = nextProps;
141 const { formData, currentId, sModelsId } = nextProps; 141 const { formData, currentId, sModelsId } = nextProps;
142 if (commonUtils.isEmptyArr(controlColumn) && formData.length > 0) { 142 if (commonUtils.isEmptyArr(controlColumn) && formData.length > 0) {
143 - const sId = currentId !== undefined ? currentId : ''; 143 + const sId = currentId || nextProps.masterData?.sId || '';
144 /* 数据Id */ 144 /* 数据Id */
145 const masterConfig = formData.filter(item => !item.bGrd)[0]; 145 const masterConfig = formData.filter(item => !item.bGrd)[0];
146 if(masterConfig && masterConfig.gdsconfigformslave.filter(item => item.sControlName === 'bLayout')[0]) { 146 if(masterConfig && masterConfig.gdsconfigformslave.filter(item => item.sControlName === 'bLayout')[0]) {
@@ -613,7 +613,7 @@ class WorkOrderPack extends Component { @@ -613,7 +613,7 @@ class WorkOrderPack extends Component {
613 /* 获取表数据 */ 613 /* 获取表数据 */
614 handleGetData = async (controlConfig, materialsConfig, processConfig, colorConfig, packConfig, extraState = {}) => { 614 handleGetData = async (controlConfig, materialsConfig, processConfig, colorConfig, packConfig, extraState = {}) => {
615 const { currentId, slaveData } = this.props; /* 当前页签数据 */ 615 const { currentId, slaveData } = this.props; /* 当前页签数据 */
616 - const sId = currentId !== undefined ? currentId : ''; /* 数据Id */ 616 + const sId = currentId || this.props.masterData?.sId || ''; /* 数据Id */
617 617
618 this.handleGetAllData(controlConfig, processConfig, sId, materialsConfig, colorConfig, packConfig, extraState); 618 this.handleGetAllData(controlConfig, processConfig, sId, materialsConfig, colorConfig, packConfig, extraState);
619 }; 619 };
@@ -621,7 +621,7 @@ class WorkOrderPack extends Component { @@ -621,7 +621,7 @@ class WorkOrderPack extends Component {
621 621
622 handleGetOtherData = async (tableList, childTableList, configMap) => { 622 handleGetOtherData = async (tableList, childTableList, configMap) => {
623 const { currentId, slaveData, sModelsType, masterData } = this.props; /* 当前页签数据 */ 623 const { currentId, slaveData, sModelsType, masterData } = this.props; /* 当前页签数据 */
624 - const sId = currentId !== undefined ? currentId : ''; /* 数据Id */ 624 + const sId = currentId || this.props.masterData?.sId || ''; /* 数据Id */
625 if(commonUtils.isNotEmptyObject(configMap)){ 625 if(commonUtils.isNotEmptyObject(configMap)){
626 for (const configName of Object.keys(configMap)) { 626 for (const configName of Object.keys(configMap)) {
627 const tableName = configName.replace('Config', '').trim(); 627 const tableName = configName.replace('Config', '').trim();
src/components/Manufacture/WorkOrderPack/WorkOrderResearchTableTree.js
@@ -117,7 +117,7 @@ class WorkOrderPack extends Component { @@ -117,7 +117,7 @@ class WorkOrderPack extends Component {
117 } = nextProps; 117 } = nextProps;
118 const { formData, currentId, sModelsId } = nextProps; 118 const { formData, currentId, sModelsId } = nextProps;
119 if (commonUtils.isEmptyArr(controlColumn) && formData.length > 0) { 119 if (commonUtils.isEmptyArr(controlColumn) && formData.length > 0) {
120 - const sId = currentId !== undefined ? currentId : ''; 120 + const sId = currentId || nextProps.masterData?.sId || '';
121 /* 数据Id */ 121 /* 数据Id */
122 const masterConfig = formData.filter(item => !item.bGrd)[0]; 122 const masterConfig = formData.filter(item => !item.bGrd)[0];
123 if(masterConfig && masterConfig.gdsconfigformslave.filter(item => item.sControlName === 'bLayout')[0]) { 123 if(masterConfig && masterConfig.gdsconfigformslave.filter(item => item.sControlName === 'bLayout')[0]) {
@@ -428,7 +428,7 @@ class WorkOrderPack extends Component { @@ -428,7 +428,7 @@ class WorkOrderPack extends Component {
428 /* 获取表数据 */ 428 /* 获取表数据 */
429 handleGetData = async (controlConfig, materialsConfig, processConfig, colorConfig, packConfig, extraState = {}) => { 429 handleGetData = async (controlConfig, materialsConfig, processConfig, colorConfig, packConfig, extraState = {}) => {
430 const { currentId, slaveData, sModelsType, masterData } = this.props; /* 当前页签数据 */ 430 const { currentId, slaveData, sModelsType, masterData } = this.props; /* 当前页签数据 */
431 - const sId = currentId !== undefined ? currentId : ''; /* 数据Id */ 431 + const sId = currentId || this.props.masterData?.sId || ''; /* 数据Id */
432 const addStateControl = await this.props.handleGetDataSet({ 432 const addStateControl = await this.props.handleGetDataSet({
433 name: 'control', configData: controlConfig, condition: { sSqlCondition: { sParentId: sId } }, isWait: true, 433 name: 'control', configData: controlConfig, condition: { sSqlCondition: { sParentId: sId } }, isWait: true,
434 }); 434 });
@@ -540,7 +540,7 @@ class WorkOrderPack extends Component { @@ -540,7 +540,7 @@ class WorkOrderPack extends Component {
540 540
541 handleGetOtherData = async (tableList, childTableList, configMap) => { 541 handleGetOtherData = async (tableList, childTableList, configMap) => {
542 const { currentId, slaveData, sModelsType, masterData } = this.props; /* 当前页签数据 */ 542 const { currentId, slaveData, sModelsType, masterData } = this.props; /* 当前页签数据 */
543 - const sId = currentId !== undefined ? currentId : ''; /* 数据Id */ 543 + const sId = currentId || this.props.masterData?.sId || ''; /* 数据Id */
544 if(commonUtils.isNotEmptyObject(configMap)){ 544 if(commonUtils.isNotEmptyObject(configMap)){
545 for (const configName of Object.keys(configMap)) { 545 for (const configName of Object.keys(configMap)) {
546 const tableName = configName.replace('Config', '').trim(); 546 const tableName = configName.replace('Config', '').trim();
src/components/ProductionReport/ProductionReport.js
@@ -50,7 +50,7 @@ class ProductionReport extends Component { @@ -50,7 +50,7 @@ class ProductionReport extends Component {
50 } = nextProps; 50 } = nextProps;
51 const { formData, currentId } = nextProps; 51 const { formData, currentId } = nextProps;
52 if (commonUtils.isEmptyArr(employeeColumn) && formData.length > 0) { 52 if (commonUtils.isEmptyArr(employeeColumn) && formData.length > 0) {
53 - const sId = currentId !== undefined ? currentId : ''; 53 + const sId = currentId || nextProps.masterData?.sId || '';
54 /* 数据Id */ 54 /* 数据Id */
55 const masterConfig = formData.filter(item => !item.bGrd)[0]; 55 const masterConfig = formData.filter(item => !item.bGrd)[0];
56 /* bGrd代表是否是表格 */ 56 /* bGrd代表是否是表格 */
@@ -115,7 +115,7 @@ class ProductionReport extends Component { @@ -115,7 +115,7 @@ class ProductionReport extends Component {
115 /* 获取表数据 */ 115 /* 获取表数据 */
116 handleGetData = (employeeConfig, extraState = {}) => { 116 handleGetData = (employeeConfig, extraState = {}) => {
117 const { currentId } = this.props; /* 当前页签数据 */ 117 const { currentId } = this.props; /* 当前页签数据 */
118 - const sId = currentId !== undefined ? currentId : ''; /* 数据Id */ 118 + const sId = currentId || this.props.masterData?.sId || ''; /* 数据Id */
119 this.props.handleGetDataSet({ 119 this.props.handleGetDataSet({
120 name: 'employee', configData: employeeConfig, condition: { sSqlCondition: { sParentId: sId } }, 120 name: 'employee', configData: employeeConfig, condition: { sSqlCondition: { sParentId: sId } },
121 }); 121 });
@@ -364,7 +364,7 @@ class ProductionReport extends Component { @@ -364,7 +364,7 @@ class ProductionReport extends Component {
364 /** 获取主表、从表、审核表、员工表数据 */ 364 /** 获取主表、从表、审核表、员工表数据 */
365 handleGetTableData = (masterConfig, slaveConfig, checkConfig, employeeConfig) => { 365 handleGetTableData = (masterConfig, slaveConfig, checkConfig, employeeConfig) => {
366 const { currentId } = this.props; /* 当前页签数据 */ 366 const { currentId } = this.props; /* 当前页签数据 */
367 - const sId = currentId !== undefined ? currentId : ''; 367 + const sId = currentId || this.props.masterData?.sId || '';
368 this.props.handleGetDataOne({ 368 this.props.handleGetDataOne({
369 name: 'master', configData: masterConfig, condition: { sId, pageSize: '', pageNum: '' }, 369 name: 'master', configData: masterConfig, condition: { sId, pageSize: '', pageNum: '' },
370 }); 370 });
src/components/QuoQuotation/Quotation/Quotation.js
@@ -63,7 +63,7 @@ class Quotation extends Component { @@ -63,7 +63,7 @@ class Quotation extends Component {
63 } = nextProps; 63 } = nextProps;
64 const { formData, currentId } = nextProps; 64 const { formData, currentId } = nextProps;
65 if (commonUtils.isEmptyArr(controlColumn) && formData.length > 0) { 65 if (commonUtils.isEmptyArr(controlColumn) && formData.length > 0) {
66 - const sId = currentId !== undefined ? currentId : ''; 66 + const sId = currentId || nextProps.masterData?.sId || '';
67 /* 数据Id */ 67 /* 数据Id */
68 const masterConfig = formData.filter(item => !item.bGrd)[0]; 68 const masterConfig = formData.filter(item => !item.bGrd)[0];
69 /* bGrd代表是否是表格 */ 69 /* bGrd代表是否是表格 */
@@ -177,7 +177,7 @@ class Quotation extends Component { @@ -177,7 +177,7 @@ class Quotation extends Component {
177 /* 获取表数据 */ 177 /* 获取表数据 */
178 handleGetData = async (controlConfig, materialsConfig, processConfig, manyqtysConfig, colorConfig, extraState = {}) => { 178 handleGetData = async (controlConfig, materialsConfig, processConfig, manyqtysConfig, colorConfig, extraState = {}) => {
179 const { currentId } = this.props; /* 当前页签数据 */ 179 const { currentId } = this.props; /* 当前页签数据 */
180 - const sId = currentId !== undefined ? currentId : ''; /* 数据Id */ 180 + const sId = currentId || this.props.masterData?.sId || ''; /* 数据Id */
181 const addStateControl = await this.props.handleGetDataSet({ 181 const addStateControl = await this.props.handleGetDataSet({
182 name: 'control', configData: controlConfig, condition: { sSqlCondition: { sParentId: sId } }, isWait: true, 182 name: 'control', configData: controlConfig, condition: { sSqlCondition: { sParentId: sId } }, isWait: true,
183 }); 183 });
src/components/QuoQuotation/QuotationPack/QuotationPack.js
@@ -80,7 +80,7 @@ class QuotationPack extends Component { @@ -80,7 +80,7 @@ class QuotationPack extends Component {
80 } = nextProps; 80 } = nextProps;
81 const { formData, currentId } = nextProps; 81 const { formData, currentId } = nextProps;
82 if (commonUtils.isEmptyArr(controlColumn) && formData.length > 0) { 82 if (commonUtils.isEmptyArr(controlColumn) && formData.length > 0) {
83 - const sId = currentId !== undefined ? currentId : ''; 83 + const sId = currentId || nextProps.masterData?.sId || '';
84 /* 数据Id */ 84 /* 数据Id */
85 const masterConfig = formData.filter(item => !item.bGrd)[0]; 85 const masterConfig = formData.filter(item => !item.bGrd)[0];
86 /* bGrd代表是否是表格 */ 86 /* bGrd代表是否是表格 */
@@ -291,7 +291,7 @@ class QuotationPack extends Component { @@ -291,7 +291,7 @@ class QuotationPack extends Component {
291 /* 获取表数据 */ 291 /* 获取表数据 */
292 handleGetData = async (controlConfig, materialsConfig, processConfig, manyqtysConfig, colorConfig, packConfig, extraState = {}) => { 292 handleGetData = async (controlConfig, materialsConfig, processConfig, manyqtysConfig, colorConfig, packConfig, extraState = {}) => {
293 const { currentId, slaveData } = this.props; /* 当前页签数据 */ 293 const { currentId, slaveData } = this.props; /* 当前页签数据 */
294 - const sId = currentId !== undefined ? currentId : ''; /* 数据Id */ 294 + const sId = currentId || this.props.masterData?.sId || ''; /* 数据Id */
295 const addStateControl = await this.props.handleGetDataSet({ 295 const addStateControl = await this.props.handleGetDataSet({
296 name: 'control', configData: controlConfig, condition: { sSqlCondition: { sParentId: sId } }, isWait: true, 296 name: 'control', configData: controlConfig, condition: { sSqlCondition: { sParentId: sId } }, isWait: true,
297 }); 297 });
src/components/QuoQuotation/QuotationPackTableTree/QuotationPackTableTree.js
@@ -101,7 +101,7 @@ class QuotationPackTableTree extends Component { @@ -101,7 +101,7 @@ class QuotationPackTableTree extends Component {
101 } = nextProps; 101 } = nextProps;
102 const { formData, currentId } = nextProps; 102 const { formData, currentId } = nextProps;
103 if (commonUtils.isEmptyArr(controlColumn) && formData.length > 0) { 103 if (commonUtils.isEmptyArr(controlColumn) && formData.length > 0) {
104 - const sId = currentId !== undefined ? currentId : ''; 104 + const sId = currentId || nextProps.masterData?.sId || '';
105 /* 数据Id */ 105 /* 数据Id */
106 const masterConfig = formData.filter(item => !item.bGrd)[0]; 106 const masterConfig = formData.filter(item => !item.bGrd)[0];
107 if(masterConfig && masterConfig.gdsconfigformslave.filter(item => item.sControlName === 'bLayout')[0]) { 107 if(masterConfig && masterConfig.gdsconfigformslave.filter(item => item.sControlName === 'bLayout')[0]) {
@@ -382,7 +382,7 @@ class QuotationPackTableTree extends Component { @@ -382,7 +382,7 @@ class QuotationPackTableTree extends Component {
382 /* 获取表数据 */ 382 /* 获取表数据 */
383 handleGetData = async (controlConfig, materialsConfig, processConfig, manyqtysConfig, colorConfig, packConfig, extraState = {}) => { 383 handleGetData = async (controlConfig, materialsConfig, processConfig, manyqtysConfig, colorConfig, packConfig, extraState = {}) => {
384 const { currentId, masterData, slaveData } = this.props; /* 当前页签数据 */ 384 const { currentId, masterData, slaveData } = this.props; /* 当前页签数据 */
385 - const sId = currentId !== undefined ? currentId : ''; /* 数据Id */ 385 + const sId = currentId || this.props.masterData?.sId || ''; /* 数据Id */
386 const addStateControl = await this.props.handleGetDataSet({ 386 const addStateControl = await this.props.handleGetDataSet({
387 name: 'control', configData: controlConfig, condition: { sSqlCondition: { sParentId: sId } }, isWait: true, 387 name: 'control', configData: controlConfig, condition: { sSqlCondition: { sParentId: sId } }, isWait: true,
388 }); 388 });
@@ -654,7 +654,7 @@ class QuotationPackTableTree extends Component { @@ -654,7 +654,7 @@ class QuotationPackTableTree extends Component {
654 654
655 handleGetOtherData = async (tableList, childTableList, configMap) => { 655 handleGetOtherData = async (tableList, childTableList, configMap) => {
656 const { currentId, slaveData, sModelsType, masterData } = this.props; /* 当前页签数据 */ 656 const { currentId, slaveData, sModelsType, masterData } = this.props; /* 当前页签数据 */
657 - const sId = currentId !== undefined ? currentId : ''; /* 数据Id */ 657 + const sId = currentId || this.props.masterData?.sId || ''; /* 数据Id */
658 if(commonUtils.isNotEmptyObject(configMap)){ 658 if(commonUtils.isNotEmptyObject(configMap)){
659 for (const configName of Object.keys(configMap)) { 659 for (const configName of Object.keys(configMap)) {
660 const tableName = configName.replace('Config', '').trim(); 660 const tableName = configName.replace('Config', '').trim();
src/mobile/common/CommobileBillEvent.js
@@ -25,7 +25,7 @@ export default (ChildComponent) =&gt; { @@ -25,7 +25,7 @@ export default (ChildComponent) =&gt; {
25 formData, currentId, masterConfig: masterConfigOld, sModelsId, 25 formData, currentId, masterConfig: masterConfigOld, sModelsId,
26 } = nextProps; 26 } = nextProps;
27 if (commonUtils.isEmptyObject(masterConfigOld) && formData.length > 0) { 27 if (commonUtils.isEmptyObject(masterConfigOld) && formData.length > 0) {
28 - const sId = currentId !== undefined ? currentId : ''; 28 + const sId = currentId || nextProps.masterData?.sId || '';
29 /* 数据Id */ 29 /* 数据Id */
30 const masterConfig = formData.filter(item => !item.bGrd)[0]; 30 const masterConfig = formData.filter(item => !item.bGrd)[0];
31 const slaveConfig = formData.filter(item => item.bGrd)[0]; 31 const slaveConfig = formData.filter(item => item.bGrd)[0];
@@ -777,7 +777,7 @@ export default (ChildComponent) =&gt; { @@ -777,7 +777,7 @@ export default (ChildComponent) =&gt; {
777 /** 获取主表、从表、审核表数据 */ 777 /** 获取主表、从表、审核表数据 */
778 handleGetData = async (masterConfig, slaveConfig) => { 778 handleGetData = async (masterConfig, slaveConfig) => {
779 const { currentId } = this.props; /* 当前页签数据 */ 779 const { currentId } = this.props; /* 当前页签数据 */
780 - const sId = currentId !== undefined ? currentId : ''; 780 + const sId = currentId || this.props.masterData?.sId || '';
781 await this.props.handleGetDataOne({ name: 'master', configData: masterConfig, condition: { sId, pageSize: '', pageNum: '' } }); 781 await this.props.handleGetDataOne({ name: 'master', configData: masterConfig, condition: { sId, pageSize: '', pageNum: '' } });
782 if (!commonUtils.isEmptyObject(slaveConfig)) { 782 if (!commonUtils.isEmptyObject(slaveConfig)) {
783 this.props.handleGetDataSet({ 783 this.props.handleGetDataSet({
@@ -788,7 +788,7 @@ export default (ChildComponent) =&gt; { @@ -788,7 +788,7 @@ export default (ChildComponent) =&gt; {
788 788
789 handleGetMemoData = async (employeeConfig) => { 789 handleGetMemoData = async (employeeConfig) => {
790 const { currentId } = this.props; /* 当前页签数据 */ 790 const { currentId } = this.props; /* 当前页签数据 */
791 - const sId = currentId !== undefined ? currentId : ''; /* 数据Id */ 791 + const sId = currentId || this.props.masterData?.sId || ''; /* 数据Id */
792 this.props.handleGetDataSet({ 792 this.props.handleGetDataSet({
793 name: 'employee', configData: employeeConfig, condition: { sSqlCondition: { sParentId: sId } }, 793 name: 'employee', configData: employeeConfig, condition: { sSqlCondition: { sParentId: sId } },
794 }); 794 });
src/mobile/common/CommobileSubBillEvent.js
@@ -25,7 +25,7 @@ export default (ChildComponent) =&gt; { @@ -25,7 +25,7 @@ export default (ChildComponent) =&gt; {
25 formData, currentId, masterConfig: masterConfigOld, sModelsId, 25 formData, currentId, masterConfig: masterConfigOld, sModelsId,
26 } = nextProps; 26 } = nextProps;
27 if (commonUtils.isEmptyObject(masterConfigOld) && formData.length > 0) { 27 if (commonUtils.isEmptyObject(masterConfigOld) && formData.length > 0) {
28 - const sId = currentId !== undefined ? currentId : ''; 28 + const sId = currentId || nextProps.masterData?.sId || '';
29 /* 数据Id */ 29 /* 数据Id */
30 const masterConfig = formData.filter(item => !item.bGrd)[0]; 30 const masterConfig = formData.filter(item => !item.bGrd)[0];
31 const slaveConfig = formData.filter(item => item.bGrd)[0]; 31 const slaveConfig = formData.filter(item => item.bGrd)[0];
src/mobile/common/ProcessReportMobile.js
@@ -59,7 +59,7 @@ class ProcessReportMobileComponent extends React.Component { @@ -59,7 +59,7 @@ class ProcessReportMobileComponent extends React.Component {
59 componentWillReceiveProps(nextProps) { 59 componentWillReceiveProps(nextProps) {
60 const { formData, employeeConfig, currentId } = nextProps; 60 const { formData, employeeConfig, currentId } = nextProps;
61 if (commonUtils.isEmptyObject(employeeConfig) && formData.length > 0) { 61 if (commonUtils.isEmptyObject(employeeConfig) && formData.length > 0) {
62 - const sId = currentId !== undefined ? currentId : ''; 62 + const sId = currentId || nextProps.masterData?.sId || '';
63 const employeeConfig = formData.filter(item => item.sTbName.toUpperCase() === 'mftproductionreportemployee'.toUpperCase())[0]; 63 const employeeConfig = formData.filter(item => item.sTbName.toUpperCase() === 'mftproductionreportemployee'.toUpperCase())[0];
64 const addState = {}; 64 const addState = {};
65 if (sId === '') { 65 if (sId === '') {