瀏覽代碼

Merge branch 'newVersion6.0' of http://192.168.2.236:10080/zhouna/newICSS into newVersion6.0

zhangxc 4 年之前
父節點
當前提交
b1d92bfbf0
共有 42 個文件被更改,包括 348 次插入297 次删除
  1. 2 2
      src/common/components/SearchOption/index.jsx
  2. 27 8
      src/components/AddAssistCheck/index.jsx
  3. 43 25
      src/components/AddInspect/SlidePic/index.jsx
  4. 2 2
      src/components/AddInspect/index.jsx
  5. 24 62
      src/components/AddNewInspect/SlidePic/index.jsx
  6. 2 1
      src/components/AddNewInspect/index.jsx
  7. 1 0
      src/components/AddNewInspect/index.less
  8. 2 1
      src/components/AssistCheck/index.jsx
  9. 10 12
      src/components/BlockEmrCont/index.jsx
  10. 2 2
      src/components/BlockEmrCont/index.less
  11. 2 1
      src/components/BodyContainer/index.jsx
  12. 1 1
      src/components/DiagResultSearch/index.jsx
  13. 9 3
      src/components/DiagResultSearch/index.less
  14. 1 7
      src/components/Diagnosis/index.jsx
  15. 45 23
      src/components/HistoryCaseContainer/HistoryList/index.jsx
  16. 5 2
      src/components/InfoTitle/index.jsx
  17. 7 0
      src/components/PatInfo/Select/index.jsx
  18. 8 8
      src/components/PatInfo/index.less
  19. 1 1
      src/components/PreviewBody/MedicalAdvice/index.jsx
  20. 20 1
      src/components/PreviewBody/index.jsx
  21. 0 1
      src/components/PushData/index.jsx
  22. 4 1
      src/containers/AssistCheck.js
  23. 1 1
      src/containers/BlockEMRContanier.js
  24. 5 0
      src/containers/Diagnosis.js
  25. 5 2
      src/containers/HistoryCases.js
  26. 3 3
      src/containers/Inspect.js
  27. 2 2
      src/containers/NewAdvice.js
  28. 7 1
      src/store/actions/assistCheck.js
  29. 5 1
      src/store/actions/historyTemplates.js
  30. 5 4
      src/store/actions/inspect.js
  31. 3 2
      src/store/actions/newAdvice.js
  32. 1 1
      src/store/async-actions/historyTemplates.js
  33. 4 1
      src/store/async-actions/inspect.js
  34. 17 0
      src/store/reducers/assistCheck.js
  35. 9 1
      src/store/reducers/historyTemplates.js
  36. 16 65
      src/store/reducers/inspect.js
  37. 21 5
      src/store/reducers/newAdvice.js
  38. 1 0
      src/store/types/assistCheck.js
  39. 1 0
      src/store/types/historyTemplates.js
  40. 1 1
      src/store/types/inspect.js
  41. 1 3
      src/utils/ajax.js
  42. 22 40
      src/utils/tools.js

+ 2 - 2
src/common/components/SearchOption/index.jsx

