index.jsx 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. import React, { Component } from 'react';
  2. import style from "../index.less";
  3. class MedicalAdvice extends Component {
  4. constructor(props) {
  5. super(props);
  6. this.state = { }
  7. }
  8. render() {
  9. const {advice} = this.props
  10. console.log(advice,'===========');
  11. const {labelListBig,labelListSmall} = advice
  12. return (
  13. <tr className={style['patInfoFst']}>
  14. <td className={style['patInfoSec']}>医嘱:</td>
  15. <td className={style['patInfoSec']}>
  16. <table style={style.assistTable}>
  17. {
  18. labelListBig && labelListBig.map((item,index)=>{
  19. return (
  20. <tr>
  21. <td className={style.adviceTableTdFst}>{item.name}</td>
  22. <td className={style.assistTableTdTrd}>药品</td>
  23. <td className={style.assistTableTdSec}>{item.value}</td>
  24. <td className={style.assistTableTdFor}>{item.time}</td>
  25. </tr>
  26. )
  27. })
  28. }
  29. {
  30. labelListSmall && labelListSmall.map((item, index) => {
  31. return (
  32. <tr>
  33. <td className={style.adviceTableTdFst}>{item.name}</td>
  34. {/* <td className={style.assistTableTdSec}></td> */}
  35. <td className={style.assistTableTdTrd}>手术/操作</td>
  36. <td className={style.assistTableTdSec}>{item.value}</td>
  37. <td className={style.assistTableTdFor}>{item.time}</td>
  38. </tr>
  39. )
  40. })
  41. }
  42. </table>
  43. </td>
  44. </tr>
  45. );
  46. }
  47. }
  48. export default MedicalAdvice;