浏览代码

Merge remote-tracking branch 'origin/dev/new1'

zhouna 5 年之前
父节点
当前提交
924db5e41a
共有 34 个文件被更改,包括 243 次插入109 次删除
  1. 1 1
      src/common/components/EditableSpan/index.less
  2. 1 1
      src/components/AddInspect/SlideSelect/index.jsx
  3. 1 1
      src/components/Advice/index.jsx
  4. 2 2
      src/components/AssessResult/ChartItem/index.jsx
  5. 10 12
      src/components/AssessResult/ScaleItem/index.jsx
  6. 2 2
      src/components/AssessResult/index.jsx
  7. 15 2
      src/components/CheckBody/index.jsx
  8. 2 2
      src/components/ChronicInfo/index.jsx
  9. 23 6
      src/components/DiagnosticList/index.jsx
  10. 7 0
      src/components/Emergency/HisList/index.jsx
  11. 21 4
      src/components/Emergency/index.jsx
  12. 2 10
      src/components/EmergencyProcedure/EmergencyModal/index.jsx
  13. 59 3
      src/components/EmergencyProcedure/EmergencyModal/index.less
  14. 30 0
      src/components/EmergencyProcedure/ImgView/index.jsx
  15. 二进制
      src/components/EmergencyProcedure/img/pic1.png
  16. 二进制
      src/components/EmergencyProcedure/img/pic2.png
  17. 二进制
      src/components/EmergencyProcedure/img/pic3.png
  18. 二进制
      src/components/EmergencyProcedure/img/pic4.png
  19. 二进制
      src/components/EmergencyProcedure/img/pic5.png
  20. 2 3
      src/components/EmergencyProcedure/index.jsx
  21. 2 2
      src/components/PreviewBody/index.jsx
  22. 1 1
      src/components/PushItems/TipsMsg/index.jsx
  23. 2 2
      src/components/PushItems/index.jsx
  24. 1 1
      src/config/index.js
  25. 2 26
      src/containers/AssessResult.js
  26. 8 0
      src/containers/DiagnosticList.js
  27. 6 0
      src/containers/PushItemsContainer.js
  28. 6 1
      src/store/actions/pushMessage.js
  29. 23 17
      src/store/async-actions/fetchModules.js
  30. 3 2
      src/store/async-actions/print.js
  31. 2 2
      src/store/async-actions/pushMessage.js
  32. 3 0
      src/store/async-actions/treat.js
  33. 1 1
      src/store/types/pushMessage.js
  34. 5 5
      src/utils/tools.js

+ 1 - 1
src/common/components/EditableSpan/index.less

@@ -7,7 +7,7 @@
   // line-height: 2;
   height: 16px;
   line-height: 16px;
-  /*vertical-align: middle;*/
+  vertical-align: middle;
   text-align: left;
 }
 .full{

+ 1 - 1
src/components/AddInspect/SlideSelect/index.jsx

@@ -88,7 +88,7 @@ class SlideSelect extends Component {
     let numPlus = 0,numPlus1 = 0;
     let staticTime = {}
     if(dateTime){
-      let tmp1 = dateTime.split(' ')[0].split('-')            
+      let tmp1 = dateTime.split(' ')[0].split('-')
       let tmp2 = (dateTime).split(' ').length>1&&(dateTime).split(' ')[1].split(':')
       staticTime = {
         year: tmp1[0]-0,

+ 1 - 1
src/components/Advice/index.jsx

@@ -81,7 +81,7 @@ class Advice extends Component{
       })}</p>
     })
 
-    return  <div className={`${'mainsuit-box'} ${style['main-suit']}`}>
+    return  <div id="adviceBox" className={`${'mainsuit-box'} ${style['main-suit']}`}>
       <ItemBox title='医嘱' editable={false} border={true} marginTop="10px">
         <div className={style['billing']}>
           {advice.assay && advice.assay.length > 0 || advice.check && advice.check.length > 0 ? <h1>开单项目</h1> : ''}

+ 2 - 2
src/components/AssessResult/ChartItem/index.jsx

