فهرست منبع

患者信息最小宽度改小

zhouna 5 سال پیش
والد
کامیت
678b36818f
3فایلهای تغییر یافته به همراه13 افزوده شده و 14 حذف شده
  1. 1 1
      src/components/InfoTitle/index.jsx
  2. 9 10
      src/components/PatInfo/index.jsx
  3. 3 3
      src/components/PatInfo/index.less

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

@@ -53,7 +53,7 @@ class InfoTitle extends Component {
         const {disVisible,copyVisible,winWidth,loading} = this.props;
         const {le} = this.state;
         return <div className={style['title-wrapper']} >
-            <PatInfoContainer sizeFlag={winWidth <= 1065?true:false}/>
+            <PatInfoContainer />
             <div className={style['activeWrap']}>
                 <div className={style["operations"]} onClick={this.showHistoryBox}>
                     <span><img src={historyCase} />&nbsp;历史病历</span>

+ 9 - 10
src/components/PatInfo/index.jsx

@@ -12,19 +12,18 @@ class PatInfo extends Component {
 
   render(){
     const {message} = this.props.patInfo;
-    const {sizeFlag} = this.props;
-     return <table className={sizeFlag?`${style["table"]} ${style["newSize"]}`:style["table"]}>
+     return <table className={style["table"]}>
       <tr>
-        <td key='1' className={`${style.tdBorderB} ${style.tdBorderR}`} title={'卡号:' + (message.patientIdNo && message.patientIdNo)}>卡号:{message.patientIdNo && message.patientIdNo}</td>
-        <td key='2' className={`${style.tdBorderB} ${style.tdBorderR}`} title={sizeFlag&&message.patientName&&message.patientName.length>3?message.patientName:''}>姓名:{sizeFlag&&message.patientName && message.patientName.length>3?message.patientName.slice(0,3)+'...':message.patientName}</td>
-        <td key='3' className={`${style.tdBorderB} ${style.tdBorderR}`}>年龄:{message.patientAge && message.patientAge}</td>
-        <td key='4' className={`${style.tdBorderB} ${style.tdBorderR}`}>性别:{message.patientSex && message.patientSex}</td>
+        <td key='1' className={`${style.tdBorderB} ${style.tdBorderR}`} title={'卡号:' + (message.patientIdNo||'')}>卡号:{message.patientIdNo}</td>
+        <td key='2' className={`${style.tdBorderB} ${style.tdBorderR}`} title={'姓名:' + (message.patientName||'')}>姓名:{message.patientName}</td>
+        <td key='3' className={`${style.tdBorderB} ${style.tdBorderR}`} title={'年龄:'+(message.patientAge||'')}>年龄:{message.patientAge}</td>
+        <td key='4' className={`${style.tdBorderB} ${style.tdBorderR}`} title={'性别:'+(message.patientSex||'')}>性别:{message.patientSex}</td>
       </tr>
       <tr>
-        <td key='5' className={`${style.tdBorderR}`} style={{whiteSpace: 'nowrap'}} title={'就诊时间:'+(message.systemTime&&message.systemTime.substring(0, 10))}>就诊时间:{message.systemTime&&message.systemTime.substring(0, 10)}</td>
-        <td key='6' className={`${style.tdBorderR}`}>科室:{message.hospitalDeptName && message.hospitalDeptName}</td>
-        <td key='7' className={`${style.tdBorderR}`} title={sizeFlag&&message.doctorName&&message.doctorName.length>3?message.doctorName:''}>医生:{sizeFlag&&message.doctorName && message.doctorName.length>3?message.doctorName.slice(0,3)+'...':message.doctorName}</td>
-        <td key='8' className={`${style.tdBorderR}`} title={'门诊号:'+(message.recordId && message.recordId)}>门诊号:{message.recordId && message.recordId}</td>
+        <td key='5' className={`${style.tdBorderR}`} style={{whiteSpace: 'nowrap'}} title={'就诊时间:'+(message.systemTime&&message.systemTime.substring(0, 10)||'')}>就诊时间:{message.systemTime&&message.systemTime.substring(0, 10)}</td>
+        <td key='6' className={`${style.tdBorderR}`} title={'科室:'+(message.hospitalDeptName||'')}>科室:{message.hospitalDeptName}</td>
+        <td key='7' className={`${style.tdBorderR}`} title={'医生:'+(message.doctorName||'')}>医生:{message.doctorName}</td>
+        <td key='8' className={`${style.tdBorderR}`} title={'门诊号:'+(message.recordId||'')}>门诊号:{message.recordId}</td>
       </tr>
     </table>;
   }

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

@@ -13,14 +13,14 @@
   }
   .tdBorderB {
     border-bottom: 1px solid @person-table-color;
-    max-width: 180px;
+    max-width: 110px;
     overflow: hidden;
     white-space: nowrap;
     text-overflow: ellipsis;
   }
   .tdBorderR {
     border-right: 1px solid @person-table-color;
-    max-width: 180px;
+    max-width: 110px;
     overflow: hidden;
     white-space: nowrap;
     text-overflow: ellipsis;
@@ -32,6 +32,6 @@
     font-size: 13px;
     white-space: nowrap;
     text-overflow: ellipsis;
-    max-width: 180px;
+    max-width: 110px;
   }
 }