Quellcode durchsuchen

参数名修改

wyq vor 3 Jahren
Ursprung
Commit
59b09855f2

+ 7 - 0
src/components/AddInspect/SlidePic/index.less

@@ -49,6 +49,13 @@
     }
     .smallname {
         width: 16%;
+        overflow: hidden;
+        word-break: break-all;
+        -o-text-overflow: ellipsis;
+        text-overflow: ellipsis;
+        display: -webkit-box;
+        -webkit-box-orient: vertical;
+        -webkit-line-clamp: 3;
     }
     .edit {
         width: 15%;

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

@@ -7,6 +7,7 @@
     padding-top: 10px;
     padding-bottom: 10px;
     border-bottom:1px dashed #989DA3;
+    display: flex;
     i {
         font-style: normal;
         display: inline-block;

+ 48 - 41
src/components/PreviewBody/Inspect/index.jsx

@@ -1,44 +1,44 @@
 import style from "../index.less";
-import { normalVal,getStatusImg } from '@utils/tools';
+import { normalVal, getStatusImg } from '@utils/tools';
 import report from '@common/images/report_time.png';
 import billing from '@common/images/billing_time.png';
 
 const PreviewInspect = (props) => {
-  const { dataJson, toTime ,dateTime,showDetails  } = props;
+  const { dataJson, toTime, dateTime, showDetails } = props;
   // console.log(dateTime,'dateTime');
-    return <tr className={style['patInfoFst']}>
-      <td className={style['patInfoSec']}>检验:</td>
-      <td className={style['patInfoSec']}>
-        <table className={style.assistTable}>
+  return <tr className={style['patInfoFst']}>
+    <td className={style['patInfoSec']}>检验:</td>
+    <td className={style['patInfoSec']}>
+      <table className={style.assistTable}>
         {
-          (dataJson.labelListSmall.length !== 0 || dataJson.labelListBig.length !== 0) && ( <span style={{ lineHeight: '36px' }}>检验结果数据</span>)
+          (dataJson.labelListSmall.length !== 0 || dataJson.labelListBig.length !== 0) && (<span style={{ lineHeight: '36px' }}>检验结果数据</span>)
         }
         {
           dataJson && dataJson.labelListSmall && dataJson.labelListSmall.map((item) => {
             // console.log(item, item,'=====');
-              return (               
-                  <tr className={style.assistTableTrSec}>
-                  <td className={style.assistTableTdFst}>{item.detailName}</td>
-                    <td className={style.assistTableTdSec}>
-                      {/* {getStatusImg(value.type, value.value, 1)}
+            return (
+              <tr className={style.assistTableTrSec}>
+                <td className={style.assistTableTdFst}>{item.detailName}</td>
+                <td className={style.assistTableTdSec}>
+                  {/* {getStatusImg(value.type, value.value, 1)}
                       {value.unit} */}
-                      {getStatusImg(0, item.value, 1)}
-                      {item.units}
-                      {/* {getStatusImg(2, 9.8, 1)}
+                  {getStatusImg(0, item.value, 1)}
+                  {item.units}
+                  {/* {getStatusImg(2, 9.8, 1)}
                       {'mmol/L'} */}
-                    </td>
-                    {/* {showDetails(item)} */}
-                    <td className={style.assistTableTdTrd}>
-                      {normalVal(item.minValue, item.maxValue)}
-                      {/* {normalVal(3.9, 6.1)} */}
-                    </td>
-                    {/* <td className={style.assistTableTdFor}>{item.time == '' ? ('导入时间:' + dateTime) : '检验时间:' + toTime(item.time) */}
-                  {/* <td className={style.assistTableTdFor}>{item.time == '' ?   dateTime  :  item.time}</td> */}
-                  <td className={style.assistTableTdFor}><img className={style.imgCheck} src={report} title={'报告时间'} />{item.time }</td>
-                  <td className={style.assistTableTdFor}><img className={style.imgCheck} src={report} title={'报告时间'} />{item.finishDateValue}</td>
-                  </tr>
-                // </table>
-              )
+                </td>
+                {/* {showDetails(item)} */}
+                <td className={style.assistTableTdTrd}>
+                  {normalVal(item.minValue, item.maxValue)}
+                  {/* {normalVal(3.9, 6.1)} */}
+                </td>
+                {/* <td className={style.assistTableTdFor}>{item.time == '' ? ('导入时间:' + dateTime) : '检验时间:' + toTime(item.time) */}
+                {/* <td className={style.assistTableTdFor}>{item.time == '' ?   dateTime  :  item.time}</td> */}
+                <td className={style.assistTableTdFor}><img className={style.imgCheck} src={report} title={'开单时间'} />{item.time}</td>
+                <td className={style.assistTableTdFor}><img className={style.imgCheck} src={report} title={'报告时间'} />{item.finishDateValue}</td>
+              </tr>
+              // </table>
+            )
           })
         }
 
@@ -46,21 +46,28 @@ const PreviewInspect = (props) => {
           dataJson && dataJson.labelListBig && dataJson.labelListBig.map((item) => {
             return (
               // <table style={style.assistTable}>
-                <tr className={style.assistTableTrSec}>
-                  <td className={style.assistTableTdFst}>{item.name}</td>  
-                  <td className={style.assistTableTdSec}></td>
-                  <td className={style.assistTableTdTrd}></td>                                             
-                  {/* <td className={style.assistTableTdFor}>{item.time == '' ? ('导入时间:' + dateTime) : '检验时间:' + toTime(item.time) */}
-                  {/* <td className={style.assistTableTdFor}>{item.time == '' ? dateTime : toTime(item.time) */}
-                  <td className={style.assistTableTdFor}>{item.time == '' ? dateTime : toTime(item.time)}</td>
-                </tr>
+              <tr className={style.assistTableTrSec}>
+                <td className={style.assistTableTdFst}>{item.name}</td>
+                <td className={style.assistTableTdSec}></td>
+                <td className={style.assistTableTdTrd}></td>
+                {/* <td className={style.assistTableTdFor}>{item.time == '' ? ('导入时间:' + dateTime) : '检验时间:' + toTime(item.time) */}
+                {/* <td className={style.assistTableTdFor}>{item.time == '' ? dateTime : toTime(item.time) */}
+                <td className={style.assistTableTdFor}><img className={style.imgCheck} src={report} title={'开单时间'} />{item.time == '' ? dateTime : toTime(item.time)}</td>
+                <td className={style.assistTableTdFor}>
+                  {
+                    item.finishDateValue || item.finishDateValue != '' ? (
+                      <img className={style.imgCheck} src={report} title={'报告时间'} />
+                    ) : null
+                  }
+                  {item.finishDateValue}</td>
+              </tr>
               // </table>
             )
           })
         }
 
-        </table>
-        {/* {
+      </table>
+      {/* {
           dataJson&&dataJson.getExcelDataList && dataJson.getExcelDataList.map((items) => {
             return items.lisExcelRes && items.lisExcelRes.map((item) => {
               return <table style={style.assistTable}>
@@ -85,7 +92,7 @@ const PreviewInspect = (props) => {
             })
           })
         } */}
-        {/* {
+      {/* {
           dataJson&&dataJson.labelList && dataJson.labelList.map((item, idx) => {
             return <table style={{ margin: '8px 0', width: '100%' }}>
               {
@@ -117,8 +124,8 @@ const PreviewInspect = (props) => {
             </table>
           })
         } */}
-      </td>
-    </tr>
+    </td>
+  </tr>
 }
 
 export default PreviewInspect;

+ 3 - 4
src/utils/tools.js

@@ -70,7 +70,6 @@ const strDateTime = (str) => {
   var r = str.match(reg);
   if (r == null) return false;
   var d = new Date(r[1], r[3] - 1, r[4], r[5], r[6], r[7]);
-  console.log(r)
   return (d.getFullYear() == r[1] && (d.getMonth() + 1) == r[3] && d.getDate() == r[4] && d.getHours() == r[5] && d.getMinutes() == r[6] && d.getSeconds() == r[7]);
 }
 
@@ -157,7 +156,6 @@ const getAllDataList =(baseList) =>{           //获取所有模块结构化的
     return jsonData;
 }
 const getAllDataStringList =(baseList) =>{           //获取所有模块文本的数据
-  console.log(baseList)
     let jsonDataString = {};
     jsonDataString.lis = {};
     let chiefData = [],presentData=[],otherData=[],vitalData=[];
@@ -183,7 +181,6 @@ const getAllDataStringList =(baseList) =>{           //获取所有模块文本
     }else{
         vitalData = baseList.checkBody.saveText
     }
-  console.log(baseList.assistCheck)
     jsonDataString = {
       'chief' : JSON.stringify(chiefData),
       'present' : JSON.stringify(presentData),
@@ -1915,9 +1912,11 @@ function getAllString(checkedListImport,assistLabel,flg){
       "result": tempArr[i].value||"",
     }
     tmpArr.push(obj)
+    console.log(tempArr)
     // tmpString += (tempArr[i].name + (tmpVal ? (':' + tmpVal) + ', ' : ':') + (tempArr[i].time ? '报告日期:' + tempArr[i].time : '') + '^;')
-    tmpString += (tempArr[i].name + (tmpVal ? (':' + tmpVal) + ', ' : ':') + `<img style='margin:0 5px' src='/src/common/images/billing_time.png' alt=""/>` + (tempArr[i].time ? tempArr[i].time : '') + `<img style="margin:0 5px" src='/src/common/images/report_time.png' alt=""/>` + (tempArr[i].finishDateValue ? tempArr[i].finishDateValue : ''))
+    tmpString += (tempArr[i].name + (tmpVal ? (':' + tmpVal) + ', ' : ':') + `<img style='margin:0 5px' title="开单时间" src='/src/common/images/billing_time.png' alt=""/>` + (tempArr[i].time ? tempArr[i].time : '') + (tempArr[i].check || tempArr[i].finishDateValue == '' ? '' : `<img style="margin:0 5px" title="报告时间" src='/src/common/images/report_time.png' alt=""/>`) + (tempArr[i].check ? '' : tempArr[i].finishDateValue))
   }
+
   return tmpObj = {
     arr:tmpArr,
     str:tmpString