@@ -161,7 +161,7 @@ class Chart extends Component{
       let name='';
       it&&it.creatTime.map((x,i)=>{
         inx=xAxis.findIndex((a)=>{
-          name=type=='week'?x.substr(0,13):x.substr(0,10);
+          name=x.substr(0,13);
           return a.substr(0,13)==name;
         });     //日期对应横坐标的位置
         if(inx!=-1){
@@ -222,7 +222,7 @@ class Chart extends Component{
           rotate:65,
           fontSize:10,
           formatter: function(value,index){
-            return value.substr(0,10);
+            return value.substr(0,13);
           }
         }
       },

+ 10 - 12
src/components/AssessResult/ScaleItem/index.jsx

@@ -197,9 +197,9 @@ class ScaleItem extends Component {
           const cresult = showRes&&showRes[1]&&showRes[1].text;
                     temp = <div className={style['results']}>
                     <span>计算公式结果:</span>
-                    <span className={style["blue"]} onClick={this.showFormula.bind(this,item.conceptId,it)}>{cresult?cresult:'请选择'}</span>
-                    <img src={level1} />
-                    <MiniToast title={it.content.name}
+                    <span className={style["blue"]} style={disabled?{cursor:'default'}:''} onClick={disabled?'':this.showFormula.bind(this,item.conceptId,it)}>{cresult?cresult:'请选择'}</span>
+                      {disabled?'':<img src={level1} />}
+                      {disabled?'':<MiniToast title={it.content.name}
                                confirmText='关闭'
                                icon={allTableIcon}
                                show={formulaId&&formulaId==item.conceptId?true:false}
@@ -218,7 +218,6 @@ class ScaleItem extends Component {
                                   return <div className={style["chooseItem"]}>
                                     <Radio label={ii.detailName}
                                            isSelect={ii.state == 1}
-                                           disabled={disabled}
                                            handleClick={this.handleForRadio.bind(this,item.conceptId,details,idd,ind)}>
                                       >
                                     </Radio>
@@ -232,7 +231,7 @@ class ScaleItem extends Component {
                                 <span>{'请输入'+item1.name+':'}</span>
                               </td>
                               <td>
-                                {disabled?item1.value:<input type="text" placeholder="请输入"  value={item1.value} onKeyDown={this.handleReg.bind(this)} onInput={(e)=>this.handleInputformula(item.conceptId,details,idd,e)}/>}
+                                <input type="text" placeholder="请输入"  value={item1.value} onKeyDown={this.handleReg.bind(this)} onInput={(e)=>this.handleInputformula(item.conceptId,details,idd,e)}/>
                               </td>
                               <td>
                                 <span>{item1.uint}</span>
@@ -242,7 +241,7 @@ class ScaleItem extends Component {
                           }
                         })}
                       </table>
-                      {disabled?"":<div className={style["forMulBtn"]} onClick={this.calcuFormula.bind(this,its)}>计算</div>}
+                      <div className={style["forMulBtn"]} onClick={this.calcuFormula.bind(this,its)}>计算</div>
                       <table>
                         {showRes && Array.isArray(showRes) &&showRes.map((itemResult) => {
                           return <tr>
@@ -255,14 +254,14 @@ class ScaleItem extends Component {
                           </tr>
                         })}
                       </table>
-                    </MiniToast>
+                    </MiniToast>}
                 </div>
         }else if(its.type==3){
           temp = <div className={style['results']}>
                     <span>可能结果:</span>
-                    <span onClick={this.showOption.bind(this,item.conceptId)} className={style["blue"]}>{possible&&possible[item.conceptId]?possible[item.conceptId]:'请选择'}</span>
-                    <img src={level1} />
-                    <MiniToast title='结果选择'
+                    <span onClick={disabled?'':this.showOption.bind(this,item.conceptId)} style={disabled?{cursor:'default'}:''} className={style["blue"]}>{possible&&possible[item.conceptId]?possible[item.conceptId]:'请选择'}</span>
+                    {disabled?'':<img src={level1} />}
+                    {disabled?'':<MiniToast title='结果选择'
                          icon={checkIcon}
                          show={optionId&&optionId==item.conceptId?true:false}
                          close={this.closeOption}
@@ -273,7 +272,6 @@ class ScaleItem extends Component {
                           {it.content.details&&it.content.details.map((lis,ind)=>{
                             return <div className={style["chooseItem"]}>
                               <Radio label={lis.detailName}
-                                     disabled={disabled}
                                      isSelect={radioVal&&radioVal[item.conceptId]==lis.detailName}
                                      handleClick={this.handleRadio.bind(this,lis,item,i)}>
                               </Radio>
@@ -281,7 +279,7 @@ class ScaleItem extends Component {
                             </div>
                           })}
                         </div>
-                    </MiniToast>
+                    </MiniToast>}
                   </div>;
         }
         const passId = item.details[j].type==1?item.details[j].content.conceptId:undefined;

+ 2 - 2
src/components/AssessResult/index.jsx

@@ -33,11 +33,11 @@ class AssessResult extends Component {
     this.handleScaleText = this.handleScaleText.bind(this);
     this.handleResult = this.handleResult.bind(this);
   }
-  componentWillMount(){
+  /*componentWillMount(){
     const {disId,disName,getAssess} = this.props;
     //获取评估
     getAssess&&getAssess(disId,disName);
-  }
+  }*/
   handleScaleText(text){
     const {disName} = this.props;
     const obj = Object.assign({},this.state.wholeAssessText);

+ 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)=>{

+ 2 - 2
src/components/ChronicInfo/index.jsx

@@ -415,7 +415,7 @@ class ChronicInfo extends React.Component{
                                             return <div className={style["chooseItem"]}>
                                                     <Radio label={ii.detailName}
                                                              isSelect={ii.state == 1}
-                                                             handleClick={this.handleForRadio.bind(this,v.conceptId,details,idd,ind)}>
+                                                             handleClick={item.isShow == '0' ? '' : this.handleForRadio.bind(this,v.conceptId,details,idd,ind)}>
                                                       </Radio>
                                                   </div>
                                           })}
@@ -427,7 +427,7 @@ class ChronicInfo extends React.Component{
                                           <span>{'请输入'+item.name+':'}</span>
                                         </td>
                                         <td>
-                                          <input type="text" placeholder="请输入"  value={item.value} onKeyDown={this.handleReg.bind(this)} onInput={this.handleInputformula.bind(this,v.conceptId,details,idd)}/>
+                                          <input type="text" placeholder="请输入" readonly={item.isShow == '0'} value={item.value} onKeyDown={this.handleReg.bind(this)} onInput={this.handleInputformula.bind(this,v.conceptId,details,idd)}/>
                                         </td>
                                         <td>
                                           <span>{item.uint}</span>

+ 23 - 6
src/components/DiagnosticList/index.jsx

@@ -15,6 +15,7 @@ import { dragBox } from '@utils/drag';
 import iconRadioDefault from '@common/images/icon-radio-default.png'
 import iconRadioActive from '@common/images/icon-radio-active.png'
 import AssessResult from '@containers/AssessResult';
+import {getAssessData} from '@store/async-actions/fetchModules';
 import tableIcon from '@common/images/table.png';
 import { CONFIRM_TYPE } from "@store/types/typeConfig";
 import $ from "jquery";
@@ -173,7 +174,7 @@ class DiagnosticList extends Component {
         }
     }
     handleQuoteClick(item, index) {
-        const { handleQuoteClick } = this.props
+        // const { handleQuoteClick } = this.props
         // handleQuoteClick && handleQuoteClick(item)
         this.setState({
             activeHistory: index,
@@ -191,12 +192,28 @@ class DiagnosticList extends Component {
         </div>)
     }
     showAssessFn(item){
+      const {setAssess} = this.props;
+      const that = this;
         if(item&&item.conceptId){         //显示评估弹窗
-          this.setState({
-            showAssess:true,
-            isAssessConfirm:false,
-            assessId:item.conceptId,
-            disName:item.name
+          getAssessData(item.conceptId,item.name).then((res)=>{
+            if(res.data.code=='0'){
+              const data = res.data.data;
+              if(!data||data.length==0){
+                Notify.info('暂无数据');
+              }else{
+                setAssess&&setAssess(data,item.name);
+                that.setState({
+                  showAssess:true,
+                  isAssessConfirm:false,
+                  assessId:item.conceptId,
+                  disName:item.name
+                });
+              }
+            }else{
+              Notify.error(res.data.msg);
+            }
+          }).catch(error=>{
+            console.log(error);
           });
         }else{          //关闭评估弹窗
             this.setState({

+ 7 - 0
src/components/Emergency/HisList/index.jsx

@@ -154,6 +154,13 @@ class HisList extends Component {
     return style['export'];
   }
 
+  shouldComponentUpdate(next){
+    if(next.changeInd !==this.props.changeInd){
+      this.setState({index:0})
+    }
+    return true;
+  }
+
   getList(){
     const { data } = this.props;
     let list = data&&data.map((v,i)=>{

+ 21 - 4
src/components/Emergency/index.jsx

@@ -17,7 +17,9 @@ class EmergencyHis extends Component{
       index:0,
       timer:null,
       valChange:true,
-      chooseItem:''
+      chooseItem:'',
+      filtFlag:-1 , //筛选标识
+      changeInd:false
     }
     this.searInp = React.createRef();
     this.handleClose = this.handleClose.bind(this);
@@ -48,6 +50,9 @@ class EmergencyHis extends Component{
   handleFilter(obj){//筛选
     const {filterData} = this.props;
     filterData&&filterData(obj);
+    this.setState({
+      filtFlag:obj.flag
+    }) 
   }
 
   showDetail(index){//病历详情
@@ -96,7 +101,7 @@ class EmergencyHis extends Component{
   }
   // 确认添加
   handleAdd(){
-    const {chooseItem,index} = this.state;
+    const {chooseItem,index,filtFlag,changeInd} = this.state;
     const {addSecond,data} = this.props;
     if(chooseItem.trim()){
       // 添加接口
@@ -111,6 +116,16 @@ class EmergencyHis extends Component{
         chooseItem:''
       });
     }
+    // 在非默认筛选条件下添加二次诊断后重新调筛选接口
+    if(filtFlag !== -1){
+      this.handleFilter({flag:filtFlag});
+      if(filtFlag ==0){//无二次诊断添加后重置index
+        this.setState({
+          index:0,
+          changeInd:!changeInd //重置list中的index标识
+        })
+      }
+    }
   }
 
   componentWillUnmount(){
@@ -122,7 +137,8 @@ class EmergencyHis extends Component{
 
   render(){
     const {show,data,total,preInfo,searchData} = this.props;
-    const {index,valChange} = this.state;
+    // const {index,valChange,changeInd} = this.state;
+    const {index,valChange,changeInd} = this.state;
     // const searchData = [];
     let baseObj = data[index];
     let dataJson,dataStr;
@@ -153,7 +169,8 @@ class EmergencyHis extends Component{
                         getMore={this.getMore} 
                         handleFilter={this.handleFilter}
                         detail={this.showDetail}
-                        handleDownload={this.handleDownload}/>
+                        handleDownload={this.handleDownload}
+                        changeInd={changeInd}/>
               </div>
               <div className={style['emer-right']}>
                 {

+ 2 - 10
src/components/EmergencyProcedure/EmergencyModal/index.jsx

@@ -1,6 +1,7 @@
 import styles from './index.less'
 import small from '../img/small.png'
 import EmergencyPart from '../EmergencyPart'
+import ImgView from '../ImgView'
 import pic from '../img/pic.png'
 import pic1 from '../img/pic1.png'
 import pic2 from '../img/pic2.png'
@@ -67,16 +68,7 @@ class EmergencyModal extends React.Component{
               idx == 0?null:<img className={styles.imgs} src={pic} onClick={()=>{this.handleImgShow(true)}} alt=""/>
             }
             {
-              this.state.imgShow?<React.Fragment>
-                <div className={styles.imageModalWrap} onClick={()=>{this.handleImgShow(false)}}></div>
-                <div className={styles.imageModal} id="dragModalWrap">
-                  <div id="dragModalTitle" className={`${styles.dragImgWrap} drag-title`}>
-                    {data.emergencyname}
-                  </div>
-                  <img id="preImg" className={styles.emergencyImg} src={idx==1?pic1:idx==2?pic2:idx==3?pic3:idx==4?pic4:idx==5?pic5:null}/>
-                  <img className={styles.img} src={close} onClick={()=>{this.handleImgShow(false)}} />
-                </div>
-              </React.Fragment>:null
+              this.state.imgShow?<ImgView name={data.emergencyname} idx={idx} handleImgShow={this.handleImgShow}></ImgView>:null
             }
           </div>
           <div className={styles.modalTopR} onClick={()=>{this.handleSlideShow()}} id="modalTopR">其他危重症状</div>

+ 59 - 3
src/components/EmergencyProcedure/EmergencyModal/index.less

@@ -6,7 +6,7 @@
   bottom: 10px;
   width: 450px;
   right: 10px;
-  z-index: 205;
+  z-index: 202;
   padding: 15px;
   background-color: #fff;
   .modalTop {
@@ -86,10 +86,10 @@
     background-color: #fff;
     overflow: hidden;
     z-index: 500;
-    width: 1000px;
+    width: 900px;
     padding-top: 30px;
     box-sizing: border-box;
-    margin-left: -500px;
+    margin-left: -450px;
     // margin-top: -400px;
     // height: 800px;
     // top: 50%;
@@ -124,4 +124,60 @@
     right: 10px;
     z-index: 800;
   }
+}
+.imageModalWrap {
+  position: fixed;
+  left: 0;
+  top: 0;
+  z-index: 300;
+  width: 100%;
+  height: 100%;
+  background-color: #000;
+  opacity: 0.6;
+  filter: alpha(opacity=60);
+  -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(opacity=60);";
+}
+.imageModal {
+  position: fixed;
+  background-color: #fff;
+  overflow: hidden;
+  z-index: 500;
+  width: 900px;
+  padding-top: 30px;
+  box-sizing: border-box;
+  margin-left: -450px;
+  // margin-top: -400px;
+  // height: 800px;
+  // top: 50%;
+  left: 50%;
+  top: 40px;
+  bottom: 40px;
+  .emergencyImg{
+    height: 100%;
+    width: 100%;
+    max-height: 800px;
+    position: relative;
+    float: left;
+    // position: absolute;
+    // left: 50%;
+    // transform: translateX(-50%);
+  }
+}
+.dragImgWrap {
+  width: 100%;
+  height: 30px;
+  line-height: 36px;
+  text-indent: 1em;
+  z-index: 502;
+  background-color: transparent;
+  position: absolute;
+  top: 0;
+  left: 0;
+}
+img.img{
+  cursor: pointer;
+  position: absolute;
+  top: 6px;
+  right: 10px;
+  z-index: 800;
 }

+ 30 - 0
src/components/EmergencyProcedure/ImgView/index.jsx

@@ -0,0 +1,30 @@
+import styles from '../EmergencyModal/index.less'
+import pic1 from '../img/pic1.png'
+import pic2 from '../img/pic2.png'
+import pic3 from '../img/pic3.png'
+import pic4 from '../img/pic4.png'
+import pic5 from '../img/pic5.png'
+import close from '@common/images/icon_close.png';
+import ReactDom from "react-dom";
+
+class ImgView extends React.Component{
+  constructor(props){
+    super(props)
+  }
+  render(){
+    const {name,idx,handleImgShow} = this.props;
+    const domNode = document.getElementById('root');
+    return ReactDom.createPortal(<React.Fragment>
+            <div className={styles.imageModalWrap} onClick={()=>{handleImgShow(false)}}></div>
+            <div className={styles.imageModal} id="dragModalWrap">
+              <div id="dragModalTitle" className={`${styles.dragImgWrap} drag-title`}>
+                {name}
+              </div>
+              <img id="preImg" className={styles.emergencyImg} src={idx==1?pic1:idx==2?pic2:idx==3?pic3:idx==4?pic4:idx==5?pic5:null}/>
+              <img className={styles.img} src={close} onClick={()=>{handleImgShow(false)}} />
+            </div>
+          </React.Fragment>,domNode)
+  }
+}
+
+export default ImgView;

二进制
src/components/EmergencyProcedure/img/pic1.png


二进制
src/components/EmergencyProcedure/img/pic2.png


二进制
src/components/EmergencyProcedure/img/pic3.png


二进制
src/components/EmergencyProcedure/img/pic4.png


二进制
src/components/EmergencyProcedure/img/pic5.png


+ 2 - 3
src/components/EmergencyProcedure/index.jsx

@@ -13,7 +13,6 @@ class EmergencyProcedure extends React.Component {
     }
     this.handleShow=this.handleShow.bind(this)
   }
-  
   slideToggle(type){
     if(type){
       $("#emergencyName").css({"display":"block"})
@@ -36,9 +35,9 @@ class EmergencyProcedure extends React.Component {
     !type&&this.slideToggle(0)
   }
   render(){
-    const {data,setDataIdx,idx,windowHeight} = this.props;
+    const {data,setDataIdx,idx,windowHeight,hideAllDrop} = this.props;
     const domNode = document.getElementById('root');
-    return ReactDom.createPortal(<div className={styles.emergencyProdureWrap}>
+    return ReactDom.createPortal(<div className={styles.emergencyProdureWrap} onClick={hideAllDrop}>
       <div id="emergencyWrap" className={styles.emergencyWrap}>
         <span id="emergencys" onClick={()=>this.slideToggle(1)} className={styles.emergency}>急</span>
         <span id="emergency" className={`${styles.emergency}`} onClick={()=>this.slideToggle(0)}>急</span>

+ 2 - 2
src/components/PreviewBody/index.jsx

@@ -103,7 +103,7 @@ class PreviewBody extends Component {
   render() {
     const { show, preInfo, dataJson, dataStr, baseObj, flg ,showAssessBtn,showHistoryCases} = this.props;
     const other_yjs = dataStr.other?filterOtherDataArr(JSON.parse(dataStr.other),dataJson.other):'';
-    const isChronic = (dataJson.diagChronicMagItem&&dataJson.diagChronicMagItem.name)||(dataJson.mainChronicDesease&&dataJson.mainChronicDesease.name);
+    //const isChronic = (dataJson.diagChronicMagItem&&dataJson.diagChronicMagItem.name)||(dataJson.mainChronicDesease&&dataJson.mainChronicDesease.name);
     const noData = JSON.stringify(preInfo) == '{}';
     return <div className={style['content']} style={{ width: flg ? '700' : '820' }}>
       <div className={style['contents']} id="content" style={{ margin: "0 auto", maxWidth: "620px" }}>
@@ -144,7 +144,7 @@ class PreviewBody extends Component {
           </tr>
         </table>
         <p className={style.docName}>医生签名:<span>{baseObj ? baseObj.doctorName : (noData ? '' : preInfo.doctorName)}</span></p>
-        {showAssessBtn&&isChronic?<AssessResultHis showHistoryCases={showHistoryCases} inquiryId={baseObj&&baseObj.id} inquiryDate={baseObj&&baseObj.inquiryDate}></AssessResultHis>:""}
+        {showAssessBtn&&dataJson.haveAssess?<AssessResultHis showHistoryCases={showHistoryCases} inquiryId={baseObj&&baseObj.id} inquiryDate={baseObj&&baseObj.inquiryDate}></AssessResultHis>:""}
         <div onClick={() => { this.surePrint(dataStr) }} className={style.printBtn} style={{
           display: show ? 'inline-block' : 'none',
         }}>打印</div>

+ 1 - 1
src/components/PushItems/TipsMsg/index.jsx

@@ -17,7 +17,7 @@ class TipsMsg extends Component {
 
     render() {
         const { tips, showTips, tipsDiscalimer, tipsImg, tmpFlg} = this.props;
-        return <div className={style["tips"]}>
+        return <div id="tipsMsg" className={style["tips"]}>
         <h1>
           <img src={tipsImg} />
           提示信息

+ 2 - 2
src/components/PushItems/index.jsx

@@ -160,7 +160,7 @@ class PushItems extends Component {
       tipsDetails,
       tmpFlg,
     } = this.props.pushMessage;
-    const { tipsDiscalimer,chronicPushItems,wholeIndexs,setPushEmergencyIdx,sysConfig,windowHeight} = this.props;
+    const { tipsDiscalimer,chronicPushItems,wholeIndexs,setPushEmergencyIdx,sysConfig,windowHeight,hideAllDrop} = this.props;
     const {
       billing,
       changeCheck,
@@ -281,7 +281,7 @@ class PushItems extends Component {
             tipsDetails = {tipsDetails}/>}
             
             {
-              (setPushEmergencyIdx+'')&&(sysConfig.emergency_show==1)&&<EmergencyProcedure windowHeight={windowHeight} data={dataLis[this.state.idx]||dataLis[setPushEmergencyIdx]} idx={this.state.idx||setPushEmergencyIdx} setDataIdx={this.setDataIdx}></EmergencyProcedure>
+              (setPushEmergencyIdx+'')&&(sysConfig.emergency_show==1)&&<EmergencyProcedure hideAllDrop={hideAllDrop} windowHeight={windowHeight} data={dataLis[this.state.idx]||dataLis[setPushEmergencyIdx]} idx={this.state.idx||setPushEmergencyIdx} setDataIdx={this.setDataIdx}></EmergencyProcedure>
             }
       </div>
     );

+ 1 - 1
src/config/index.js

@@ -30,7 +30,7 @@ export default {
     chartDismen:'year',   //评估图表默认维度:近1年year,近6个月sixMonth,近1个月month,近1周week
     chartSymbols:['emptyCircle' , 'rect', 'arrow', 'triangle', 'diamond','circle', 'pin', 'roundRect'],
     chartColors:['#E84C47','#B947E8', '#47B0E8', '#4774E8', '#6C4EF9','#63DEC2', '#DDD81D','#EF592B'],
-    showCheckNum:16,        //查体默认展开非自由文本标签的个数
+    showCheckNum:22,        //查体默认展开非自由文本标签的个数
     radioOptionPer:'()',     //单选项输入占位符
     textReg:new RegExp("([\u4E00-\uFA29]|[\uE7C7-\uE7F3]|[a-zA-Z0-9])"), //包含中英文或数字
     slideTime:400,      //右侧指标推送展开/收起动画时间

+ 2 - 26
src/containers/AssessResult.js

@@ -3,8 +3,8 @@ import {connect} from 'react-redux';
 import AssessResult from '@components/AssessResult';
 import {ISREAD} from '@store/types/homePage.js';
 import {billing} from '@store/async-actions/pushMessage';
-import {getAssessData,getIndexData} from '@store/async-actions/fetchModules';
-import {SET_ASSESS_DATA,SET_INDEX_DATA,SET_INDEX_SUB_TYPE,REMOVE_ASSESS_ITEMS,CLEAR_INDEX_DATA,SET_CHRONIC_CALCU_RESULT,SET_CALCU_VALUES} from '@types/assessResult';
+import {getIndexData} from '@store/async-actions/fetchModules';
+import {SET_INDEX_DATA,SET_INDEX_SUB_TYPE,REMOVE_ASSESS_ITEMS,CLEAR_INDEX_DATA,SET_CHRONIC_CALCU_RESULT,SET_CALCU_VALUES} from '@types/assessResult';
 import {parseChartData,deepClone} from '@utils/tools';
 import {SHOW_TABLE_LIST,HIDE_TABLE_LIST} from '@store/types/pushMessage';
 import {saveMessage} from "../store/async-actions/print";
@@ -47,30 +47,6 @@ function mapStateToProps(state) {
 
 function mapDispatchToProps(dispatch) {
   return {
-    getAssess(disId,disName){        //获取评估内容数据
-      dispatch(getAssessData(disId,disName)).then((res)=>{
-        if(res.data.code=='0'){
-          dispatch({
-            type:SET_ASSESS_DATA,
-            data:res.data.data,
-            name:disName
-          })
-        }else{
-          dispatch({
-            type:SET_ASSESS_DATA,
-            data:[],
-            name:disName
-          })
-        }
-      }).catch(error=>{
-        dispatch({
-          type:SET_ASSESS_DATA,
-          data:[],
-          name:disName
-        });
-        console.log(error);
-      });
-    },
     getIndexData(param){        //获取评估图表数据
       const {range,rangeType,index,pindex,getNew,disName} = param;
       dispatch(getIndexData(range,disName)).then((res)=>{

+ 8 - 0
src/containers/DiagnosticList.js

@@ -11,6 +11,7 @@ import {CURRENT_CHRONIC} from '@store/types/currentIll';
 import {autoFillModules} from '@store/async-actions/fetchModules';
 import { initItemList } from '@store/async-actions/historyTemplates';
 import {MODI_LOADING} from '@store/types/homePage.js';
+import {SET_ASSESS_DATA} from '@types/assessResult';
 
 function mapStateToProps(state) {
     const {diagnosticList,assessResult,pushMessage } = state;
@@ -34,6 +35,13 @@ function mapStateToProps(state) {
 
 function mapDispatchToProps(dispatch) {
     return {
+      setAssess(data,disName){        //获取评估内容数据
+        dispatch({
+          type:SET_ASSESS_DATA,
+          data:data,
+          name:disName
+        });
+      },
         delDiagnostic: (item) => {
             dispatch({
                 type: DEL_DIAGNOSTIC,

+ 6 - 0
src/containers/PushItemsContainer.js

@@ -5,6 +5,7 @@ import {CHANGE_ASSAY, CHANGE_CHECK, ADD_BILLING, SHOW_TIPS_DETAILS, HIDE_TIPS_DE
 import { ADD_DIAGNOSTIC, GET_DIAGNOSTIC_STR } from '@store/types/diagnosticList';
 import {billing, getAllConceptDetail} from '../store/async-actions/pushMessage';
 import { isAddMainSuit } from '@store/async-actions/diagnosticList';
+import { HIDEDROP } from '@store/types/homePage.js';
 
 function mapStateToProps(state) {//console.log(state)
   const {pushMessage,diagnosticList} = state;
@@ -24,6 +25,11 @@ function mapStateToProps(state) {//console.log(state)
 
 function mapDispatchToProps(dispatch) {
     return {
+        hideAllDrop(){
+            dispatch({
+              type:HIDEDROP
+            });
+        },
         changeAssay: (item) => {
             dispatch({type: CHANGE_ASSAY, item})
         },

+ 6 - 1
src/store/actions/pushMessage.js

@@ -87,7 +87,7 @@ export const addScheme = (state, action) => {
   const scheme = res.advice.scheme || [];
   let isRepeat = false; 
   let RepeatIndex;
-  
+  let SelectedDrugNum = 0 	//选中的药品数量
   for (let i = 0; i < treatment.length; i++) {
 		let treatmentStr = '';
 		let drugList = []
@@ -95,11 +95,15 @@ export const addScheme = (state, action) => {
       if(treatment[i].medicitionsList[j].selected) {
 				treatmentStr = treatmentStr + treatment[i].medicitionsList[j].medicitionName + ', '
 				drugList.push({conceptId: treatment[i].medicitionsList[j].conceptId, conceptName: treatment[i].medicitionsList[j].medicitionName })
+				SelectedDrugNum++
 			}
 	}
 	treatment[i].treatmentStr = treatmentStr.substring(0,treatmentStr.length-2)
 	treatment[i].drugList = drugList
   }
+  if(SelectedDrugNum > 0) { //如果有选中的药品,滚动到医嘱框
+	document.getElementById("adviceBox").scrollIntoView(true)
+  }
   treatItem.treatment = treatment;
   for (let i = 0; i < scheme.length; i++) {
     if (scheme[i].name === treatItem.name) {
@@ -156,6 +160,7 @@ export const addScheme = (state, action) => {
 	if (res.advice.scheme) {
 		res.advice.drugList = getDrugList(res.advice.scheme)
 	}
+	
   return res;
 }
 

+ 23 - 17
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,
@@ -261,7 +261,7 @@ export function saveMode(mode){
 
 //慢病-获取管理评估
 export function getAssessData(disId,disName){
-  return ()=>{
+  //return ()=>{
     const emrData = getEMRParams();
     const param = {
       diseaseId:disId,
@@ -275,7 +275,7 @@ export function getAssessData(disId,disName){
       symptom:emrData.current + emrData.main
     };
     return json(api.getAssess,param);
-  }
+  //}
 }
 
 //慢病-获取管理评估历史单条记录
@@ -336,23 +336,27 @@ export function getAllHis(item){
   return (dispatch,getStore)=>{
     const state = getStore();
     const {message} = state.patInfo;
-    const params = {
-      "current": item.current,
-      // "endDate": item.endDate,
-      "hospitalDeptId": message.hospitalDeptId,
-      "hospitalId": message.hospitalId,
-      "size": 6,
-      // "startDate": item.startDate,
+    const {params} = state.emergencyHis;
+    let param = {};
+    if(JSON.stringify(params) == '{}'){
+      param = {
+        "current": item.current,
+        "hospitalDeptId": message.hospitalDeptId,
+        "hospitalId": message.hospitalId,
+        "size": 6,
+      }
+    }else{
+      param = Object.assign({},params,{current:item.current})
     }
 
-    json(api.getAllHisURL,params).then((res)=>{
+    json(api.getAllHisURL,param).then((res)=>{
       const result = res.data;
       if(result.code == 0){
         dispatch({
           type:GET_ALL_HIS,
           data:result.data.inquiryList,
           total:result.data.total,
-          params:params,
+          params:param,
         })
       }
     })
@@ -366,13 +370,14 @@ export function getFilterHis(obj){
     const {params} = state.emergencyHis;
     let newParam = {};
     if(obj.flag == 999){//时间筛选
-      newParam = Object.assign(params,{startDate:obj.startDate,endDate:obj.endDate})
+      newParam = Object.assign(params,{startDate:obj.startDate,endDate:obj.endDate,current:1})
     }else{
-      if(obj.flag==-1){
+      /*if(obj.flag==-1){
         newParam = Object.assign(params,{current:1})
       }else{
-        newParam = Object.assign({},params,{isHasSecond:obj.flag})
-      }
+        newParam = Object.assign({},params,{isHasSecond:obj.flag,current:1})
+      }*/
+      newParam = Object.assign({},params,{isHasSecond:obj.flag,current:1})
     }
 
     json(api.getAllHisURL,newParam).then((res)=>{
@@ -382,7 +387,8 @@ export function getFilterHis(obj){
           type:FILTER_ALL_HIS,
           data:result.data.inquiryList,
           total:result.data.total,
-          params:Object.assign(params,{current:1}),
+          // params:Object.assign(params,{current:1}),
+          params:Object.assign(newParam,{current:1}),
         })
       }
     })

+ 3 - 2
src/store/async-actions/print.js

@@ -19,8 +19,9 @@ export const saveMessage = (bool) => {
     let jsonData = getAllDataList(baseList);
     const lisData = baseList.inspect.pushItem;
     const lisArr = transferIndexData(lisData);
+    const haveAssess = Object.keys(baseList.assessResult.data).length>0;
     const evaluation={
-      htmlContent:JSON.stringify(getEvaluations(baseList.assessResult,pushMessage)),
+      htmlContent:haveAssess?JSON.stringify(getEvaluations(baseList.assessResult,pushMessage)):'{}',
       //scaleList:[]
     };//getEvaluation();
     //console.log(baseList)
@@ -30,7 +31,7 @@ export const saveMessage = (bool) => {
         "hospitalDeptId": state.hospitalDeptId,
         "hospitalId": state.hospitalId,
         "patientId": state.patientId,         //患者id              
-        "dataJson": JSON.stringify(getAllDataList(baseList)),
+        "dataJson": JSON.stringify(Object.assign({haveAssess:haveAssess},jsonData)),
         "indexData":lisArr,
         "inquiryEvaluation":evaluation,
         "detailList": [{

+ 2 - 2
src/store/async-actions/pushMessage.js

@@ -25,7 +25,7 @@ export const billing = (mdata,boxMark) => {
   const emrData = getEMRParams();
   const params = {
     age: emrData.age,
-    featureType: getCheck?"4,41,5,6,7":"4,5,6,7",    //41只返回查体模板,4只返回查体高亮
+    featureType: getCheck?"42,41,5,6,7":"42,5,6,7",    //41只返回查体模板,4只返回查体高亮
     // featureType: "22",
     diag: emrData.dis,
     lis: emrData.lis,
@@ -160,7 +160,7 @@ export const getConceptDetail = (item) => {
                           flag:true
                         });
                     }
-                    
+                    document.getElementById("tipsMsg").scrollIntoView(true)
                 } else if(item.position == '5' || item.position == '6'){    //药品或不良反应说明
                     dispatch({
                         type: SET_DRUG_INFO,

+ 3 - 0
src/store/async-actions/treat.js

@@ -415,6 +415,9 @@ export const commonTreatAddToAdvice = () => {
                     hasFollowUp: true
                 })
             }
+            if(state.treat.generalTreat.content || followUp) { //如果一般治疗和回访时间存在,定位到医嘱
+                document.getElementById("adviceBox").scrollIntoView(true)
+            }
             
         } else {
             return

+ 1 - 1
src/store/types/pushMessage.js

@@ -21,7 +21,7 @@ export const SET_CHRONIC_PUSHS ='SET_CHRONIC_PUSHS'; //右侧慢病量表评估
 export const SET_SCALE_INFO = 'SET_SCALE_INFO' ; //量表明细
 export const SAVE_TABLE_RESULT = 'SAVE_TABLE_RESULT' ; //量表计算结果
 export const SAVE_FOLLOW_UP = 'SAVE_FOLLOW_UP';  //保存回访时间
-export const DEL_FOLLOW_UP = 'DEL_FOLLOW_UP';  //保存回访时间
+export const DEL_FOLLOW_UP = 'DEL_FOLLOW_UP';  //删除回访时间
 export const TOGGLE_CHRONIC_INFO = 'TOGGLE_CHRONIC_INFO';   //收起展开指标推送模块
 
 

+ 5 - 5
src/utils/tools.js

@@ -734,14 +734,14 @@ function ifOtherClear(jsonData,jsonStr,baseList){
   }
 }
 function normalVal(min,max){
-  if(min == ''&&max==''){
+  if(!min&&!max){
     return null;
-  }else if(!isNaN(min) && !isNaN(max)){
+  }else if(min&&max){
       return `正常值: (${min}~${max})`
-  }else if(!isNaN(min) && isNaN(max)){
-      return `正常值: (>${min})`
-  }else if(isNaN(min) && !isNaN(max)){
+  }else if(!min && max){
       return `正常值: (<${max})`
+  }else if(min && !max){
+      return `正常值: (>${min})`
   }
 }
 /**