血透系统pad前端

detailsInfo.vue 5.8KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254
  1. <template>
  2. <div class="info">
  3. <h2 class="plateTitle">
  4. <span class="line"></span>
  5. <p>基本信息</p>
  6. <span class="line"></span>
  7. </h2>
  8. <div class="ui-step clearfix">
  9. <ul class="ui-step-ul">
  10. <li
  11. v-for="(item, index) in step_data"
  12. :key="index"
  13. class="ui-step-done"
  14. >
  15. <div
  16. class="ui-step-number"
  17. :style="
  18. item.value == 1
  19. ? ''
  20. : 'background:#fff;border: 1px $main-color solid;'
  21. "
  22. >
  23. <i :style="item.value == 1 ? '' : 'border:0;'" />
  24. </div>
  25. <div class="ui-step-title">{{ item.title }}</div>
  26. </li>
  27. </ul>
  28. </div>
  29. <ul class="clearfix newWidth">
  30. <li>
  31. <label>姓名 :</label>
  32. <span>{{ patient.name }}</span>
  33. </li>
  34. <li>
  35. <label>性别 :</label>
  36. <span>{{ patient.gender == 1 ? "男" : "女" }}</span>
  37. </li>
  38. <li>
  39. <label>年龄 :</label>
  40. <span>{{ age }}</span>
  41. </li>
  42. <li>
  43. <label>透析号 :</label>
  44. <span>{{ patient.dialysis_no }}</span>
  45. </li>
  46. <li>
  47. <label>床位号 :</label>
  48. <span>{{ device_number }}</span>
  49. </li>
  50. <li>
  51. <label>来源 :</label>
  52. <span>{{ source }}</span>
  53. </li>
  54. <li>
  55. <label>住院号 :</label>
  56. <span>{{ patient.admission_number }}</span>
  57. </li>
  58. <li>
  59. <label>透析日期 :</label>
  60. <span>{{ dialysis_date }}</span>
  61. </li>
  62. </ul>
  63. </div>
  64. </template>
  65. <script>
  66. import { parseTime } from "@/utils";
  67. import { jsGetAge } from "@/utils/tools";
  68. export default {
  69. name: "DetailsInfo",
  70. data() {
  71. return {
  72. steps: [
  73. { title: "透析处方" },
  74. { title: "接诊评估" },
  75. { title: "透前评估" },
  76. { title: "临时医嘱" },
  77. { title: "透析上机" },
  78. { title: "双人核对" },
  79. { title: "透析监测" },
  80. { title: "透析下机" },
  81. { title: "透后评估" },
  82. { title: "治疗小结" }
  83. ]
  84. };
  85. },
  86. props: {
  87. step_data: {
  88. type: Array
  89. },
  90. patient: {
  91. type: Object,
  92. default: function() {
  93. return {
  94. name: "",
  95. gender: 1,
  96. birthday: "",
  97. dialysis_no: "",
  98. // device_number: "",
  99. source: "",
  100. admission_number: ""
  101. };
  102. }
  103. },
  104. device_number: {
  105. type: String
  106. }
  107. },
  108. computed: {
  109. dialysis_date: function() {
  110. return parseTime(this.$route.query.date, "{y}/{m}/{d}");
  111. },
  112. age: function() {
  113. if (this.patient.age == 0) {
  114. return jsGetAge(parseTime(this.patient.birthday, "{y}-{m}-{d}"), "-");
  115. } else {
  116. return this.patient.age;
  117. }
  118. },
  119. source: function() {
  120. return this.patient.source == 1 ? "门诊" : "住院";
  121. }
  122. },
  123. methods: {
  124. },
  125. created() {}
  126. };
  127. </script>
  128. <style rel="stylesheet/scss" lang="scss" scoped>
  129. .info {
  130. background: $text-color;
  131. ul {
  132. padding: 0.4rem 0.8rem;
  133. li {
  134. float: left;
  135. width: 25%;
  136. font-size: 0.34rem;
  137. height: 0.53rem;
  138. }
  139. }
  140. .ui-step {
  141. margin: 0 0 0.8rem 0;
  142. padding: 0.1rem 0 0 0;
  143. zoom: 1;
  144. background: #fff;
  145. .ui-step-tit {
  146. font-size: 0.24rem;
  147. text-align: center;
  148. color: #34495e;
  149. }
  150. .ui-step-ul {
  151. list-style: none;
  152. .ui-step-done {
  153. float: left;
  154. position: relative;
  155. -webkit-box-sizing: border-box;
  156. -moz-box-sizing: border-box;
  157. box-sizing: border-box;
  158. text-align: center;
  159. width: 10%;
  160. &:before,
  161. &:after {
  162. position: absolute;
  163. left: 0;
  164. top: 0.26rem;
  165. display: block;
  166. content: " ";
  167. width: 50%;
  168. height: 1px;
  169. background: #409eff;
  170. z-index: 1;
  171. }
  172. &:after {
  173. left: 50%;
  174. }
  175. &:first-child:before,
  176. &:last-child::after {
  177. width: 0;
  178. }
  179. .ui-step-title {
  180. color: #34495e;
  181. font-size: 0.34rem;
  182. font-weight: normal;
  183. @media only screen and (max-width: 415px) {
  184. width: 0.8rem;
  185. margin-left: 4px;
  186. }
  187. @media only screen and (min-width: 415px) and (max-width: 767px) {
  188. width: 0.8rem;
  189. margin-left: 0.25rem;
  190. }
  191. @media only screen and (min-width: 768px) {
  192. width: 1rem;
  193. margin-left: 10px;
  194. }
  195. }
  196. .ui-step-number {
  197. position: relative;
  198. display: inline-block;
  199. width: 0.45rem;
  200. height: 0.45rem;
  201. margin: 0.05rem 0;
  202. line-height: 0.22rem;
  203. background: #409eff;
  204. color: #fff;
  205. border-radius: 100%;
  206. -webkit-box-sizing: border-box;
  207. -moz-box-sizing: border-box;
  208. box-sizing: border-box;
  209. z-index: 2;
  210. border: 1px #409eff solid;
  211. i {
  212. position: absolute;
  213. left: 0.09rem;
  214. top: 0.1rem;
  215. width: 0.26rem;
  216. height: 0.14rem;
  217. border: 2px #fff solid;
  218. color: #fff;
  219. z-index: 9;
  220. border-top: none;
  221. border-right: none;
  222. transform: rotate(-45deg);
  223. -webkit-transform: rotate(-45deg);
  224. -moz-transform: rotate(-45deg);
  225. -ms-transform: rotate(-45deg);
  226. -o-transform: rotate(-45deg);
  227. }
  228. }
  229. }
  230. }
  231. }
  232. }
  233. .newWidth {
  234. li {
  235. @media only screen and (min-width: 375px) {
  236. width: 33.3% !important;
  237. }
  238. @media only screen and (max-width: 320px) {
  239. width: 33.3% !important;
  240. }
  241. @media only screen and (min-width: 667px) {
  242. width: 25% !important;
  243. }
  244. }
  245. }
  246. </style>