@@ -50,7 +50,6 @@ class SearchOption extends React.Component {
         })
     }
     handleClearVal(){
-        console.log(12312313);
         const { handleChangeValue } = this.props;
         this.textInput.current.value = '';
         this.textInput.current.focus();
@@ -99,7 +98,7 @@ class SearchOption extends React.Component {
         });
     }
     handleFocus(){
-        console.log(1223);
+
       this.setState({showInsp:false})
       if(this.state.val.trim() != ''){
         return;
@@ -108,6 +107,7 @@ class SearchOption extends React.Component {
       }
     }
     handleBlur(){
+
       this.setState({border:false,val:''})
     }
     render() {

+ 27 - 8
src/components/AddAssistCheck/index.jsx

@@ -6,7 +6,6 @@ import Textarea from './Textarea';
 import AssistName from './AssistName';
 import { getPageCoordinate,getCurrentDate,setPosition, setFontColorSize } from '@utils/tools';
 import ScrollArea from 'react-scrollbar';
-import { autoFillModules } from '../../store/async-actions/fetchModules';
 
 class AddAssistCheck extends React.Component {
   constructor(props) {
@@ -106,6 +105,7 @@ class AddAssistCheck extends React.Component {
   }
 
   handleSearchShow(e) {
+    const { handlePush } = this.props;
     let tmpShow = this.state.show;
     this.setState({ show: !tmpShow,pageTop:getPageCoordinate(e).boxTop })
     // e.stopPropagation(); 
@@ -113,6 +113,7 @@ class AddAssistCheck extends React.Component {
       this.props.setHighter(48)
     }else{
       setPosition(e,"#searchOption",this.props.setHighter)
+      handlePush && handlePush({mode:9});           //右侧推送
     }
   }
   handleShowDate(idx) {
@@ -179,7 +180,19 @@ class AddAssistCheck extends React.Component {
     this.props.handleChangeDate(date,idx)
     this.setState({ date: false })
   }
-
+  setEdit(e){
+    $('.canEdit').blur().attr('disabled','disabled')
+    $(e.target).removeAttr('disabled').focus()
+  }
+  handleBlur(){
+    const {handlePush} = this.props;
+    $('.canEdit').attr('disabled','disabled')
+    handlePush && handlePush({mode:8});       //右侧推送
+  }
+  handleInput(e,item,idx){
+    const {setTipValue} = this.props
+    setTipValue(item,e.target.value,idx)
+  }
   getAssistLabel() {
     const { assistLabel,checkedListImport, handleChangeAssistValue,checkOnOff, handleChangeDate, isRead, handlePush, winWidth,getInfomation,assistList } = this.props;
     const { visible,activeName,id,date } = this.state;
@@ -232,13 +245,19 @@ class AddAssistCheck extends React.Component {
                 </ScrollArea>
               </div>
               <div className={`${styles.pointerFinger} ${setFontColorSize(2,2)}`}>
-                <p>报告日期:<span>{item.time || this.state.dateTime}</span></p>
-                {/* <i onClick={() => this.handleShowDate(idx)}></i> */}
-                {/*<a href="javascript:void(0);" onClick={() => { this.handleDelClick(idx,item) }}><img src={close} alt="" /></a>*/}
+                <p>报告日期:<span>
+                  <input disabled="disabled" type="text" 
+                      class="canEdit"
+                      onDoubleClick={(e)=>this.setEdit(e)}
+                      style={'#333'}
+                      placeholder='时间'
+                      autoComplete="off"
+                      value={item.time}
+                      onInput={(e)=>{this.handleInput(e,item,idx)}}
+                      onBlur={()=>{this.handleBlur()}}
+                      />
+                </span></p>
                 <span className={styles.closeIcon} id="assiClose" onClick={() => { this.handleDelClick(idx,item) }}></span>
-                {/* {
-                  this.state.date && idx == this.state.active ?<Calendar timeLis={staticTime} isShow={true} timeSure={(date)=>this.timeSure(date,idx)} needTime={true} sure={true} handleChange={(info) => { this.handleChangeDate(info, idx) }} top={30}></Calendar>:null
-                } */}
               </div>
               <DelToast show={idx==id&&item.name==activeName?visible:false}
                   name={activeName}

+ 43 - 25
src/components/AddInspect/SlidePic/index.jsx

@@ -79,16 +79,6 @@ class SlideSelect extends Component {
       show:!tmpShow
     })
   }
-  setEdit(){
-    this.setState({
-      canEdit:false
-    },()=>{
-      $(".canEdit").focus()
-      $(".canEdit").blur(()=>{
-        this.setState({canEdit:true})
-      })
-    })
-  }
   handleDel(time){
     const {handleDelClick,item} = this.props;
     this.setState({
@@ -127,17 +117,19 @@ class SlideSelect extends Component {
       refreshScroller()&&refreshScroller().scrollYTo(290);
     })*/
   }
-  handleInput(e,item){
+  handleInput(e,item,sign){
     const {setTipValue} = this.props
-    setTipValue(item,e.target.value)
-    let type = getArrow(item.minValue,item.maxValue,e.target.value||null)
-    this.setState({
-      value:e.target.value,
-      style:type
-    })
+    setTipValue(item,e.target.value,sign)
+    if(sign == 2){
+      let type = getArrow(item.minValue,item.maxValue,e.target.value||null)
+      this.setState({
+        style:type
+      })
+    }
   }
   handleBlur(){
     const {handlePush} = this.props;
+    $('.canEdit').attr('disabled','disabled')
     handlePush && handlePush({mode:8});       //右侧推送
   }
   checkOnOff(item){
@@ -145,6 +137,10 @@ class SlideSelect extends Component {
     checkOnOff(item)
     handlePush && handlePush({mode:8});       //右侧推送
   }
+  setEdit(e){
+    $('.canEdit').blur().attr('disabled','disabled')
+    $(e.target).removeAttr('disabled').focus()
+  }
   render() {
     const {item,idx,time} = this.props;
     const {canEdit,activeInd,activeName,value,style} = this.state;
@@ -157,7 +153,18 @@ class SlideSelect extends Component {
               <span className={styles.smallname}></span>
               <span className={styles.edit}></span>
               <span className={styles.maxmin}></span>
-              <span className={styles.pass}>检验时间:{item.time}</span>
+              <span className={styles.pass}>检验时间:
+                <input disabled="disabled" type="text" 
+                    class="canEdit" 
+                    onDoubleClick={(e)=>this.setEdit(e)}
+                    style={{color:style==2||style==4?'red':style==1?'#D949FF':'#333'}}
+                    placeholder='时间'
+                    autoComplete="off"
+                    value={item.time}
+                    onInput={(e)=>{this.handleInput(e,item,1)}}
+                    onBlur={()=>{this.handleBlur()}}
+                    />
+              </span>
               <span id="addClose" className={styles.partDel} onClick={()=>{this.handleDel(item.time)}}></span>
             </tr>
           </table>
@@ -172,19 +179,30 @@ class SlideSelect extends Component {
           <span className={styles.bigname}>{item.name}</span>
           <span className={styles.smallname}>{item.uniqueName}</span>
           <span className={styles.edit}>
-            <input disabled={canEdit} type="text" 
-              class="canEdit" 
-              onDoubleClick={this.setEdit}
-              style={{color:style==2||style==4?'red':style==1?'#D949FF':'#333'}}
+            <input disabled="disabled" type="text" 
+              class="canEdit"
+              onDoubleClick={(e)=>this.setEdit(e)}
+              style={{ color: style == 2 || style == 4 ? 'red' : style == 1 ? '#D949FF' : '#333', backgroundColor: item.value && item.value.length>0 ? '#eeeeee' : ''}}
               placeholder='(填写)'
               autoComplete="off"
-              value={value}
-              onInput={(e)=>{this.handleInput(e,item)}}
+              value={item.value||item.otherValue}
+              onInput={(e)=>{this.handleInput(e,item,2)}}
               onBlur={()=>{this.handleBlur()}}
               /><img style={{display:style==1||style==2?'inline-block':'none'}} src={style==1?down:style==2?up:''} />{item.units}
           </span>
           <span className={styles.maxmin}>{normalVal(item.minValue,item.maxValue)}</span>
-          <span className={styles.pass}>检验时间:{item.time}</span>
+          <span className={styles.pass}>检验时间:
+            <input disabled="disabled" type="text" 
+                class="canEdit" 
+                onDoubleClick={(e)=>this.setEdit(e)}
+                style={{color:style==2||style==4?'red':style==1?'#D949FF':'#333'}}
+                placeholder='时间'
+                autoComplete="off"
+                value={item.time}
+                onInput={(e)=>{this.handleInput(e,item,1)}}
+                onBlur={()=>{this.handleBlur()}}
+                />
+          </span>
           <span id="addClose" className={styles.partDel} onClick={()=>{this.handleDel(item.time)}}></span>
           <DelToast show={time==item.time&&activeInd?true:false}
                     name={activeName}

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

@@ -126,7 +126,6 @@ class Inspect extends React.Component {
   }
   changeShowFill() {
     this.setState({ showFill: false })
-    console.log(123123);
     this.props.setHighter(48)
   }
   handleChangeDate(info) {
@@ -135,12 +134,13 @@ class Inspect extends React.Component {
   }
   handleSearchShow(e) {
     let tmpShow = this.state.show;
+    const { handlePush } = this.props;
     this.setState({ show: !tmpShow, pageTop: getPageCoordinate(e).boxTop })
-    // e.stopPropagation();
     if(tmpShow){
       this.props.setHighter(48)
     }else{
       this.props.detailClick(2)
+      handlePush && handlePush({mode:8});       //右侧推送
       setPosition(e,"#searchOption",this.props.setHighter)
     }
   }

+ 24 - 62
src/components/AddNewInspect/SlidePic/index.jsx

@@ -78,16 +78,6 @@ class SlidePic extends Component {
       show:!tmpShow
     })
   }
-  setEdit(){
-    this.setState({
-      canEdit:false
-    },()=>{
-      $(".canEdit").focus()
-      $(".canEdit").blur(()=>{
-        this.setState({canEdit:true})
-      })
-    })
-  }
   handleDel(time){
     const {handleDelClick,item} = this.props;
     this.setState({
@@ -126,17 +116,13 @@ class SlidePic extends Component {
       refreshScroller()&&refreshScroller().scrollYTo(290);
     })*/
   }
-  handleInput(e,item){
+  handleInput(e,item,sign){
     const {setTipValue} = this.props
-    setTipValue(item,e.target.value)
-    let type = getArrow(item.minValue,item.maxValue,e.target.value||null)
-    this.setState({
-      value:e.target.value,
-      style:type
-    })
+    setTipValue(item,e.target.value,sign)
   }
   handleBlur(){
     const {handlePush} = this.props;
+    $('.canEdit').attr('disabled','disabled')
     handlePush && handlePush({mode:8});       //右侧推送
   }
   checkOnOff(item){
@@ -144,69 +130,45 @@ class SlidePic extends Component {
     checkOnOff(item)
     handlePush && handlePush({mode:8});       //右侧推送
   }
+  setEdit(e){
+    $('.canEdit').blur().attr('disabled','disabled')
+    $(e.target).removeAttr('disabled').focus()
+  }
   render() {
     const {item,time} = this.props;
     const {canEdit,activeInd,activeName,value,style} = this.state;
     return (
-      item.flg == 1?<li key={item.time} className={`${styles.slideLi} clearfix`}> 
-          <span className={styles.bigname}>{item.uniqueName}</span>
-          <span className={styles.smallname}></span>
-          <span className={styles.edit}></span>
-          <span className={styles.maxmin}></span>
-          <span className={styles.pass}>检验时间:{item.time}</span>
-          <span id="addClose" className={styles.partDel} onClick={()=>{this.handleDel(item.time)}}></span>
-          <DelToast show={time==item.time&&activeInd?true:false}
-                    name={activeName}
-                    right={'-34px'}
-                    top={'30px'}
-                    cancel={this.handleCancel}
-                    confirm={()=>{this.delConfirm(item)}}/>
-      </li>:(item.flg == 5||item.flg == 6)?<li key={item.time} className={`${styles.slideLi} clearfix`}> 
+      <li key={item.time} className={`${styles.slideLi} clearfix`}> 
           <img className={styles.imgCheck} src={item.check?checkOn:checkOff} onClick={()=>this.checkOnOff(item)} alt=""/>
           <span className={styles.bigname}>{item.name}</span>
           <span className={styles.smallname}>{item.flg == 5?'药品':'手术/操作'}</span>
           <span className={styles.edit}>
             {
               item.flg == 5?
-              <input disabled={canEdit} type="text" 
-                className="canEdit" 
-                onDoubleClick={this.setEdit}
+              <input disabled='disabled' type="text" 
+                class="canEdit" 
+                onDoubleClick={(e)=>this.setEdit(e)}
                 style={{color:style==2||style==4?'red':style==1?'#D949FF':'#333'}}
                 placeholder='(填写用法计量)'
                 autoComplete="off"
-                value={value}
-                onInput={(e)=>{this.handleInput(e,item)}}
+                value={item.value}
+                onInput={(e)=>{this.handleInput(e,item,2)}}
                 onBlur={()=>{this.handleBlur()}}
                 />:null
             }
           </span>
-          {/* <span className={styles.maxmin}></span> */}
-          <span className={styles.pass}>{item.time}</span>
-          <span id="addClose" className={styles.partDel} onClick={()=>{this.handleDel(item.time)}}></span>
-          <DelToast show={time==item.time&&activeInd?true:false}
-                    name={activeName}
-                    right={'-34px'}
-                    top={'30px'}
-                    cancel={this.handleCancel}
-                    confirm={()=>{this.delConfirm(item)}}/>
-      </li>:<li key={item.time} className={`${styles.slideLi} clearfix`}> 
-          <span className={styles.bigname}>{item.name}</span>
-          <span className={styles.smallname}>{item.uniqueName}</span>
-          <span className={styles.edit}>
-            <input disabled={canEdit} type="text" 
-              className="canEdit" 
-              onDoubleClick={this.setEdit}
-              style={{color:style==2||style==4?'red':style==1?'#D949FF':'#333'}}
-              placeholder='(填写用法计量)'
-              autoComplete="off"
-              value={value}
-              title={value}
-              onInput={(e)=>{this.handleInput(e,item)}}
-              onBlur={()=>{this.handleBlur()}}
-              />
+          <span className={styles.pass}>
+            <input disabled="disabled" type="text" 
+                class="canEdit" 
+                onDoubleClick={(e)=>this.setEdit(e)}
+                style={{color:'#333'}}
+                placeholder='时间'
+                autoComplete="off"
+                value={item.time}
+                onInput={(e)=>{this.handleInput(e,item,1)}}
+                onBlur={()=>{this.handleBlur()}}
+                />
           </span>
-          <span className={styles.maxmin}>{normalVal(item.minValue,item.maxValue)}</span>
-          <span className={styles.pass}>检验时间:{item.time}</span>
           <span id="addClose" className={styles.partDel} onClick={()=>{this.handleDel(item.time)}}></span>
           <DelToast show={time==item.time&&activeInd?true:false}
                     name={activeName}

+ 2 - 1
src/components/AddNewInspect/index.jsx

@@ -137,14 +137,15 @@ class AddNewInspect extends React.Component {
     this.setState({ dateTime: date, date: false })
   }
   handleSearchAdvice(e) {
-    const {refreshScroller}=this.props
     let tmpShow = this.state.show;
+    const { handlePush } = this.props;
     this.setState({ show: !tmpShow, pageTop: getPageCoordinate(e).boxTop })
     // e.stopPropagation();
     if(tmpShow){
       this.props.setHighter(80)
     }else{
       this.props.detailClick(5)
+      handlePush && handlePush({mode:8});       //右侧推送
       setPosition(e,"#searchOption",this.props.setHighter)
     }
   }

+ 1 - 0
src/components/AddNewInspect/index.less

@@ -68,6 +68,7 @@
     } */
 }
 .labelWrap {
+    margin-bottom: 10px;
     .table {
         color: #000;
         width: 80%;

+ 2 - 1
src/components/AssistCheck/index.jsx

@@ -96,7 +96,7 @@ class AssistCheck extends React.Component {
     render(){
         const {setHighter,checkOnOff,checkedListImport,list,getInfomation,windowHeight,hospitalMsg,assistLabel,assistVal,
           handleChangeValue,handleSign,fetchPushInfos,handleDelAssist,handleChangeAssistValue,handleChangeDate,
-          isRead,winWidth,assistList,hideAllDrop} = this.props;
+          isRead,winWidth,assistList,hideAllDrop,setTipValue} = this.props;
         const {showSlideImport,checkSystemIpt,onClose,closeInIcss} = this;
         const {importLis,ieVersion,hide} = this.state;
         // if(JSON.stringify(hospitalMsg) != {} && document.getElementById("choose")){//动态绑定只绑定一次
@@ -148,6 +148,7 @@ class AssistCheck extends React.Component {
                 >
                     <div style={{padding:'10px',boxSizing:'border-box',color:'#000'}} >
                         <AddAssistCheck
+                            setTipValue={setTipValue}
                             checkOnOff={checkOnOff}
                             handleChangeValue={handleChangeValue}
                             refreshScroller={this.refreshScroller}

+ 10 - 12
src/components/BlockEmrCont/index.jsx

@@ -25,7 +25,8 @@ class BlockEMRCont extends Component {
   constructor(props){
     super(props);
     this.state = {
-      isShowSexInput : true
+      isShowSexInput : true,
+      historyId : -1
     }
     this.$cont = React.createRef();
     this.$div = React.createRef();
@@ -46,17 +47,14 @@ class BlockEMRCont extends Component {
     // });
   }
 
-  componentWillReceiveProps(nextProps) {
-    if (nextProps.patInfoData && nextProps.patInfoData.patInfoData[3].value === 1){
-      this.setState({
-        isShowSexInput : false
-      })
-    }else {
-      this.setState({
-        isShowSexInput: true
-      })
-    }
-  }
+  // componentWillReceiveProps(nextProps) {
+  //   console.log(nextProps,'nextProps');
+  //   if (nextProps.historyId !== this.state.historyId){
+  //     this.setState({
+  //       historyId : nextProps.historyId
+  //     })
+  //   }
+  // }
 
   setHighter(ht){
     // console.log(ht, '-=-=-ht=-------');

+ 2 - 2
src/components/BlockEmrCont/index.less

@@ -14,11 +14,11 @@
   // min-width: 700px;
   // min-width: 548px;
   width: 1200px;
-  padding-bottom: 80px;
+  padding-bottom: 48px;
 }
 .inner{
   padding-top:20px;
-  padding-bottom: 80px;
+  padding-bottom: 48px;
 }
 .keep {
   position: absolute;

+ 2 - 1
src/components/BodyContainer/index.jsx

@@ -6,9 +6,10 @@ import PushContainer from '../PushContainer';
 import style from './index.less';
 
 const BodyContainer = (props) =>{
+  console.log(props,'===');
   const { saveDateAll,mode } = props;
   return <div className={style['container'] + ' clearfix'}>
-      <BlockEMRCont/>
+      <BlockEMRCont />
       {/* <PushContainer></PushContainer> */}
   </div>;
 }

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

@@ -45,7 +45,7 @@ class DiagResultSearch extends Component {
     // console.log(searchResult,'searchResult');
     // console.log(isShowNoDataInfo,'isShowNoDataInfo');
     if (isShowNoDataInfo === true && searchResult.length === 0 ){
-      return <div className={style['search-result-noItem']}>暂无筛选项</div>
+      return <div className={style['search-result-noItem']}><span>暂无筛选项</span></div>
     }
     return <div className={style['search-result']} style={{'min-height':'120px',width:'412px',overflow:'auto'}}>
       {

+ 9 - 3
src/components/DiagResultSearch/index.less

@@ -58,9 +58,15 @@
 }
 
 .search-result-noItem{
-    position: relative;
+   span{
+        // position: relative;
     color: #bfbfbf;
-    top: 8px;
-    left: 27px;
+    margin-top: -8px;
+    margin-left: 30px;
+    // top: 8px;
+    // left: 27px;
     height: 50px;
+    display: inline-block;
+    line-height: 50px;
+   }
 }

+ 1 - 7
src/components/Diagnosis/index.jsx

@@ -3,7 +3,6 @@ import { Button, ItemBox, ConfirmModal, Loading, Message, Add } from '@commonCom
 import DiagnosticList from '@containers/DiagnosticList.js';
 import { getPageCoordinate,setPosition  } from '@utils/tools';
 import DiagResultSearch from '@containers/DiagResultSearch';
-import $ from 'jquery';
 
 class Diagnosis extends Component {
   constructor(props) {
@@ -40,15 +39,13 @@ class Diagnosis extends Component {
     if(this.props.show){
       this.props.setHighter(48)
     }else{
+      this.props.getBilling({mode:10});
       setPosition(e,"#searchOption",this.props.setHighter)
     }
   }
   refreshScroller(){
     //更新滚动条状态,解决容器变大滚动条不更新bug
     return this.context.scrollArea;
-    /*this.context.scrollArea.refresh();
-    this.context.scrollArea.scrollBottom();*/
-
   }
   render() {
     return (<div id="diagnosisResult">
@@ -64,10 +61,7 @@ class Diagnosis extends Component {
             height={150}>
           </DiagResultSearch>
         </div>
-
-
       </ItemBox>
-      {/* <TreatDrug></TreatDrug> */}
       <Message></Message>
     </div>)
   }

+ 45 - 23
src/components/HistoryCaseContainer/HistoryList/index.jsx

@@ -7,6 +7,7 @@ import sort from "./img/sort.png"
 import close from "./img/close.png";
 import PreviewBody from '@components/PreviewBody';
 import Empty from '@components/Empty'
+
 import { pushAllDataList,didPushParamChange } from '@utils/tools';
 // import { dragBox } from '@utils/drag';
 import { initItemList, setInitHistory } from '@store/async-actions/historyTemplates';
@@ -42,7 +43,8 @@ class HistoryCaseContainer extends React.Component {
           activeIndex: -1,  //字体显示蓝色高亮index
           showEditIcon: false,
           showDelIcon: false,
-          desc: true // 正序/逆序
+          desc: true, // 正序/逆序
+          overHeight: 0
         }
         this.handleCaseClick=this.handleCaseClick.bind(this)
         this.handleQuoteClick=this.handleQuoteClick.bind(this)
@@ -103,20 +105,27 @@ class HistoryCaseContainer extends React.Component {
         activeId: idx,
         activeHis: tmpItems,
         dataStr: JSON.parse(tmpItems.preview)||[],
-        activeIndex: idx
-      })
+        activeIndex: idx,
+        // overHeight: this.$scrollRef.current.scrollTop
+      },
+        // ()=> {
+        // setTimeout(() => {
+        //   this.$scrollRef.current.scrollTop = this.state.overHeight
+        // }, 0)}
+      )
+
+     
     }
     // 确认引用选中病历
     makeSure(){
         const {activeHis} = this.state;
         this.setState({visible:false});
         store.dispatch(showHistory(false));
-        //store.dispatch({type: CONFIRM_TYPE, confirmType: activeHis.sign});
-        //store.dispatch({type: SET_READ_MODE, readMode: activeHis.sign});
         store.dispatch(getHistempDetail(activeHis));  // 获取引用数据
         const {handleQuoteClick} = this.props;
-        handleQuoteClick&&handleQuoteClick();
-        // dragBox('hisWrapMove','closeHis','del');
+        handleQuoteClick && handleQuoteClick(activeHis);
+        // 确定引用后,页面设置为可滚动
+        document.body.style.overflow = 'auto';
     }
     //确认删除病历
     makeSureDel(){
@@ -141,9 +150,9 @@ class HistoryCaseContainer extends React.Component {
               this.handleCaseClick(0, items[0])
               // this.$scrollRef.scrollArea.refresh();
               // this.context.scrollArea.scrollYTo(40);
-              console.log(this.$scrollRef,'this.$scrollRef');
-              console.log(this.context,'this.context');
-              this.forceUpdate()
+              // console.log(this.$scrollRef,'this.$scrollRef');
+              // console.log(this.context,'this.context');
+              // this.forceUpdate()
             }
           })
         }
@@ -215,14 +224,14 @@ class HistoryCaseContainer extends React.Component {
 
     // 引用,右侧文本数据同步渲染
     handleQuoteClick(e,val,idx){
+      e.stopPropagation()
       this.setState({
         visible:true,
         activeId:idx,
-        activeHis:val,
-        // dataStr: val.preview||{},
-        // dataJson:JSON.parse(val.dataJson)||{},
-        dataStr: JSON.parse(val.preview) || [],
+        // activeHis:val,
+        // dataStr: JSON.parse(val.preview) || [],
       })
+      document.body.scrollTop = document.documentElement.scrollTop = 0
     }
     // 修改模板名称 input的值
     handleChange(e){
@@ -249,7 +258,6 @@ class HistoryCaseContainer extends React.Component {
 
       // 处理鼠标移入编辑按钮
     handleMouseEnterEdit(idx) {
-
         this.setState({
           showEditIcon: true
         })
@@ -257,7 +265,6 @@ class HistoryCaseContainer extends React.Component {
 
       // 处理鼠标移出编辑按钮
     handleMouseLeaveEdit(idx) {
-
       this.setState({
         showEditIcon: false
       })
@@ -265,7 +272,6 @@ class HistoryCaseContainer extends React.Component {
 
   // 处理鼠标移入删除按钮
   handleMouseEnterDel(idx) {
-
     this.setState({
       showDelIcon: true
     })
@@ -300,12 +306,7 @@ class HistoryCaseContainer extends React.Component {
     })
   }
 
-  componentDidUpdate() {  // 刷新组件
-    // console.log(this.$scrollRef.current.scrollTop);
-    // console.log(this.$scrollRef);
-    // this.$scrollRef.current.scrollTop = this.$scrollRef.current.scrollHeight;
 
-  }
 
     render(){
         const { items,handleSortClick,showHistoryBox,preInfo } = this.props;
@@ -348,7 +349,27 @@ class HistoryCaseContainer extends React.Component {
                         <span className={styles.sort} onClick={this.handleSortClick}>排序 <img src={sort} alt="排序"/></span>
                     </div>
                     <div className={styles.lists}>
-                        <ul id="hislistLeft" style={{ overflow:'auto' }} >
+                      {/* <List
+                        items = {items}
+                        handleCaseClick = {this.handleCaseClick}
+                        currentIndex ={ currentIndex}
+                        showEditIcon = {this.state.showEditIcon}
+                        activeIndex={activeIndex}
+                        showDelIcon={this.state.showDelIcon}
+                      ></List> */}
+
+                      <ScrollArea speed={0.8}
+                        key={items.length}
+                        // ref={this.$scrollRef}
+                        horizontal={false}
+                        // stopScrollPropagation={items.length > 6 ? true : false}
+                        style={{ height: '100%' }}
+                        onScroll={(value) => { }}
+                        className={styles["area"]}
+                        verticalContainerStyle={contStyle}
+                        verticalScrollbarStyle={barStyle}
+                        contentClassName="content">
+                        <ul id="hislistLeft" style={{ overflow:'auto' }}  ref={this.$scrollRef}>
                             {(items && items.length > 0) ? items.map((val,idx)=>{                                    
                               return <li key={val.id} onClick={() => { this.handleCaseClick(idx, val) }} onMouseEnter={() => this.handleMouseEnterLi(idx)} onMouseLeave={() => this.handleMouseLeaveLi(idx)}>
                                          <div className={styles.itemLeft}>
@@ -376,6 +397,7 @@ class HistoryCaseContainer extends React.Component {
                                 }):<Empty message={'无历史病历'}></Empty>
                             }
                         </ul>
+                      </ScrollArea>
                     </div>
                 </div>
                 <div className={styles.mainHistoryRight}>

+ 5 - 2
src/components/InfoTitle/index.jsx

@@ -21,10 +21,13 @@ class InfoTitle extends Component {
         this.showHistoryBox = this.showHistoryBox.bind(this)
     }
     showHistoryBox(){
+
+        console.log('关闭');
         const {showLoading,hideLoading}=this.props;
         showLoading();
-        // document.body.style.overflow = 'hidden';
-        // document.body.style.position = 'fixed';
+        // 底部页面禁止滚动
+        document.body.style.overflow = 'hidden';
+
         // store.dispatch(initItemList());
         // store.dispatch(showHistory(true))
         // initItemList().then((res)=>{

+ 7 - 0
src/components/PatInfo/Select/index.jsx

@@ -4,6 +4,7 @@ import style from "./../index.less";
 import selectSex from '../../../common/images/selectSex.png'
 import { CLEARMENSTRUATIONTEXTDATA, } from '@store/types/menstruationHistory';
 import store from '@store';
+import { embedPush } from '../../../store/async-actions/pushMessage'
 export default class Select extends Component {
   constructor(props) {
     super(props);
@@ -70,6 +71,7 @@ export default class Select extends Component {
   };
 
   onChange(e,val) {
+    const state = store.getState();
     e.stopPropagation()
     this.setState({
       value: val,
@@ -79,6 +81,11 @@ export default class Select extends Component {
     store.dispatch({
       type: CLEARMENSTRUATIONTEXTDATA,
     });
+
+    store.dispatch(embedPush({
+      action: "patientia",
+      mode: 1
+    }))
   };
   handleMouseEnter(){
     // console.log('鼠标进入');

+ 8 - 8
src/components/PatInfo/index.less

@@ -142,13 +142,13 @@
       left: 38px;
       cursor: pointer;
       img{
-        width: 16px;
-        height: 10px;
+        width: 12px;
+        height: 8px;
         position: absolute;
         top: 50%;
         left: 50%;
-        margin-left: -8px;
-        margin-top: -5px;
+        margin-left: -6px;
+        margin-top: -4px;
         // width: 50%;
         // margin-bottom: 3px;
       }
@@ -164,13 +164,13 @@
       left: 38px;
       cursor: pointer;
       img{
-        width: 16px;
-        height: 10px;
+        width: 12px;
+        height: 8px;
         position: absolute;
         top: 50%;
         left: 50%;
-        margin-left: -8px;
-        margin-top: -5px;
+        margin-left: -6px;
+        margin-top: -4px;
         // width: 50%;
         // margin-bottom: 3px;
       }

+ 1 - 1
src/components/PreviewBody/MedicalAdvice/index.jsx

@@ -7,7 +7,7 @@ class MedicalAdvice extends Component {
   }
   render() { 
     const {advice} = this.props
-    console.log(advice,'===========');
+    // console.log(advice,'===========');
     const {labelListBig,labelListSmall} = advice
     return ( 
         <tr className={style['patInfoFst']}>

+ 20 - 1
src/components/PreviewBody/index.jsx

@@ -9,7 +9,7 @@ import ItemPart from './ItemPart';
 import $ from "jquery";
 import AssessResultHis from '@containers/AssessResultHis';
 import { dragBox } from '@utils/drag';
-
+import ScrollArea from 'react-scrollbar';
 class PreviewBody extends Component {
   constructor(props) {
     super(props)
@@ -85,6 +85,15 @@ class PreviewBody extends Component {
     const { show, preInfo, dataJson, dataStr, baseObj, flg ,come,showAssessBtn,showHistoryCases} = this.props;
     let other_data={},lis_data={},pas_data={},other_yjs='',access='',adviceData={};
     let isShowSex = baseObj.sex !== 2 ? false : true
+    const contStyle = {
+      opacity: '0.4',
+      right: '0',
+      top: '1px',
+      zIndex: '15',
+      width: '14px',
+      background: '#f1f1f1'
+    };
+    const barStyle = { background: '#777', width: '100%' };
     // if(!come){
     //   other_data = JSON.parse(baseObj.detailList[2].contentJson)
     //   lis_data = JSON.parse(baseObj.detailList[4].contentJson)
@@ -99,6 +108,15 @@ class PreviewBody extends Component {
     // }
     // const noData = JSON.stringify(preInfo) == '{}';
     return <div className={style['content']} style={{ width: '700px'}} ref={this.$scrollRef}>
+      <ScrollArea speed={0.8}
+        horizontal={false}
+        // stopScrollPropagation={items.length > 6 ? true : false}
+        style={{ height: '100%' }}
+        onScroll={(value) => { }}
+        // className={styles["area"]}
+        verticalContainerStyle={contStyle}
+        verticalScrollbarStyle={barStyle}
+        contentClassName="content">
       <div className={style['contents']} id="content" style={{ margin: "0 auto", maxWidth: "620px" }}>
         {/* <div style={{height:'40px', backgroundColor: 'red', width:'100%'}}></div> */}
         <Information baseObj={baseObj} preInfo={preInfo}></Information>
@@ -123,6 +141,7 @@ class PreviewBody extends Component {
           display: show ? 'inline-block' : 'none',
         }}>打印</div>
       </div>
+      </ScrollArea>
     </div>
   }
 }

+ 0 - 1
src/components/PushData/index.jsx

@@ -38,7 +38,6 @@ class PushData extends Component{
     render(){
         const {hashNum } = this.state
         const {mrId,planCode,showPushData,togglePushData ,windowWidth,windowHeight,hospitalId} = this.props
-        console.log(windowWidth,windowHeight)
         const url =`${pushPage2}?mrId=${mrId}&planCode=${planCode}&hospitalId=${hospitalId}`;
         return <div >
             {!showPushData&&<div className={style['slideButton']} style={{right:(windowWidth-1200)/2+'px'}} onClick={this.showPushData}> 

+ 4 - 1
src/containers/AssistCheck.js

@@ -3,7 +3,7 @@ import {
     connect
 } from 'react-redux';
 import AssistCheck from '@components/AssistCheck';
-import { assistLable,delAssistLabel,changeAssistVal,changeDate,allCheckImports,selectOneChecks,showInIcsss,checkOffOn } from '@store/actions/assistCheck';
+import { assistLable,delAssistLabel,changeAssistVal,changeDate,allCheckImports,selectOneChecks,showInIcsss,checkOffOn,setTipVal } from '@store/actions/assistCheck';
 import { getSearchList,getInstroduce ,getImportLists,getSonDetailList} from '@store/async-actions/assistCheck';
 import {ISREAD,HIDEDROP} from '@store/types/homePage.js';
 import {embedPush, getConceptDetail,getMRAnalyse} from '@store/async-actions/pushMessage';
@@ -34,6 +34,9 @@ function mapStateToProps(state) {//console.log(state.typeConfig)
 
 function mapDispatchToProps(dispatch, store) {
     return {
+        setTipValue(item,val,idx){
+          dispatch(setTipVal(item,val,idx))
+        },
         checkOnOff(item){
           dispatch(checkOffOn(item))
         },

+ 1 - 1
src/containers/BlockEMRContanier.js

@@ -5,7 +5,7 @@ import BlockEMRCont from '../components/BlockEmrCont/index.jsx';
 
 function mapStateToProps(state) {
   return {
-    patInfoData: state.patInfo
+    historyId: state.historyTemplates.historyId
   };
 }
 function mapDispatchToProps(dispatch) {

+ 5 - 0
src/containers/Diagnosis.js

@@ -3,6 +3,7 @@ import { connect } from 'react-redux';
 import Diagnosis from '@components/Diagnosis';
 import { SHOW_SEARCH,  HIDE_SEARCH } from '@store/types/diagnosticSearch';
 import {HIDEDROP} from '@types/homePage';
+import {embedPush} from '@store/async-actions/pushMessage';
 
 function mapStateToProps(state) {//console.log(state)
     return {
@@ -29,6 +30,10 @@ function mapDispatchToProps(dispatch) {
             type:HIDEDROP
           });
         },
+        getBilling: (obj) => {
+            obj.action ='diag'
+            dispatch(embedPush(obj))
+        },
     }
 }
 

+ 5 - 2
src/containers/HistoryCases.js

@@ -1,7 +1,7 @@
 import React from 'react';
 import { connect } from 'react-redux';
 import HistoryCaseContainer from '@components/HistoryCaseContainer';
-import { showHistory,sortHistory,activeHistory,visibleHistory } from '@store/actions/historyTemplates'
+import { showHistory,sortHistory,activeHistory,visibleHistory,saveHistoryId } from '@store/actions/historyTemplates'
 import {keepPushData} from '@store/actions/tabTemplate';
 import { dragBox } from '@utils/drag';
 
@@ -22,16 +22,19 @@ function mapDispatchToProps(dispatch) {
         showHistoryBox(){
             dragBox('hisWrapMove','closeHis','del')
             dispatch(showHistory(false))
+            // 取消历史模态框后,页面设置为可滚动
+            document.body.style.overflow = 'auto';
         },
         handleCaseClick(e,val){
             e.stopPropagation();
             dispatch(activeHistory(val))
         },
-        handleQuoteClick(e,data,idx){
+        handleQuoteClick(data,idx){
             // e.stopPropagation();
             dispatch(keepPushData(data,'his'))      //历史病历引用
             dispatch(activeHistory(idx))
             dispatch(visibleHistory(true))
+            dispatch(saveHistoryId(data.id));
         },
         handleSortClick(){
             dispatch(sortHistory())

+ 3 - 3
src/containers/Inspect.js

@@ -16,7 +16,7 @@ import {
   clearLabel,
   delPartItem,
   setContext,
-  setTip,
+  setTips,
   searchType,
   resetLabel,
   delOnePic,
@@ -99,8 +99,8 @@ function mapDispatchToProps(dispatch) {
       dispatch(delPartItem(idx))
       dispatch(getMRAnalyse())
     },
-    setTipValue(item,value) {
-      dispatch(setTip(item,value))
+    setTipValue(item,value,type) {
+      dispatch(setTips(item,value,type))
     },
     //右侧推送
     fetchPushInfos(obj) {

+ 2 - 2
src/containers/NewAdvice.js

@@ -99,8 +99,8 @@ function mapDispatchToProps(dispatch) {
       dispatch(delPartItem(idx))
       dispatch(getMRAnalyse())
     },
-    setTipValue(item,value) {
-      dispatch(setTip(item,value))
+    setTipValue(item,value,sign) {
+      dispatch(setTip(item,value,sign))
     },
     //右侧推送
     fetchPushInfos(obj) {

+ 7 - 1
src/store/actions/assistCheck.js

@@ -1,4 +1,4 @@
-import {GET_ASSIST_SEARCH_LIST,GET_ASSIST_LABEL,CHECK_OFF_ON,DEL_ASSIST_LABEL,CHANGE_ASSIST_VAL,CHANGE_DATE,CLEAR_ASSIST_DATA,ADD_ASSIST_LABEL} from '../types/assistCheck';
+import {SET_TIP_VAL,GET_ASSIST_SEARCH_LIST,GET_ASSIST_LABEL,CHECK_OFF_ON,DEL_ASSIST_LABEL,CHANGE_ASSIST_VAL,CHANGE_DATE,CLEAR_ASSIST_DATA,ADD_ASSIST_LABEL} from '../types/assistCheck';
 
 export const searchList = (list,val) => ({         //搜索列表渲染
     type:GET_ASSIST_SEARCH_LIST,
@@ -34,6 +34,12 @@ export const checkOffOn = (item) => ({
     type:CHECK_OFF_ON,
     item
 })
+export const setTipVal = (item,val,idx) => ({
+    type:SET_TIP_VAL,
+    item,
+    val,
+    idx
+})
 export const clearAssistData = (data,saveText,checkedListImport) => ({         //清空回读
     type:CLEAR_ASSIST_DATA,
     data,

+ 5 - 1
src/store/actions/historyTemplates.js

@@ -1,4 +1,4 @@
-import { HISTORY_TEMPLATES, HISTORY_TEMPLATES_SORT, HISTORY_INIT, HISTORY_ACTIVE, HISTORY_VISIBLE, HISTORY_UPDATEBYIDUSNAMES, HISTORY_GETHOSPITALINFO } from '@store/types/historyTemplates';
+import {HISTORYID, HISTORY_TEMPLATES, HISTORY_TEMPLATES_SORT, HISTORY_INIT, HISTORY_ACTIVE, HISTORY_VISIBLE, HISTORY_UPDATEBYIDUSNAMES, HISTORY_GETHOSPITALINFO } from '@store/types/historyTemplates';
 
 export const showHistory=(bool) => ({   //显示隐藏历史病历
     type:HISTORY_TEMPLATES,
@@ -23,6 +23,10 @@ export const visibleHistory=(bool) => ({   //历史病历弹窗
 export const updateByIdUsNamesHistory = () => ({   //修改病历名称
     type: HISTORY_UPDATEBYIDUSNAMES,
 });
+export const saveHistoryId = (id) => ({   //修改病历名称
+    type: HISTORYID,
+    id
+});
 
 
 // export const getInitHospitalInfo = (val) => ({   //获取医院信息

+ 5 - 4
src/store/actions/inspect.js

@@ -1,4 +1,4 @@
-import {SET_CONTEXT,CHECK_ON_OFF,DEL_ONE_PIC,ADD_LABEL,SEARCH_LIST,SET_LABEL,SET_TIP,FILL_ACTIVE,FILL_ACTIVE_DETAIL,GET_EXCEL,CHECK_VALUE_IS_CHANGE,CLEAR_LABEL,RESET_LABEL,CLEAR_ALL_LABEL,DEL_PART_ITEM,DEL_EXCEL_LIST,SEARCH_TYPE} from '../types/inspect';
+import {SET_CONTEXT,CHECK_ON_OFF,DEL_ONE_PIC,ADD_LABEL,SEARCH_LIST,SET_LABEL,SET_TIP_NEW,FILL_ACTIVE,FILL_ACTIVE_DETAIL,GET_EXCEL,CHECK_VALUE_IS_CHANGE,CLEAR_LABEL,RESET_LABEL,CLEAR_ALL_LABEL,DEL_PART_ITEM,DEL_EXCEL_LIST,SEARCH_TYPE} from '../types/inspect';
 
 export const setLabel = (idx,sign) => ({          //搜索后点击选中的结果
     type:SET_LABEL,
@@ -63,10 +63,11 @@ export const setContext = (obj) => ({
     type:SET_CONTEXT,
     obj
 })
-export const setTip = (item,value) => ({
-    type:SET_TIP,
+export const setTips = (item,value,sign) => ({
+    type:SET_TIP_NEW,
     item,
-    value
+    value,
+    sign
 })
 export const searchType = (value) => ({
     type:SEARCH_TYPE,

+ 3 - 2
src/store/actions/newAdvice.js

@@ -63,10 +63,11 @@ export const setContext = (obj) => ({
     type:SET_CONTEXT,
     obj
 })
-export const setTip = (item,value) => ({
+export const setTip = (item,value,sign) => ({
     type:SET_TIP,
     item,
-    value
+    value,
+    sign
 })
 export const searchTypeNew = (value) => ({
     type:SEARCH_TYPE_NEW,

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

@@ -43,7 +43,7 @@ export const getHistempDetail = (item) => {
                 //   dispatch(billing());
                 // }
                 // dispatch(getMRAnalyse())
-
+                
                 
             }else{
                 Notify.error(data.msg);

+ 4 - 1
src/store/async-actions/inspect.js

@@ -24,12 +24,15 @@ export const getSearchList = (val) => {
                 const data = res.data.data;let curDate=[];
                 if(type==2){
                     curDate = data && data.lisDetailNames
+                    for (let i = 0;i < curDate.length;i++) {
+                        curDate[i]['detailName'] = curDate[i]['uniqueName']
+                        curDate[i]['flg'] = 0;
+                    }
                 }else{
                     let arr = data.lisNames,tmp=[];
                     for (var key in arr) {
                         let obj = {}
                         obj['uniqueName'] = arr[key];
-                        obj['detailName'] = arr[key];
                         obj['value'] = '';
                         obj['otherValue']='';
                         obj['name'] = arr[key];

+ 17 - 0
src/store/reducers/assistCheck.js

@@ -9,6 +9,7 @@ import {
   CHECK_OFF_ON,
   REASSISTCHECKDATA,
   CLEARASSISTCHECKDATA,
+  SET_TIP_VAL,
 } from '../types/assistCheck';
 import store from '@store';
 const initSearchList = {
@@ -34,6 +35,21 @@ const initSearchList = {
 import { getCurrentDate,getAllString} from '@utils/tools';
 
 export default (state = initSearchList, action) => {
+  if (action.type == SET_TIP_VAL) { //改变shijian
+    const newState = Object.assign({}, state);
+    const tempArr = newState.assistLabel;
+    for (let i = 0; i < tempArr.length; i++) {
+      if (i == action.idx) {
+        tempArr[i].dateValue = action.val
+        tempArr[i].time = action.val
+        newState.assistLabel = [...tempArr]
+      }
+    }
+    let tmpObj = getAllString(newState.checkedListImport,newState.assistLabel)
+    newState.dataArr = tmpObj.arr
+    newState.dataString = tmpObj.str
+    return newState;
+  }
   if (action.type == ADD_ASSIST_LABEL) {
     const newState = Object.assign({}, state);
     let tempArr = newState.assistLabel;
@@ -163,6 +179,7 @@ export default (state = initSearchList, action) => {
     newState.assistLabel = [];
     newState.dataArr = [];
     newState.dataString = [];
+    newState.totalOrder = [];
     return newState;
   }
   return state;

+ 9 - 1
src/store/reducers/historyTemplates.js

@@ -5,7 +5,8 @@ import {
     HISTORY_ACTIVE,
     HISTORY_VISIBLE,
     HISTORY_UPDATEBYIDUSNAMES,
-    HISTORY_GETHOSPITALINFO
+    HISTORY_GETHOSPITALINFO,
+    HISTORYID
 } from '../types/historyTemplates';
 
 
@@ -15,6 +16,7 @@ const initHistoryList = {
     activeHistory:{},//需要显示的病例
     items: [],
     HospitalInfo: {}, // 医院信息
+    historyId: -1, // 病历id
 }
 
 export default (state = initHistoryList, action) => {
@@ -58,5 +60,11 @@ export default (state = initHistoryList, action) => {
         newState.HospitalInfo = action.data
         return newState;
     }
+     if (action.type === HISTORYID) {
+       const newState = Object.assign({}, state);
+       newState.historyId = action.id;
+       return newState;
+     }
+
     return state;
 }

+ 16 - 65
src/store/reducers/inspect.js

@@ -11,7 +11,7 @@ import {
   DEL_EXCEL_LIST,
   ADD_LABEL,
   SET_CONTEXT,
-  SET_TIP,
+  SET_TIP_NEW,
   SEARCH_TYPE,
   DEL_ONE_PIC,
   CHECK_ON_OFF,
@@ -89,21 +89,30 @@ export default (state = initSearchList, action) => {
         return newState;
     }
 
-    if (action.type == SET_TIP) {    
+    if (action.type == SET_TIP_NEW) {
         const newState = Object.assign({}, state);
         let tempArr = newState.labelListBig;
         let tempArrs = newState.labelListSmall;
         let tmpLis = action.item
+        tempArr = tempArr.filter((item)=>{
+            item.time = action.value
+            return item
+        })
         tempArrs = tempArrs.filter((item)=>{
             if(item.time == tmpLis.time){
-                if(isNumber(action.value-0)){
-                    item.value = action.value
+                if(action.sign ==1){
+                    item.time = action.value
                 }else{
-                    item.otherValue = action.value
+                    if(isNumber(action.value-0)){
+                        item.value = action.value
+                    }else{
+                        item.otherValue = action.value
+                    }
                 }
             }
             return item
         })
+        newState.labelListBig = [...tempArr]
         newState.labelListSmall = [...tempArrs]
         return newState;
     }
@@ -268,6 +277,7 @@ export default (state = initSearchList, action) => {
       const newState = Object.assign({}, state);
         newState.labelListBig = action.params[8].content.labelListBig
         newState.labelListSmall = action.params[8].content.labelListSmall;       
+        newState.totalOrder = action.params[8].content.totalOrder;       
       return newState;
 
     }
@@ -275,71 +285,12 @@ export default (state = initSearchList, action) => {
       let newState = Object.assign({}, state);
       newState.labelListBig = [];
       newState.labelListSmall = [];
+      newState.totalOrder = [];
       return newState;
     }
     return state;
 }
 
-function getExcelString(action,newState,tmpArr,tmpArr2) {
-  let tmpString = '';
-  if(JSON.stringify(action.data||{}) != '{}' && action.data.lisExcelRes.length > 0){
-    action.data.lisExcelRes.map((item)=>{
-        item.lisExcelItem.map((part)=>{
-            if(part.type == 1){
-                if(part.max != '' && (part.value-0) > (part.max-0) ) {
-                    let rate = (part.value/part.max).toFixed(2);
-                    let tmpStr = part.mealName+','+part.itemName+','+part.value+' '+part.unit+'升高'+rate+';'
-                    tmpString += tmpStr;
-                }else if(part.min != '' && (part.value-0) < (part.min-0) ){
-                    let rate = (part.value/part.min).toFixed(2);
-                    let tmpStr = part.mealName+','+part.itemName+','+part.value+' '+part.unit+'降低'+rate+';'
-                    tmpString += tmpStr;
-                }else{
-                    let tmpStr = part.mealName+','+part.itemName+','+part.value+' '+part.unit+'异常;'
-                    tmpString += tmpStr;
-                }
-            }else{
-                let tmpStr = part.mealName+','+part.itemName+','+part.value+' '+part.unit+'正常;'
-                tmpString += tmpStr;
-            }
-        })
-    })
-    newState.pushItem = getPushList(tmpArr,tmpArr2);
-    newState.pushItems = getPushLists(tmpArr,tmpArr2);
-    newState.inspectStrPlus = getStringPlus(newState.pushItems)
-  }else{
-    newState.inspectStrPlus = '';
-    newState.pushItem = []
-  }
-}
-function getString(lists) {
-    let tmpString = '';
-    lists.map((item)=>{
-        if(item.show == true){
-            item.details.map((part)=>{
-                if(part.value){
-                    if(typeof(part.value) == "number"){
-                        if(part.maxValue != '' && (part.value-0) > (part.maxValue-0) ) {
-                            let rate = (part.value/part.maxValue).toFixed(2);
-                            let tmpStr = item.name+','+part.name+','+part.value+' '+part.labelSuffix+'升高'+rate+';'
-                            tmpString += tmpStr;
-                        }else if(part.minValue != '' && (part.value-0) < (part.minValue-0) ){
-                            let rate = (part.value/part.minValue).toFixed(2);
-                            let tmpStr = item.name+','+part.name+','+part.value+' '+part.labelSuffix+'降低'+rate+';'
-                            tmpString += tmpStr;
-                        }else{
-                            let tmpStr = item.name+','+part.name+','+part.value+' '+part.labelSuffix+';'
-                            tmpString += tmpStr;
-                        }
-                    }else{
-                        tmpString += item.name+','+part.name+','+part.value+' '+part.labelSuffix+';'
-                    }
-                }
-            })
-        }
-    })
-    return tmpString;
-}
 function isNumber(obj) {  
     return typeof obj === 'number' && !isNaN(obj)  
 }

+ 21 - 5
src/store/reducers/newAdvice.js

@@ -68,7 +68,6 @@ export default (state = initSearchList, action) => {
         tempBigOrder = tempArr.filter((item)=>item.check)
         tempSmallOrder = tempArrs.filter((item)=>item.check)
         newState.drugOrder=[...tempBigOrder]
-        console.log(newState.drugOrder,77777,tempBigOrder,1111)
         newState.operationOrder=[...tempSmallOrder]
         return newState;
     }
@@ -94,14 +93,29 @@ export default (state = initSearchList, action) => {
     if (action.type == SET_TIP) {    
         const newState = Object.assign({}, state);
         let tempArr = newState.labelListBig;
+        let tempArrs = newState.labelListSmall;
         let tmpLis = action.item
-
-        for(let i= 0;i < tempArr.length;i++){
-            if(tmpLis.time == tempArr[i].time){
-                tempArr[i].value = action.value
+        if(tmpLis.flg == 5){
+            for(let i= 0;i < tempArr.length;i++){
+                if(tmpLis.time == tempArr[i].time){
+                    if(action.sign == 1){
+                        tempArr[i].time = action.value
+                        tempArr[i].dateValue = action.value
+                    }else{
+                        tempArr[i].value = action.value
+                    }
+                }
+            }
+        }else{
+            for(let i= 0;i < tempArrs.length;i++){
+                if(tmpLis.time == tempArrs[i].time){
+                    tempArrs[i].time = action.value
+                    tempArrs[i].dateValue = action.value
+                }
             }
         }
         newState.labelListBig = [...tempArr]
+        newState.labelListSmall = [...tempArrs]
         return newState;
     }
     if (action.type == SEARCH_TYPE_NEW) {
@@ -271,6 +285,8 @@ export default (state = initSearchList, action) => {
     const newState = Object.assign({}, state);
     newState.labelListBig = [];
     newState.labelListSmall = [];
+    newState.drugOrder = [];
+    newState.operationOrder = [];
     return newState;
     }
     return state;

+ 1 - 0
src/store/types/assistCheck.js

@@ -6,6 +6,7 @@ export const CHANGE_DATE = 'CHANGE_DATE';
 export const CLEAR_ASSIST_DATA = 'CLEAR_ASSIST_DATA';
 export const ADD_ASSIST_LABEL = 'ADD_ASSIST_LABEL';
 export const CHECK_OFF_ON = 'CHECK_OFF_ON';
+export const SET_TIP_VAL = 'SET_TIP_VAL';
 
 
 export const REASSISTCHECKDATA = 'REASSISTCHECKDATA';

+ 1 - 0
src/store/types/historyTemplates.js

@@ -7,3 +7,4 @@ export const HISTORY_VISIBLE = 'HISTORY_VISIBLE';
 
 export const HISTORY_UPDATEBYIDUSNAMES = 'HISTORY_UPDATEBYIDUSNAMES';  //修改病历名称
 export const HISTORY_GETHOSPITALINFO = 'HISTORY_GETHOSPITALINFO';  //获取医院信息
+export const HISTORYID = 'HISTORYID';  //病历ID

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

@@ -12,7 +12,7 @@ export const DEL_PART_ITEM = 'DEL_PART_ITEM';
 export const DEL_EXCEL_LIST = 'DEL_EXCEL_LIST';
 export const ADD_LABEL = 'ADD_LABEL';
 export const SET_CONTEXT = 'SET_CONTEXT';
-export const SET_TIP = 'SET_TIP';
+export const SET_TIP_NEW = 'SET_TIP_NEW';
 export const SEARCH_TYPE = 'SEARCH_TYPE';
 export const DEL_ONE_PIC = 'DEL_ONE_PIC';
 export const CHECK_ON_OFF = 'CHECK_ON_OFF';

+ 1 - 3
src/utils/ajax.js

@@ -9,10 +9,8 @@ const orgin = window.location.origin;
 // const qhost = isLocal?host+prefix:prefix;
 const qhost = isLocal ? host  :'';
 axios.defaults.headers.post['Content-Type'] = 'application/x-www-form-urlencoded';
-//axios.defaults.baseURL = host;       //默认地址
+//axios.defaults.baseURL = host;         //默认地址
 // axios.defaults.timeout = 60000;       //请求超时
-
-
     const securityCode = getUrlArgObject("code");
     const appKeyId = getUrlArgObject("appI");
     const appKeySecret = getUrlArgObject("appS");

+ 22 - 40
src/utils/tools.js

@@ -879,27 +879,8 @@ function handleEnter(event){
     event = event?event:window.event;
     if(event.keyCode==13){return false;}
 }
-//获取病例输入的内容
-// function getEMRParams(){
-//   const state = store.getState();
-//   const {message} = state.patInfo;
-//   const {mainSuit,currentIll,otherHistory,checkBody,inspect,assistCheck,diagnosticList} = state;
-//   //console.log('message', message)
-//   const main = filterDataArr(mainSuit.saveText)||'',
-//     current=filterDataArr(currentIll.saveText)||'',
-//     other = filterDataArr(otherHistory.saveText)||'',
-//     vital = filterDataArr(checkBody.saveText)||'',
-//     lis = inspect.pushItem,    //化验推送所需数据
-//     pacs = assistCheck.dataString||'',
-//     dis=diagnosticList.diagnosticStrNoType||'',
-//     advice = '',
-//     diseaeId = [];
-//   const age = message.patientAge;
-//   const sex = message.sex;
-//   const patientId = message.patientId //病人id,取上次用药
-//   const hosCode = message.hospitalCode
-//   return {main,current,other,vital,lis,pacs,dis,advice,diseaeId,sex,age, patientId, hosCode};
-// };
+
+
 // 获取参数value
 function formatFormParmas(val,arr){
     let item = arr.length!==0 && arr.find(item=>{
@@ -907,13 +888,12 @@ function formatFormParmas(val,arr){
     })
     return item.value
 }
-
+//获取病例输入的内容
 function getEMRParams(){
   const state = store.getState();
   const {id} =  state.historyTemplates && state.historyTemplates.HospitalInfo 
   const {message} = state.patInfo;
   const { patInfoData } = state.patInfo;
-  // console.log(state, 'state================');
   const {
     mainSuit,
     currentIll,
@@ -930,7 +910,6 @@ function getEMRParams(){
     newAdvice,
   } = state;
   const diag = [];
-  console.log(state,7777777)
   for(let i = 0; i < diagnosticList.diagnosticList.length; i++) {
     diag.push({"dateValue": "","name": "","uniqueName": diagnosticList.diagnosticList[i].name})
   }
@@ -942,10 +921,11 @@ function getEMRParams(){
   tempdrug = tempdrug.filter((item)=>!item.check)
   let tempoperation = newAdvice.labelListSmall
   tempoperation = tempoperation.filter((item)=>!item.check)
+  let sex = formatFormParmas('patientSex', patInfoData);
   const obj = {
     "hospitalId": id || '',
     "age": formatFormParmas('patientAge', patInfoData),
-    "sex": formatFormParmas('patientSex', patInfoData),
+    "sex": sex,
     "deptName": formatFormParmas('hospitalDeptName', patInfoData),
     "chief": filterDataArr(mainSuit.saveText)||'',    //主诉
     "symptom": filterDataArr(currentIll.saveText)||'',  //现病史
@@ -979,6 +959,11 @@ function getEMRParams(){
     "drug": tempdrug,
     "hospitalId": id || ''
   }
+  if(sex !== 2){
+    // 不是女性时,去除月经史
+    obj.menstrual = '';
+  }
+  
   return obj;
 };
 function getMRInfo() {
@@ -1845,16 +1830,19 @@ function setPosition (e,dom,setHighter){
     const $dom = isBlock?$("#EmrBlockContainer"):$("#EmrContainer");
     const wrapHt = $dom.height();//滚动区域高度
     const clickHt = getPageCoordinate(e).boxTop;//点击高度
-    const scrollHt = Math.abs(parseFloat($dom.parent('.scrollarea-content').css('margin-top'))) //滚动区滚动的距离
-    let btmHt = wrapHt-(clickHt-111)-scrollHt;//点击位置距离底部的距离
-    // console.log(wrapHt,clickHt,scrollHt,btmHt,contHt)
-    if(btmHt<contHt){
-      console.log(999)
-      setHighter&&setHighter(contHt-btmHt+100);
+    const scrollHt = Math.abs(parseFloat(document.documentElement.scrollTop || document.body.scrollTop)) //滚动的距离
+    let btmHt = $(window).height()-(clickHt-scrollHt);//点击位置距离底部的距离
+    // console.log('滚动区域高度:',wrapHt,' 点击高度:',clickHt,' 滚动区滚动的距离',scrollHt,'点击距离底部',btmHt,$(e.target).html())
+    if(btmHt<300){
+      if(btmHt<200&&$(e.target).html()=='添加检验项'){
+        setHighter&&setHighter(48);
+      }else{
+        setHighter&&setHighter(400-btmHt);
+      }
+      $(e.target)[0].scrollIntoView();
     }else{
-      setHighter&&setHighter(180);       //标签填写单连续点击弹出,未超出需要恢复
+      setHighter&&setHighter(48);       //标签填写单连续点击弹出,未超出需要恢复
     }
-    $(e.target)[0].scrollIntoView(true);
   },10);
 }
 
@@ -2068,13 +2056,7 @@ function checkDeptContent(jsonStr,tmpLis){
     }
   }
 }
-// 获取参数value
-function formatFormParmas(val,arr){
-  let item = arr.length!==0 && arr.find(item=>{
-     return item.id === val
-  })
-  return item.value
-}
+
 module.exports = {
   getIds,
   getWindowInnerWidth,