123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121 |
- import style from "../index.less";
- import { normalVal,getStatusImg } from '@utils/tools';
- const PreviewInspect = (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}>
- {
- (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)}
- {value.unit} */}
- {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}>{item.time }</td>
- </tr>
- // </table>
- )
- })
- }
- {
- 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>
- // </table>
- )
- })
- }
- </table>
- {/* {
- dataJson&&dataJson.getExcelDataList && dataJson.getExcelDataList.map((items) => {
- return items.lisExcelRes && items.lisExcelRes.map((item) => {
- return <table style={style.assistTable}>
- <tr style={style.assistTableTrFst}><td><span>{item.menus}</span></td></tr>
- {
- item.lisExcelItem && item.lisExcelItem.map((value) => {
- return <tr className={style.assistTableTrSec}>
- <td className={style.assistTableTdFst}>{value.itemName}</td>
- <td className={style.assistTableTdSec}>
- {getStatusImg(value.type,value.value,1)}
- {value.unit}
- </td>
- <td className={style.assistTableTdTrd}>
- {normalVal(value.min, value.max)}
- </td>
- <td className={style.assistTableTdFor}>{value.time == '' ? ('导入时间:' + dateTime) : '检验时间:' + toTime(value.time)
- }</td>
- </tr>
- })
- }
- </table>
- })
- })
- } */}
- {/* {
- dataJson&&dataJson.labelList && dataJson.labelList.map((item, idx) => {
- return <table style={{ margin: '8px 0', width: '100%' }}>
- {
- item.show?<tr className={style.assistTableTrFst}>
- <td colSpan='4'>
- <span> {item.name} </span>
- <p style={{display:item.inpValue?'inline-block':'none'}}>
- ({item.inpValue})
- <i></i>
- </p>
- </td>
- </tr>:
- <tr className={style.assistTableTrFstExcel}><td><span>「{item.name}」</span></td></tr>
- }
- {
- item.details.map((val) => {
- if (val.value && val.value != '') {
- return <tr className={style.assistTableTrSecExcel}>
- <td className={style.assistTableTdFst}>{val.name}</td>
- {showDetails(val)}
- <td className={style.assistTableTdTrd}>
- {normalVal(val.minValue, val.maxValue)}
- </td>
- <td className={style.assistTableTdFor}>{'检验时间:' + item.time}</td>
- </tr>
- }
- })
- }
- </table>
- })
- } */}
- </td>
- </tr>
- }
- export default PreviewInspect;
|