血透系统pad前端

detailsInfo.vue 6.7KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279
  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. // patient: {
  73. // name: "",
  74. // gender: 1,
  75. // birthday: "",
  76. // dialysis_no: "",
  77. // device_number: "",
  78. // source: "",
  79. // admission_number: "",
  80. // },
  81. // device_number: {
  82. // number: "",
  83. // },
  84. steps: [
  85. { title: "透析处方" },
  86. { title: "接诊评估" },
  87. { title: "透前评估" },
  88. { title: "临时医嘱" },
  89. { title: "透析上机" },
  90. { title: "双人核对" },
  91. { title: "透析监测" },
  92. { title: "透析下机" },
  93. { title: "透后评估" },
  94. { title: "治疗小结" }
  95. ]
  96. };
  97. },
  98. props: {
  99. step_data: {
  100. type: Array
  101. },
  102. patient: {
  103. type: Object,
  104. default: function() {
  105. return {
  106. name: "",
  107. gender: 1,
  108. birthday: "",
  109. dialysis_no: "",
  110. // device_number: "",
  111. source: "",
  112. admission_number: ""
  113. };
  114. }
  115. },
  116. device_number: {
  117. type: String
  118. }
  119. },
  120. computed: {
  121. dialysis_date: function() {
  122. return parseTime(this.$route.query.date, "{y}/{m}/{d}");
  123. },
  124. age: function() {
  125. if (this.patient.age == 0) {
  126. return jsGetAge(parseTime(this.patient.birthday, "{y}-{m}-{d}"), "-");
  127. } else {
  128. return this.patient.age;
  129. }
  130. },
  131. source: function() {
  132. return this.patient.source == 1 ? "门诊" : "住院";
  133. }
  134. },
  135. methods: {
  136. // setPatientInfo(patient, device_number_name) {
  137. // if (patient == null) {
  138. // this.patient.name = ""
  139. // this.patient.gender = 1
  140. // this.patient.birthday = ""
  141. // this.patient.dialysis_no = ""
  142. // // this.patient.device_number = ""
  143. // this.patient.source = ""
  144. // this.patient.admission_number = ""
  145. // } else {
  146. // this.patient.name = patient.name
  147. // this.patient.gender = patient.gender
  148. // this.patient.birthday = parseTime(patient.birthday, "{y}/{m}/{d}")
  149. // this.patient.dialysis_no = patient.dialysis_no
  150. // this.device_number.number = device_number_name
  151. // this.patient.source = patient.source == 1 ? "门诊" : "住院"
  152. // this.patient.admission_number = patient.admission_number
  153. // }
  154. // }
  155. },
  156. created() {}
  157. };
  158. </script>
  159. <style rel="stylesheet/scss" lang="scss" scoped>
  160. .info {
  161. background: $text-color;
  162. ul {
  163. padding: 0.4rem 0.8rem;
  164. li {
  165. float: left;
  166. width: 25%;
  167. font-size: 0.34rem;
  168. height: 0.53rem;
  169. }
  170. }
  171. .ui-step {
  172. margin: 0 0 0.8rem 0;
  173. padding: 0.1rem 0 0 0;
  174. zoom: 1;
  175. background: #fff;
  176. .ui-step-tit {
  177. font-size: 0.24rem;
  178. text-align: center;
  179. color: #34495e;
  180. }
  181. .ui-step-ul {
  182. list-style: none;
  183. .ui-step-done {
  184. float: left;
  185. position: relative;
  186. -webkit-box-sizing: border-box;
  187. -moz-box-sizing: border-box;
  188. box-sizing: border-box;
  189. text-align: center;
  190. width: 10%;
  191. &:before,
  192. &:after {
  193. position: absolute;
  194. left: 0;
  195. top: 0.26rem;
  196. display: block;
  197. content: " ";
  198. width: 50%;
  199. height: 1px;
  200. background: #409eff;
  201. z-index: 1;
  202. }
  203. &:after {
  204. left: 50%;
  205. }
  206. &:first-child:before,
  207. &:last-child::after {
  208. width: 0;
  209. }
  210. .ui-step-title {
  211. color: #34495e;
  212. font-size: 0.34rem;
  213. font-weight: normal;
  214. @media only screen and (max-width: 415px) {
  215. width: 0.8rem;
  216. margin-left: 4px;
  217. }
  218. @media only screen and (min-width: 500px) {
  219. width: 1rem;
  220. margin-left: 10px;
  221. }
  222. }
  223. .ui-step-number {
  224. position: relative;
  225. display: inline-block;
  226. width: 0.45rem;
  227. height: 0.45rem;
  228. margin: 0.05rem 0;
  229. line-height: 0.22rem;
  230. background: #409eff;
  231. color: #fff;
  232. border-radius: 100%;
  233. -webkit-box-sizing: border-box;
  234. -moz-box-sizing: border-box;
  235. box-sizing: border-box;
  236. z-index: 2;
  237. border: 1px #409eff solid;
  238. i {
  239. position: absolute;
  240. left: 0.09rem;
  241. top: 0.1rem;
  242. width: 0.26rem;
  243. height: 0.14rem;
  244. border: 2px #fff solid;
  245. color: #fff;
  246. z-index: 9;
  247. border-top: none;
  248. border-right: none;
  249. transform: rotate(-45deg);
  250. -webkit-transform: rotate(-45deg);
  251. -moz-transform: rotate(-45deg);
  252. -ms-transform: rotate(-45deg);
  253. -o-transform: rotate(-45deg);
  254. }
  255. }
  256. }
  257. }
  258. }
  259. }
  260. .newWidth {
  261. li {
  262. @media only screen and (min-width: 375px) {
  263. width: 33.3% !important;
  264. }
  265. @media only screen and (max-width: 320px) {
  266. width: 33.3% !important;
  267. }
  268. @media only screen and (min-width: 667px) {
  269. width: 25% !important;
  270. }
  271. }
  272. }
  273. </style>