PatIndex.vue 7.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284
  1. <template>
  2. <div class="container">
  3. <div v-if="latestCase.id" style="position:absolute;width:100%;">
  4. <div class="bgcolor">
  5. <div class="docinfo">
  6. <img class="docavatar" src="../assets/images/doch1.jpg" width="60rem" height="60rem" />
  7. <p class="docname">{{patinfo.name}} 您好!</p>
  8. </div>
  9. </div>
  10. <!-- <div class="bgimg"></div> -->
  11. <div class="content">
  12. <div class="injectRecord">
  13. <div class="formTitle">体内FVIII活性水平实时预报</div>
  14. <div class="lrcontainer">
  15. <div class="lritem left">
  16. <!-- <div class="personRatio">
  17. </div> -->
  18. <img class="ratioBg3" src="../assets/images/personbg.png" width="80" height="216"></img>
  19. <div class="ratioBg" :style="'height:'+ratioHeight+'px;'" >
  20. <!-- <img src="../assets/images/ratiotop.png" width="100%" style="position:absolute;top:-16px;left:0;right:0;margin:auto;" ></img> -->
  21. </div>
  22. <img class="ratioBg2" src="../assets/images/personbg1.png" width="80" height="216"></img>
  23. </div>
  24. <div class="lritem right">
  25. <!-- <p style="margin:5px 0px;color:red;font-weight:bold;font-size:1.5rem">FVIII浓度:{{latestCase.FVIII}}</p> -->
  26. <div class="rowfont" style="margin:5px 0px;color:red;font-weight:bold;font-size:1.4rem">
  27. FVIII浓度:{{latestCase.FVIII}}%</div>
  28. <div class="rowfont">参考方案</div>
  29. <div class="rowfont">1.产品:{{latestCase.mpro}}</div>
  30. <div class="rowfont">2.剂量:{{latestCase.zsjl}}</div>
  31. <div class="rowfont">3.频次:{{latestCase.mfreq}}</div>
  32. <div class="rowfont">本结果仅供参考,</div>
  33. <div class="rowfont">具体治疗方案请遵医嘱执行</div>
  34. </div>
  35. </div>
  36. <div class="footer">
  37. <div class="jbbtn" @click="goPage('/patclockin')">注射打卡</div>
  38. <div class="jbbtn" @click="goPage('/patinjectionlist')">注射记录</div>
  39. <div class="jbbtn" @click="goPage('/procaselist')">查看PK曲线</div>
  40. <button class="jbbtn" @click="logout">退出登录</button>
  41. </div>
  42. </div>
  43. </div>
  44. </div>
  45. <!-- 未查询到病例信息 -->
  46. <div v-else>
  47. <div class="content">
  48. <!-- <div class="bgimg">
  49. <div class="docinfo">
  50. <img class="docavatar" src="../assets/images/doch1.jpg" width="60rem" height="60rem" />
  51. <p class="docname">{{patinfo.name}} 您好!</p>
  52. </div>
  53. <div style="margin:16.8rem auto;width:50%;font-size:1.4rem;margin-top:16.8rem">
  54. 未查询到您的信息请等待主治医生进行信息录入
  55. </div>
  56. </div> -->
  57. <div style="position:relative;">
  58. <img src="../assets/images/infobg.png" alt="" width="100%" style="">
  59. <div class="docinfo">
  60. <img class="docavatar" src="../assets/images/doch1.jpg" width="60rem" height="60rem" />
  61. <p class="docname">{{patinfo.name}} 您好!</p>
  62. </div>
  63. <div style="margin:40px auto;width:80%;font-size:1.4rem;">
  64. 未查询到您的信息请等待主治医生进行信息录入
  65. </div>
  66. </div>
  67. <div class="footer"><button class="jbbtn" @click="logout">退出登录</button></div>
  68. </div>
  69. </div>
  70. </div>
  71. </template>
  72. <script>
  73. import {
  74. Cell
  75. } from 'mint-ui'
  76. export default {
  77. name: 'Index',
  78. components: {
  79. Cell
  80. },
  81. data() {
  82. return {
  83. msg: 'Welcome to Your Vue.js App',
  84. inflag: 0,
  85. patinfo: {},
  86. latestCase: {},
  87. ratioHeight:0
  88. }
  89. },
  90. methods: {
  91. goPage(path) {
  92. this.$router.push(path)
  93. },
  94. logout() {
  95. window.localStorage.removeItem('token')
  96. window.localStorage.removeItem('authinfo')
  97. window.location.reload()
  98. },
  99. getData() {
  100. this.$api.getPatientLatestCase().then(res => {
  101. if (!res.data.code) {
  102. this.latestCase = res.data.data
  103. this.ratioHeight = 216/100*this.latestCase.FVIII
  104. }
  105. }),
  106. this.$api.getAccountInfo().then(res => {
  107. if (!res.data.code) {
  108. this.patinfo = res.data.data
  109. }
  110. })
  111. }
  112. },
  113. created() {
  114. this.getData()
  115. }
  116. }
  117. </script>
  118. <style scoped lang="scss">
  119. .container {
  120. .content {
  121. height: 100%;
  122. margin-top: 0px;
  123. }
  124. height: 100%;
  125. background: #fff;
  126. .bgcolor {
  127. width: 100%;
  128. height: 11rem;
  129. position: absolute;
  130. background: #016AFA;
  131. }
  132. .bgimg {
  133. width: 100%;
  134. height: 24.8rem;
  135. // border:1px solid red;
  136. /* top: 10rem; */
  137. position: absolute;
  138. /* z-index:-1; */
  139. background-image: url("../assets/images/infobg.png");
  140. background-size: 100% 100%;
  141. }
  142. .docinfo {
  143. position: absolute;
  144. top: 30%;
  145. left: 0;
  146. right: 0;
  147. .docavatar {
  148. border-radius: 60rem;
  149. }
  150. .docname {
  151. color: #fff;
  152. margin: 0.2rem;
  153. font-size: 1.2rem;
  154. }
  155. z-index:3;
  156. }
  157. .injectRecord {
  158. margin-top: 12.5rem;
  159. }
  160. .formTitle {
  161. height: 1rem;
  162. line-height: 1rem;
  163. color: #2882F4;
  164. padding-bottom: 0.5rem;
  165. font-weight: bold;
  166. font-size: 1.2rem;
  167. margin-top: 9rem;
  168. }
  169. .lrcontainer {
  170. display: flex;
  171. width: 90%;
  172. margin: auto;
  173. margin-top: 10px;
  174. height: 246px;
  175. .right {
  176. left: 30%;
  177. width: 60%;
  178. }
  179. .left {
  180. width: 30%;
  181. margin-top: 10px;
  182. position: relative;
  183. overflow: hidden;
  184. }
  185. .lritem {
  186. justify-content: space-between;
  187. /* height: 196px; */
  188. /* margin-left:1.6rem; */
  189. .ratioBg {
  190. width: 78px;
  191. position: absolute;
  192. left:0;
  193. right:0;
  194. bottom:20px;
  195. margin:auto;
  196. z-index:0;
  197. /* background:#2D9AF4; */
  198. background-image: url("../assets/images/test.png");
  199. background-size: 100% 100%;
  200. height: 100px;
  201. }
  202. .ratioBg1 {
  203. width: 80px;
  204. position: absolute;
  205. left:0;
  206. right:0;
  207. bottom:20px;
  208. margin:auto;
  209. z-index:-1;
  210. /* background:#64B3F6; */
  211. height: 216px;;
  212. }
  213. .ratioBg2 {
  214. width: 80px;
  215. position: absolute;
  216. left:0;
  217. right:0;
  218. bottom:20px;
  219. margin:auto;
  220. z-index:-1;
  221. /* background:#64B3F6; */
  222. /* height: 150px; */
  223. }
  224. .ratioBg3 {
  225. width: 80px;
  226. position: absolute;
  227. left:0;
  228. right:0;
  229. bottom:20px;
  230. margin:auto;
  231. z-index:1;
  232. /* background:#64B3F6; */
  233. height: 216px;;
  234. }
  235. .mint-cell {
  236. min-height: 2.0rem;
  237. }
  238. }
  239. }
  240. /deep/ .right .mint-cell .mint-cell-title {
  241. width: 70%;
  242. text-align: left;
  243. }
  244. /deep/ .right .mint-cell-wrapper {
  245. padding: 0px 20px;
  246. font-size: 1rem;
  247. background-size: 0px 0px;
  248. }
  249. .footer {
  250. margin-top: 60px;
  251. margin-bottom: 20px;
  252. }
  253. }
  254. </style>