Przeglądaj źródła

修改诊断名称过长时情况(2438)

zhangxc 5 lat temu
rodzic
commit
c61c4d3a68

+ 1 - 1
src/common/components/ConfirmModal/index.jsx

@@ -130,7 +130,7 @@ class ConfirmModal extends Component {
         return (
             <NewPortal visible={visible}>
                 <div className={styles['modal-wrapper']} id='confirm'>
-                    <div className={styles[['modal']]} style = {{width: width, marginLeft:marginLeft, height:height, marginTop:marginTop}}>
+                    <div className={styles[['modal']]} style = {{width: width, marginLeft:marginLeft, minHeight:height, marginTop:marginTop}}>
                         <div className={styles['modal-title']} style={{background: titleBg}}>
                             {icon?<img src={icon} className={styles['icon']}/>:''}
                             {title ? title : ''} 

+ 3 - 3
src/components/DiagnosticItem/index.less

@@ -1,9 +1,9 @@
 .confirm-info {
-    height: 70px;
+    min-height: 70px;
     font-size: 16px;
-    line-height: 16px;
+    line-height: 20px;
     text-align: center;
-    padding: 10px 30px;
+    padding: 10px 20px 20px;
 }
 .diag-item {
     display: inline-block;

+ 4 - 3
src/components/DiagnosticList/index.jsx

@@ -241,6 +241,7 @@ class DiagnosticList extends Component {
         this.props.getBilling();
       }
     }
+   
     handleEnterDel(index) {
       this.setState({
         hasOnIndex: index,
@@ -274,7 +275,7 @@ class DiagnosticList extends Component {
       })
     }
     render(){
-        const { list, treatment, showReferRecord, showHistoryCase ,chronicMagItem,loading,refreshScroller} = this.props;
+        const { list, treatment, showReferRecord, showHistoryCase ,chronicMagItem,loading,refreshScroller,windowWidth} = this.props;
         const {visible, treatTitle, showAssess, isAssessConfirm, assessId, disName, hasOndel, hasOnIndex,hasEnterItem,hasEnterImg} = this.state;
         const chronicList = JSON.parse(localStorage.getItem('chronic')||null);
         let isChronic = false;      //是否要显示管理评估
@@ -288,7 +289,7 @@ class DiagnosticList extends Component {
                         const hasTreat = item.treat && ((item.treat.commonTreatment&&item.treat.commonTreatment.content) || (item.treat.surgeryTreatment&&item.treat.surgeryTreatment.content) || item.treat.treatment.length>0 ||(item.adverseReactions&&item.adverseReactions.length > 0)
                            || (item.drugHistory && item.drugHistory['慢病用药内容'] &&  item.drugHistory['慢病用药内容'].length > 0) || (item.drugHistory &&item.drugHistory['普通病用药内容'] &&  item.drugHistory['普通病用药内容'].length > 0) ||item.follow)
                         isChronic = chronicMagItem&&item.type==2&&chronicList.findIndex((it)=>it.conceptId==item.conceptId)!=-1;
-                        return (<div draggable={true} className={style['diag-box'] + ' clearfix'}  key={item.conceptId} >
+                        return (<div draggable={true} className={style['diag-box'] + ' clearfix'} id="diagListBox" key={item.conceptId} >
                                     {index === 0 ? '' : <span className={style['diag-up']} onClick={() => {this.upDiagnostic(index)}}><img className={style["diag-up"]} src={diagUp}/></span>}
                                     {list.length === 1 ? '' : index !== 0 ? '' : <span onClick={() => {this.downDiagnostic(index)}} className={style['diag-down']}><img className={style["diag-down"]} src={diagDown}/></span>}
                                     <span className={style['diag-number']} style={{fontWeight:index === 0 ?'bold':'normal'}}>{index === 0 ? '1' : index+1}</span>
@@ -296,7 +297,7 @@ class DiagnosticList extends Component {
                                        onMouseEnter={this.handleMouseEnterDrug.bind(this,index)}
                                        onMouseLeave = {this.handleMouseLeaveDrug.bind(this)}
                                     >
-                                      <span  onClick={this.handleClickDiag.bind(this,item,false,true,false)}>
+                                      <span   className={style['diag-name-box']} style={{width: windowWidth > 1024 ?windowWidth-900 +'px':'130px'}} onClick={this.handleClickDiag.bind(this,item,false,true,false)}>
                                         {item.name}
                                       </span>
                                       <img className={style['info-img']}  

+ 7 - 0
src/components/DiagnosticList/index.less

@@ -50,6 +50,7 @@
 
 
 .diag-name {
+   
     margin-left: 10px;
     border-bottom: 1px solid #666;
     box-sizing: border-box;
@@ -58,6 +59,12 @@
     font-weight: bold;
     cursor: pointer;
 }
+.diag-name-box {
+    .ellipsis;
+    display: inline-block;
+    line-height: 16px;
+    // max-width: 220px;
+}
 
 .diag-up, .diag-down {
     position: relative;

+ 1 - 0
src/containers/DiagnosticList.js

@@ -27,6 +27,7 @@ function mapStateToProps(state) {
         scaleInfo: pushMessage.scaleInfo,//量表内容
         showHide: pushMessage.showHide,
         loading: diagnosticList.loading,
+        windowWidth: state.homePage.windowWidth
     }
 }