Commit df8603985cfb4eeb3bf96de6be2dfdf49130fe0e

Authored by zhangz
1 parent d54895c8

修改保存后查询;

src/mes/common/commonModelComponent/index.js
@@ -575,12 +575,12 @@ const useCommonModelEvent = props => { @@ -575,12 +575,12 @@ const useCommonModelEvent = props => {
575 conditonValues.sSReserve1 = props.sSReserve1; 575 conditonValues.sSReserve1 = props.sSReserve1;
576 } 576 }
577 577
578 - if (currentId) {  
579 - if (tableName === 'master') {  
580 - conditonValues.sId = currentId;  
581 - } else {  
582 - conditonValues.sParentId = currentId;  
583 - } 578 + const masterState = {};
  579 + if (currentId && tableName === 'master') {
  580 + masterState.sId = currentId;
  581 + }
  582 + if (currentId && tableName !== 'master') {
  583 + conditonValues.sParentId = currentId;
584 } 584 }
585 585
586 const result = 586 const result =
@@ -588,6 +588,7 @@ const useCommonModelEvent = props => { @@ -588,6 +588,7 @@ const useCommonModelEvent = props => {
588 name: tableName, 588 name: tableName,
589 configData: config, 589 configData: config,
590 condition: { 590 condition: {
  591 + ...masterState,
591 sSqlCondition: { ...conditonValues, ...sFilterConditions }, 592 sSqlCondition: { ...conditonValues, ...sFilterConditions },
592 bFilter 593 bFilter
593 }, 594 },