ソースを参照

Merge remote-tracking branch 'origin/testedMerge' into innterfaceUpdate

zhouna 5 年 前
コミット
7ee707a16e

+ 2 - 3
src/common/components/Loading/index.jsx

@@ -10,6 +10,7 @@ import React, {Component} from 'react';
 import style from './index.less';
  import wnIcon from '@common/images/wn.png';
 import icon from '@common/images/loading.gif';
+import Notify from '@commonComp/Notify';
 import ReactDom from 'react-dom';
 
 /*const propTypes = {
@@ -43,9 +44,7 @@ class Loading extends React.Component{
             <div className={style['loading']} style={{display: show ? 'block' : 'none'}}>
                 {/*{this.props.shadeIsShow?<div className={style['cover']}/>:null}*/}
                 <div className={style['cover']}/>
-              {type==='warning'?<div className={style['t-info']}>
-                <p><img src={wnIcon} alt=""/>{text}</p>
-              </div>:<div className={style['info']}>
+              {type==='warning'?Notify.info(text,0, false,false):<div className={style['info']}>
                     <img src={icon}/>
                     <p>{text}</p>
                 </div>}

+ 8 - 8
src/common/components/Notify/index.js

@@ -29,19 +29,19 @@ function createNotification() {
 }
 
 let notification
-const notice = (type, content, duration=2000, onClose) => {
+const notice = (type, content, duration=2000, onClose, showClose=true) => {
     if (!notification) notification = createNotification()
-    return notification.addNotice({ type, content, duration, onClose })
+    return notification.addNotice({ type, content, duration, onClose,showClose })
 }
 
 export default {
-    info(content, duration, onClose) {
-        return notice('info', content, duration, onClose)
+    info(content, duration, onClose, showClose) {
+        return notice('info', content, duration, onClose, showClose)
     },
-    success(content = '操作成功', duration, onClose) {
-        return notice('success', content, duration, onClose)
+    success(content = '操作成功', duration, onClose, showClose) {
+        return notice('success', content, duration, onClose, showClose)
     },
-    error(content, duration , onClose) {
-        return notice('error', content, duration, onClose)
+    error(content, duration , onClose, showClose) {
+        return notice('error', content, duration, onClose, showClose)
     }
 }

+ 9 - 9
src/common/components/Notify/index.less

@@ -10,11 +10,11 @@
   top: 0; 
 }
 .notify-box {
-  min-width: 350px;
-  height:70px;
+  // min-width: 350px;
+  // height:70px;
   position: fixed;
-  padding-right: 90px;
-  top:30%;
+  padding-right: 100px;
+  top:40%;
   left:50%;
   transform: translate(-50%, -50%);
   // margin:-35px 0 0  -175px;
@@ -22,13 +22,13 @@
   border-radius: 10px;
   line-height: 70px;
   box-sizing: border-box;
-  border: 1px solid;
+  border: 1px solid #000;
 }
 .notify-text {
-  min-width: 224px;
-  height: 70px;
+  // min-width: 224px;
+  max-height: 280px;
   padding:  0 40px 0 0;
-  // overflow: hidden;
+  overflow-y: auto;
   position: relative;
   left: 66px;
   top: 0;
@@ -76,6 +76,6 @@
 }
 .notify-close {
   position: absolute;
-  right: 10px;
+  right: 0px;
   top: 15px;
 }

+ 1 - 2
src/common/components/Notify/notify.js

@@ -22,7 +22,6 @@ class NotifyBox extends Component {
 
         // notices.push(notice);//展示所有的提示
         notices[0] = notice;//仅展示最后一个提示
-        
         this.setState({ notices })
         if (notice.duration > 0) {
             clearTimeout(this.state.timer);
@@ -70,7 +69,7 @@ class NotifyBox extends Component {
                             <div className={style['notify-box']} style={styles[notice.type]}>
                                 <div className={style[`${icons[notice.type]}`]}></div>
                                 <div className={style['notify-text']}>{notice.content}</div>
-                                <img  className={style['notify-close']} onClick={()=>{this.removeNotice(notice.key)}} src={close}/>
+                                {notice.showClose&&<img  className={style['notify-close']} onClick={()=>{this.removeNotice(notice.key)}} src={close}/>}
                             </div>
                         </div>
                     ))

+ 3 - 3
src/common/components/Radio/index.jsx

@@ -36,10 +36,10 @@ class Radio extends React.Component {
   }
 
   render() {
-    const {id,label,isSelect,disabled} = this.props;
+    const {id,label,isSelect,disabled, noSelected} = this.props;
     if(disabled){
       return (
-        <div className={style['radio']}
+        <div className={`${style['radio']} ${noSelected ? style['noSelected']:''}`}
              style={this.getStyle()}>
           <img src={isSelect?disable:off}/>
           <span style={{color:'#aaa'}}>{label}</span>
@@ -47,7 +47,7 @@ class Radio extends React.Component {
       )
     }
     return (
-      <div className={style['radio']}
+      <div className={`${style['radio']} ${noSelected ? style['noSelected']:''}`}
            onClick={() =>this.handleClick(id)}
            style={this.getStyle()}>
         <img src={isSelect?on:off}/>

+ 3 - 0
src/common/components/Radio/index.less

@@ -7,4 +7,7 @@
     vertical-align: middle;
     margin-right: 6px;
   }
+}
+.noSelected {
+  cursor:not-allowed;
 }

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

@@ -90,7 +90,7 @@ class Advice extends Component{
         </div>}
         {!isFirstMainDiag && hasFollowUp &&<FollowUp  noHeader="true" textStyle={{padding: '0 10px'}}  setFollowUp={saveFollowUp} followUp = {followUp} isRead={isRead}></FollowUp>}
         {advice.scheme && advice.scheme.length > 0 &&<div contentEditable='false' className={`${style['scheme']} ${setFontColorSize(2)}`}>
-          {advice.scheme && advice.scheme.length > 0  && <h1>治疗方案</h1>}
+          {advice.scheme && advice.scheme.length > 0  && <h1>建议用药</h1>}
           {scheme}
         </div>}
         <div className={`${style['billing']} ${setFontColorSize(2)}`} > 

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

@@ -41,12 +41,14 @@ class ChooseItem extends Component {
                 <div className={style['row']}>
                   {it.details&&it.details.map((i)=> {
                     if(it.controltype ==0){
-                      return <div className={style['choose-item']}>
+                      return <div className={`${style['choose-item']}  ${selecteds&&selecteds[it.name]==i.detailName||(selecteds&&!selecteds[it.name]&&i.state==1) ? style['selectd']:style['dis-selectd']}`}>
                                 <Radio label={i.detailName}
                                        value={i.detailName}
                                        disabled={disabled}
                                        isSelect={selecteds&&selecteds[it.name]==i.detailName||(selecteds&&!selecteds[it.name]&&i.state==1)}
-                                       handleClick={this.handleRadio.bind(this,it.name,i.detailName)}></Radio>
+                                       noSelected = {title == '风险因素评估:'}
+                                       handleClick={title == '风险因素评估:' ? '':this.handleRadio.bind(this,it.name,i.detailName)}
+                                       ></Radio>
                                 {/*{i.state?<i>(智能推荐)</i>:''}*/}
                               </div>;
                     }else{

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

@@ -34,10 +34,10 @@
   }
   li {
     line-height: 35px;
-    /*.row{
+    .row{
       display: inline-block;
       max-width: 86%;
-    }*/
+    }
     .results{
       position: relative;
     }

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

@@ -111,7 +111,7 @@ class PreviewBody extends Component {
             <td className={`${style['patInfoSec']} ${style['pushMessage']} ${style['font14']}`}>
               {((adviceData&&adviceData.assay && adviceData.assay.length > 0) || ((adviceData&&adviceData.check)&& (adviceData&&adviceData.assay.check > 0))) && <p className={style.pushMessageTitle}><span>开单项目</span></p>}
               {
-                ((adviceData&&adviceData.assay && adviceData.assay.length > 0) || ((adviceData&&adviceData.check) && (adviceData&&adviceData.assay.check > 0))) && <div className={style.pushMessageDes}>{adviceData.check?adviceData.check+',':''} {adviceData.assay}</div>
+  ((adviceData&&adviceData.assay && adviceData.assay.length > 0) || ((adviceData&&adviceData.check) && (adviceData&&adviceData.assay.check > 0))) && <div className={style.pushMessageDes}>{adviceData.assay}{adviceData.check}</div>
               }
               {adviceData&&adviceData.commontreatment && adviceData.commontreatment.length > 0 && <p  className={style.pushMessageTitle}><span>一般治疗</span></p>}
               {

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

@@ -88,7 +88,7 @@ class DetailsModal extends Component {
                                             return (<div class={styles['details-menu-title-wrapper']}>
                                                 <div className={styles['details-menu-title-box']}>
                                                     {index === 0 ? '' : <div className={styles['details-content-menu-line']}></div>}
-                                                    <span onClick={this.handleClickMenu.bind(this, index, item, tipsDetails)} className={styles['details-content-menu-name']} style = {index === currentIndex ? {color:'#0089be'} : ''}>
+                                                    <span onClick={this.handleClickMenu.bind(this, index, item, tipsDetails)} className={styles['details-content-menu-name']} style = {index === currentIndex ? {color:'#3B9ED0'} : ''}>
                                                         <div className={styles['details-content-menu-circle-box']}>
                                                             {index !== currentIndex&&<span className={styles['details-content-menu-circle']} ></span>}
                                                             {index === currentIndex&&<img className={styles['details-content-menu-img']} src ={imgCurrent}/>}

+ 30 - 26
src/components/PushItems/DetailsModal/index.less

@@ -6,7 +6,7 @@
     height: 100%;
     left: 0;
     top: 0;
-    line-height: 20px;
+    line-height: 21px;
     img {
         max-width: 100%;
     }
@@ -14,7 +14,7 @@
 
 .details-content-wrapper {
     position: fixed;
-    padding: 50px 0;
+    padding: 110px 0 50px 0;
     width: 80%;
     height: 80%;
     left: 10%;
@@ -33,33 +33,36 @@
 
 .details-content-name {
     position: absolute;
-    top: 0;
+    top: 43px;
     width: 100%;
-    padding: 0 40px;
-    height: 50px;
-    line-height: 50px;
-    font-size: 32px;
+    padding: 0  40px;
+    height: 37px;
+    line-height: 37px;
+    font-size: 28px;
     font-weight: bold;
+    color: #1E1E1E;
 }
 
 .details-content-title-box {
     position: relative;
-    height: 40px;
-    line-height: 40px;
+    line-height: 30px;
     font-size: 20px;
 }
 .details-menu-title-wrapper {
-    padding: 0 0 0 15px;
+    padding: 0 4px 0 20px;
     position: relative;
 }
 
 .details-content-title-name {
-    position: absolute;
+    position: relative;
     font-weight: bold;
     background: #fff;
     padding-right: 5px;
     font-size: 22px;
+    line-height: 30px;
+    display: inline-block;
     z-index: 10;
+    color: #1E1E1E;
 }
 
 
@@ -67,15 +70,14 @@
     position: absolute;
     right: 0;
     cursor: pointer;
+    top: -43px;
 }
 .details-content {
     position: relative;
     height: 100%;
-    padding: 0 180px 0 40px;
+    padding: 0 220px 0 40px;
     overflow-y: auto;
-    ul, ol {
-        padding: 0 0 0 15px;
-      }
+    
       ul li {
         list-style: disc;
         list-style-position: inside;
@@ -87,15 +89,15 @@
 }
 .content-menu-box {
     position: absolute;
-    top: 50px;
+    top: 110px;
     right: 20px;
-    width: 160px;
+    width: 200px;
     height: 80%;
     overflow: hidden;
     
 }
 .content-menu-wrapper {
-    width: 200px;
+    width: 240px;
     height: 100%;
     overflow-y: auto;
 }
@@ -103,11 +105,11 @@
     
     background: #F5F6F7;
     border: 1px solid #F5F6F7;
-    width: 160px;
-    padding: 15px 18px;
+    width: 200px;
+    padding: 15px 20px;
 }
 .details-content-menu-line {
-    height: 15px;
+    height: 20px;
     width: 0;
     background-color: #E0E2E3;
     margin-left: 0px
@@ -115,13 +117,14 @@
 .details-content-menu-name {
     position: relative;
     color: #777777;
-    font-size: 13px;
+    font-size: 14px;
     cursor: pointer;
+    line-height: 19px;
 }
 .details-content-menu-circle-box {
     display:inline-block;
     position: absolute;
-    left: -20px;
+    left: -25px;
     background: #F5F6F7;
 
 }
@@ -155,13 +158,13 @@
 }
 .details-content-box {
     border-left: 1px solid #969C9F;
-    padding: 0 0 0 20px;
+    padding: 0 0 0 33px;
 }
 .details-content-title-circle-box {
    position: absolute;
    z-index: 10;
    background: #fff;
-   left: -27px;
+   left: -40px;
    height: 32px;
    top: 0px;
 }
@@ -181,6 +184,7 @@ pre {
     white-space: pre-wrap;
     word-wrap: break-word;
     font-family: inherit;
-    color: #333;
+    color: #1E1E1E;
     margin: 10px 0;
+    line-height: 21px;
   }

+ 11 - 3
src/components/Treat/AdverseReactions/index.jsx

@@ -1,4 +1,5 @@
 import React, { Component } from 'react';
+import { Radio } from '@commonComp';
 import style from './index.less';
 import info2 from './../img/info2.png';
 import info3 from './../img/info3.png';
@@ -75,9 +76,16 @@ class AdverseReactions extends Component {
                         
                     </span>
                         {item.details.map((it, idx) => {
-                            return <span className={`style['adverse-reactions-name'] ${it.value == 1 ? style['selectd']:''}`} key={item.conceptId + item.name + it.name}>
-                                <input type="radio" checked={it.value == 1}  id={item.conceptId +item.name + it.name} onChange={this.changeReact.bind(this, it, index)}/>
-                                <label for={item.conceptId +item.name + it.name}> {it.name} </label>
+                            return <span className={`${style['adverse-reactions-name']} ${it.value == 1 ? style['selectd']:style['dis-selectd']}`} key={item.conceptId + item.name + it.name}>
+                                {/* <input type="radio" checked={it.value == 1}  id={item.conceptId +item.name + it.name} 
+                                    // onChange={this.changeReact.bind(this, it, index)}
+                                />
+                                <label for={item.conceptId +item.name + it.name}> {it.name} </label> */}
+                                <Radio label={it.name}
+                                       isSelect={it.value == 1}
+                                       noSelected = 'true'
+                                      //  handleClick={this.handleRadio.bind(this,it.name,i.detailName)}
+                                ></Radio>
                                 {/* {it.value==1 && <span className={style['adverse-reactions-recommend']}>(智能推荐)</span>} */}
                             </span>
                         })}

+ 1 - 1
src/components/TreatDesc/DrugInfo/index.jsx

@@ -77,7 +77,7 @@ class DrugInfo extends Component {
                                         return (<div class={style['details-menu-title-wrapper']}>
                                             <div className={style['details-menu-title-box']}>
                                                 {index === 0 ? '' : <div className={style['details-content-menu-line']}></div>}
-                                                <span onClick={this.handleClickMenu.bind(this, index, item, drugInfo.drugDesc)} className={style['details-content-menu-name']} style = {index === currentIndex ? {color:'#0089be'} : ''}>
+                                                <span onClick={this.handleClickMenu.bind(this, index, item, drugInfo.drugDesc)} className={style['details-content-menu-name']} style = {index === currentIndex ? {color:'#3B9ED0'} : ''}>
                                                     <div className={style['details-content-menu-circle-box']}>
                                                         {index !== currentIndex&&<span className={style['details-content-menu-circle']} ></span>}
                                                         {index === currentIndex&&<img className={style['details-content-menu-img']} src ={imgCurrent}/>}

+ 28 - 24
src/components/TreatDesc/DrugInfo/index.less

@@ -9,14 +9,12 @@
     top: 10%;
     margin-left: -475px;
     background: #fff;
-    padding: 50px 0 60px;
+    padding: 110px 0 50px 0;
     box-shadow: 0px 0px 5px -2px #7d7c7c;
     word-break: break-all;
     max-width: 100%;
     line-height: 20px;
-    ul, ol {
-        padding: 0 0 0 15px;
-      }
+    
       ul li {
         list-style: disc;
         list-style-position: inside;
@@ -33,13 +31,14 @@
 }
 .drug-title {
     position: absolute;
-    top: 0;
+    top: 43px;
     width: 100%;
-    height: 50px;
-    line-height: 50px;
-    font-size: 32px;
+    height: 37px;
+    line-height: 37px;
+    font-size: 28px;
     font-weight: bold;
     padding: 0 40px;
+    color: #1E1E1E;
     cursor: move;
     moz-user-select: -moz-none;
     -moz-user-select: none;
@@ -61,7 +60,7 @@
 .drug-desc-item {
     zoom: 1;
     border-left: 1px solid #969C9F;
-    padding: 0 0 0 20px;
+    padding: 0 0 0 33px;
     &:after{
         content: "";
         display: block;
@@ -85,54 +84,55 @@
     height: 60px;
     line-height: 60px;
     font-size: 32px;
-    color: #000000;
+    color: #1E1E1E;
     text-align: center;
 }
 .drug-desc-content {
     /*width: 100%;*/
-    margin: 10px 160px 10px 10px;
+    margin: 10px 200px 10px 10px;
 }
 
 .content-menu-box {
     position: absolute;
-    top: 50px;
+    top: 110px;
     right: 20px;
-    width: 160px;
+    width: 200px;
     height: 80%;
     overflow: hidden;
     
 }
 .content-menu-wrapper {
-    width: 200px;
+    width: 240px;
     height: 100%;
     overflow-y: auto;
 }
 .content-menu-border{
     border-left: 2px solid #E0E2E3;
-    padding: 0 0 0 15px;
+    padding: 0 4px 0 20px;
 }
 .content-menu {
     
     background: #F5F6F7;
     border: 1px solid #F5F6F7;
-    width: 160px;
-    padding: 15px 18px;
+    width: 200px;
+    padding: 15px 20px;
 }
 .details-content-menu-line {
-    height: 15px;
+    height: 20px;
     width: 0;
     margin-left: 4px
 }
 .details-content-menu-name {
     position: relative;
     color: #777777;
-    font-size: 13px;
+    font-size: 14px;
     cursor: pointer;
+    line-height: 19px;
 }
 .details-content-menu-circle-box {
     display:inline-block;
     position: absolute;
-    left: -20px;
+    left: -25px;
     background: #F5F6F7;
 
 }
@@ -157,7 +157,7 @@
     position: absolute;
     z-index: 10;
     background: #fff;
-    left: -27px;
+    left: -40px;
     height: 32px;
     top: 0px;
  }
@@ -172,21 +172,25 @@
  }
  .details-content-title-box {
     position: relative;
-    height: 40px;
     line-height: 40px;
+    margin: 0 180px 0 0;
     font-size: 20px;
 }
 .details-content-title-name {
-    position: absolute;
+    position: relative;
     font-weight: bold;
     background: #fff;
     padding-right: 5px;
     font-size: 22px;
+    line-height: 30px;
+    display: inline-block;
     z-index: 10;
+    color: #1E1E1E;
 }
 pre {
     white-space: pre-wrap;
     word-wrap: break-word;
     font-family: inherit;
-    color: #333;
+    color: #1E1E1E;
+    line-height: 21px;
   }

+ 10 - 10
src/store/actions/pushMessage.js

@@ -62,7 +62,7 @@ function getAdviceStr(advice) {
 					if(treatmentItem.treatmentStr === '') {
 						AdviceStr += treatmentItem.treatmentStr
 					}else {
-						AdviceStr += treatmentItem.treatmentStr + ', '
+						AdviceStr += treatmentItem.treatmentStr + ''
 					}
 				}
 			}
@@ -85,8 +85,8 @@ function getAdviceStr(advice) {
 
 
 	}
-	if(AdviceStr.slice(AdviceStr.length-2) == ', ') {
-		AdviceStr = AdviceStr.slice(0, AdviceStr.length-2)
+	if(AdviceStr.slice(AdviceStr.length-1) == ',') {
+		AdviceStr = AdviceStr.slice(0, AdviceStr.length-1)
 	}
 	// if(commontreatment)  { 
 	// 	AdviceStr = commontreatment +'; ' + AdviceStr;
@@ -117,13 +117,13 @@ export const addScheme = (state, action) => {
 				for(let l = 0; l < treatment[i].meditionDetails[j].treatment[k].medicitionsList.length; l++) {
 					const drugItem = treatment[i].meditionDetails[j].treatment[k].medicitionsList[l]
 					if(drugItem.selected) {
-						treatmentStr = treatmentStr + drugItem.medicitionName + ', '
+						treatmentStr = treatmentStr + drugItem.medicitionName + ''
 						drugList.push({conceptId: drugItem.conceptId, conceptName: drugItem.medicitionName })
 						SelectedDrugNum++
 					}
 					
 				}
-				treatment[i].meditionDetails[j].treatment[k].treatmentStr = treatmentStr.substring(0,treatmentStr.length-2)
+				treatment[i].meditionDetails[j].treatment[k].treatmentStr = treatmentStr.substring(0,treatmentStr.length-1)
 				treatment[i].meditionDetails[j].treatment[k].drugList = drugList
 			}
 		}
@@ -200,7 +200,7 @@ export const addScheme = (state, action) => {
 									const medicitionsItem = treatItem.medicitionsList[w]
 									if(medicitionsItem.selected) {
 										if(schemeItem.treatmentStr !== '') {
-											schemeItem.treatmentStr += ', ' +medicitionsItem.medicitionName
+											schemeItem.treatmentStr += '' +medicitionsItem.medicitionName
 										} else {
 											schemeItem.treatmentStr += '' +medicitionsItem.medicitionName
 										}
@@ -329,7 +329,7 @@ export const addBilling = (state, action) => {
 			if( i === 0 && res.advice.check !== '') {
 				res.advice.assay = res.advice.assay  +  assay[i].name
 			} else {
-				res.advice.assay = res.advice.assay + ', ' + assay[i].name
+				res.advice.assay = res.advice.assay + '' + assay[i].name
 			}
 		}
 		
@@ -338,12 +338,12 @@ export const addBilling = (state, action) => {
 		if ( res.advice.check === '') { //如果最后一个,则不需要逗号
 			res.advice.check = res.advice.check + check[i].name
 		} else {
-			res.advice.check = res.advice.check + ', '+ check[i].name 
+			res.advice.check = res.advice.check + ''+ check[i].name 
 		}
 	}
 	if(res.advice.assay  && res.advice.check !== '') {
-			if(res.advice.assay.substring(res.advice.assay.length-2,res.advice.assay.length-1) !== ',') {
-				res.advice.assay = res.advice.assay + ', '
+			if(res.advice.assay.substring(res.advice.assay.length-1,res.advice.assay.length) !== ',') {
+				res.advice.assay = res.advice.assay + ''
 			} 
 	}
 	res.AdviceStr = getAdviceStr(res.advice)