Commit c5fa7bbb128bc3bfa6cf910ce7049e5fd1effff8

Authored by Min
1 parent 6b68e3b5

1.去掉updateFlushmes调用

src/mes/productionExec/productionExecMain/index.js
@@ -395,36 +395,36 @@ const ProductionExecMain = baseProps => { @@ -395,36 +395,36 @@ const ProductionExecMain = baseProps => {
395 395
396 const [refreshCount, setRefreshCount] = useState(0); 396 const [refreshCount, setRefreshCount] = useState(0);
397 397
398 - useEffect(() => {  
399 - const getValue = () => {  
400 - const changeExecInfo = commonUtils.getAppData("changeExecInfo");  
401 - if (changeExecInfo.dReplyPalletERp === 1) {  
402 - try {  
403 - const { sId } = changeExecInfo;  
404 - const url = `${commonConfig.server_host}mqtt/updateFlushmes/${sId}`;  
405 - commonServices.postValueService(null, {}, url).then(() => {  
406 - props.onRefresh();  
407 - setRefreshCount(pre => pre + 1);  
408 - })  
409 - } catch (error) {  
410 - console.log("=====updateFlushmes报错", {  
411 - error, changeExecInfo,  
412 - });  
413 - props.onRefresh();  
414 - setRefreshCount(pre => pre + 1);  
415 - }  
416 - }  
417 - };  
418 -  
419 - getValue();  
420 - const timer = setInterval(() => {  
421 - getValue();  
422 - }, 1000);  
423 -  
424 - return () => {  
425 - clearInterval(timer);  
426 - };  
427 - }, []); 398 + // useEffect(() => {
  399 + // const getValue = () => {
  400 + // const changeExecInfo = commonUtils.getAppData("changeExecInfo");
  401 + // if (changeExecInfo.dReplyPalletERp === 1) {
  402 + // try {
  403 + // const { sId } = changeExecInfo;
  404 + // const url = `${commonConfig.server_host}mqtt/updateFlushmes/${sId}`;
  405 + // commonServices.postValueService(null, {}, url).then(() => {
  406 + // props.onRefresh();
  407 + // setRefreshCount(pre => pre + 1);
  408 + // })
  409 + // } catch (error) {
  410 + // console.log("=====updateFlushmes报错", {
  411 + // error, changeExecInfo,
  412 + // });
  413 + // props.onRefresh();
  414 + // setRefreshCount(pre => pre + 1);
  415 + // }
  416 + // }
  417 + // };
  418 + //
  419 + // getValue();
  420 + // const timer = setInterval(() => {
  421 + // getValue();
  422 + // }, 1000);
  423 + //
  424 + // return () => {
  425 + // clearInterval(timer);
  426 + // };
  427 + // }, []);
428 428
429 const { bFinish } = props; 429 const { bFinish } = props;
430 const [collapsed, setCollapsed] = useState(false); 430 const [collapsed, setCollapsed] = useState(false);