Browse Source

Merge branch 'bugFix20190722' of http://192.168.2.236:10080/zhouna/newICSS into bugFix20190722

liucf 5 years ago
parent
commit
381224acd1
2 changed files with 16 additions and 3 deletions
  1. 15 2
      src/components/CheckBody/index.jsx
  2. 1 1
      src/store/async-actions/fetchModules.js

+ 15 - 2
src/components/CheckBody/index.jsx

@@ -34,19 +34,32 @@ class CheckBody extends Component{
     }
     this.setState({boxLeft:next.boxLeft})
   }
+  isThereHigh(arr,ids){
+    if(!arr||!ids){
+      return false;
+    }
+    const item = arr.find((it)=>{
+      return ids.includes(it.id);
+    });
+    if(item){
+      return true;
+    }
+    return false;
+  }
   getLabels(){
     const {data,showArr,saveText,selecteds,importLabel} = this.props;
     let arr = [],list=[];
     const {boxMark,showAll} = this.state;
     const moreNum =data.length-[...data].reverse().findIndex((it)=>it.showInCheck)-1;//被隐藏的位置
     const moreText = filterDataArr([...saveText].splice(moreNum+1));     //被收起的标签中是否有有值得,有则不能再收起showMoreBtn?more:''
+    const hasHigh = this.isThereHigh([...data].splice(moreNum+1),importLabel);         //隐藏的标签中是否有高亮的
     const more = showAll?<span className={style['more']} onClick={this.showHide}>收起<img src={hideImg} /></span>:<span className={style['more']} onClick={this.showHide}>展开<img src={showImg} /></span>;
-    const showMoreBtn = data.length>config.showCheckNum&&(data.length-1>moreNum&&!data[0].full)&&!moreText;
+    const showMoreBtn = data.length>config.showCheckNum&&(data.length-1>moreNum&&!data[0].full)&&!moreText&&!hasHigh;
     let showArray = data.filter((it)=>{
       if(it.showInCheck)
         return it;
     });
-    const showData = moreText||showAll?[...data]:showArray;//[...data].splice(0,config.showCheckNum*2+1);
+    const showData = moreText||hasHigh||showAll?[...data]:showArray;//[...data].splice(0,config.showCheckNum*2+1);
     if(showData){
       list = showData;
       arr = list.map((it,i)=>{

+ 1 - 1
src/store/async-actions/fetchModules.js

@@ -148,7 +148,7 @@ export function pregetCheckbodyData(flag){     //flag=true获取到数据后立
     const emrData = getEMRParams();
     const param = {
       age: emrData.age,
-      featureType: "1,4,41,7",
+      featureType: "1,42,41,7",
       diag: emrData.dis,
       lis: emrData.lis,
       other: emrData.other,