Elizabeth's proactive approach involves introducing urinal toilet attachment , an ingenious concept that optimizes space and functionality.

dialysisIndex.vue 32KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996
  1. <template>
  2. <div class="main-contain">
  3. <div
  4. class="loadingBox"
  5. v-loading="loading"
  6. element-loading-text="拼命加载中"
  7. element-loading-spinner="el-icon-loading"
  8. element-loading-background="rgba(0, 0, 0, 0.8)"
  9. v-if="dialysisShow"
  10. >
  11. <div style="padding-top: 56px;width:100%;" >
  12. <nav-igation
  13. ref="nav"
  14. title="弹窗导航"
  15. @advice="adviceFunc"
  16. :patient="patient"
  17. :schedual="schedual"
  18. :prescription="prescription"
  19. :solution="solution"
  20. :receiver_treatment_access="receiver_treatment_access"
  21. :predialysis_evaluation="predialysis_evaluation"
  22. :doctor_advices="doctor_advices"
  23. :double_check="double_check"
  24. :assessment_after_dislysis="assessment_after_dislysis"
  25. :treatment_summary="treatment_summary"
  26. :monitor_records="monitor_records"
  27. :dialysis_order="dialysis_order"
  28. :admin_users="admin_users"
  29. :devices="devices"
  30. :device_numbers="device_numbers"
  31. :admin_user_map="admin_user_map"
  32. :device_map="device_map"
  33. :device_number_map="device_number_map"
  34. :niprocart_info="niprocart_info"
  35. :jms_info="jms_info"
  36. :fistula_needle_set_info="fistula_needle_set_info"
  37. :fistula_needle_set_16_info="fistula_needle_set_16_info"
  38. :hemoperfusion_info="hemoperfusion_info"
  39. :dialyser_sterilised_info="dialyser_sterilised_info"
  40. :filtryzer_info="filtryzer_info"
  41. :dialyzers_info="dialyzers_info"
  42. :injector_info="injector_info"
  43. :bloodlines_info="bloodlines_info"
  44. :tubingHemodialysis_info="tubingHemodialysis_info"
  45. :safe_package_info="safe_package_info"
  46. :aliquid_info="aliquid_info"
  47. :config="config"
  48. :longAdvices="longAdvices"
  49. :waitUploadAdvices="waitUploadAdvices"
  50. :is_open="is_open"
  51. :last_predialysis_evaluation="lastPredialysisEvaluation"
  52. :last_monitor_record="lastMonitorRecord"
  53. :last_assessment_after_dislysis="lastAssessmentAfterDislysis"
  54. :last_dialysis_prescribe="lastDialysisPrescribe"
  55. :last_dryWeight_dislysis="lastDryWeightDislysis"
  56. :special_premission="headNurses"
  57. @assessmentAfterDislysis="assessmentAfterDislysisFunc"
  58. :system_prescribe="system_prescribe"
  59. :his_is_open="his_is_open"
  60. :lastAssessment="lastAssessment"
  61. :stockType="stockType"
  62. :mode_id="mode_id"
  63. >
  64. </nav-igation>
  65. <basic-infor
  66. :patient="patient"
  67. :device_number="schedual.id == 0 ? '' : schedual.device_number.number"
  68. :steps="steps"
  69. title="基本信息"
  70. ></basic-infor>
  71. <dialysis-prescription
  72. :prescription="prescription"
  73. :solution="solution"
  74. :device_map="device_map"
  75. :preparestock="preparestock"
  76. title="透析处方"
  77. ></dialysis-prescription>
  78. <!-- <past-data class="往期数据"></past-data> -->
  79. <div style="height: 20px;background-color: #f6f8f9"></div>
  80. <accepts-assessment
  81. :record="receiver_treatment_access"
  82. title="接诊评估"
  83. ></accepts-assessment>
  84. <assessment-before
  85. :record="predialysis_evaluation"
  86. ref="assessment_before"
  87. title="透前评估"
  88. ></assessment-before>
  89. <stat-order
  90. ref="stat_order"
  91. :advices="doctor_advices"
  92. :doctor_map="admin_user_map"
  93. title="临时医嘱"
  94. ></stat-order>
  95. <double-check
  96. ref="double_check"
  97. :record="double_check"
  98. :admin_map="admin_user_map"
  99. title="双人核对 "
  100. ></double-check>
  101. <dialysis-computer
  102. ref="dialysis_computer"
  103. :record="dialysis_order"
  104. :admin_map="admin_user_map"
  105. :device_number_map="device_number_map"
  106. title="透析上机 "
  107. ></dialysis-computer>
  108. <dialysis-monitoring
  109. ref="monitoring"
  110. :monitores="monitor_records"
  111. title="透析监测"
  112. ></dialysis-monitoring>
  113. <dialysis-off
  114. ref="dialysis_off"
  115. :record="dialysis_order"
  116. :admin_map="admin_user_map"
  117. title="透析下机 "
  118. ></dialysis-off>
  119. <assessment-after
  120. ref="assessment_after"
  121. :record="assessment_after_dislysis"
  122. title="透后评估"
  123. ></assessment-after>
  124. <treatment-of
  125. ref="treatment_of"
  126. :record="treatment_summary"
  127. title="治疗小结"
  128. ></treatment-of>
  129. </div>
  130. </div>
  131. <div style="padding-top: 56px;width:100%;text-align:center;font-size:22px;color:red;" v-else>该患者未排班,请先去排班</div>
  132. </div>
  133. </template>
  134. <script>
  135. const moment = require('moment')
  136. import axios from 'axios'
  137. import NavIgation from '@/xt_pages/dialysis/details/NavIgation'
  138. import BasicInfor from '@/xt_pages/dialysis/details/BasicInfor'
  139. import DialysisPrescription from '@/xt_pages/dialysis/details/DialysisPrescription'
  140. import PastData from '@/xt_pages/dialysis/details/pastData'
  141. import AcceptsAssessment from '@/xt_pages/dialysis/details/acceptsAssessment'
  142. import AssessmentBefore from '@/xt_pages/dialysis/details/assessmentBefore'
  143. import StatOrder from '@/xt_pages/dialysis/details/statOrder'
  144. import DialysisComputer from '@/xt_pages/dialysis/details/dialysisComputer'
  145. import DoubleCheck from '@/xt_pages/dialysis/details/doubleCheck'
  146. import DialysisMonitoring from '@/xt_pages/dialysis/details/dialysisMonitoring'
  147. import DialysisOff from '@/xt_pages/dialysis/details/dialysisOff'
  148. import AssessmentAfter from '@/xt_pages/dialysis/details/assessmentAfter'
  149. import TreatmentOf from '@/xt_pages/dialysis/details/treatmentOf'
  150. import OperationStaff from '@/xt_pages/dialysis/details/operationStaff'
  151. import {
  152. getDialysisScheduleDetail,
  153. getLongAdvice,
  154. getDialysisRecordInitData,
  155. getDialysisSchedules
  156. } from '@/api/dialysis_record'
  157. import { parseTime } from '@/utils'
  158. import BreadCrumb from '@/xt_pages/components/bread-crumb'
  159. export default {
  160. name: 'index',
  161. components: {
  162. NavIgation,
  163. BasicInfor,
  164. DialysisPrescription,
  165. PastData,
  166. AcceptsAssessment,
  167. AssessmentBefore,
  168. StatOrder,
  169. DialysisComputer,
  170. DoubleCheck,
  171. DialysisMonitoring,
  172. DialysisOff,
  173. AssessmentAfter,
  174. TreatmentOf,
  175. OperationStaff,
  176. BreadCrumb
  177. },
  178. props:{
  179. record_date:String,
  180. patientid:Number,
  181. dialysisShow:Boolean
  182. },
  183. data() {
  184. return {
  185. crumbs: [
  186. { path: false, name: '透析管理' },
  187. { path: false, name: '透析记录' },
  188. { path: false, name: '透析单' }
  189. ],
  190. dialogFormVisible: false,
  191. orders: false,
  192. loading: false,
  193. patient_id: 0,
  194. date: 0,
  195. longAdvices: [],
  196. waitUploadAdvices: [],
  197. is_open: 0,
  198. targetAdvices: [],
  199. patient: { id: 0 }, // 患者信息
  200. schedual: { id: 0 }, // 患者排班信息
  201. prescription: { id: 0 }, // 透析处方
  202. solution: { id: 0 }, // 透析方案
  203. system_prescribe: { id: 0 },
  204. receiver_treatment_access: { id: 0 }, // 接诊评估
  205. predialysis_evaluation: { id: 0 }, // 透前评估
  206. doctor_advices: [], // 临时医嘱
  207. double_check: { id: 0 }, // 双人核对
  208. assessment_after_dislysis: { id: 0 }, // 透后评估
  209. treatment_summary: { id: 0 }, // 治疗小结
  210. monitor_records: [], // 透析监测
  211. dialysis_order: { id: 0 }, // 透析记录
  212. admin_users: [], // 系统用户列表
  213. devices: [], // 设备
  214. device_numbers: [], // 床位号
  215. admin_user_map: {}, // {user_id: admin_user object}
  216. device_map: {}, // {device_id: device}
  217. device_number_map: {}, // {device_number_id: device_number}
  218. niprocart_info: [],
  219. jms_info: [],
  220. fistula_needle_set_info: [],
  221. fistula_needle_set_16_info: [],
  222. hemoperfusion_info: [],
  223. dialyser_sterilised_info: [],
  224. filtryzer_info: [],
  225. dialyzers_info: [],
  226. injector_info: [],
  227. bloodlines_info: [],
  228. tubingHemodialysis_info: [],
  229. safe_package_info: [],
  230. aliquid_info: [],
  231. config: {},
  232. his_is_open:0,
  233. lastPredialysisEvaluation: { id: 0 },
  234. lastMonitorRecord: { id: 0 },
  235. lastAssessmentAfterDislysis: { id: 0 },
  236. lastDryWeightDislysis: { id: 0 },
  237. lastAssessment:{id:0},
  238. headNurses: [],
  239. lastDialysisPrescribe: { id: 0 },
  240. //
  241. activeName: 'first',
  242. selected_date: new Date(),
  243. // search_input 和 search_keyword,使输入关键字时不会经常刷新 filtedSchedules
  244. search_keyword: '', // 确定用于搜索的关键字
  245. search_input: '', // 输入中的关键字
  246. patient_state: [
  247. { value: 0, label: '全部患者' },
  248. { value: 1, label: '已签到' },
  249. { value: 2, label: '未签到' },
  250. { value: 3, label: '已上机' },
  251. { value: 4, label: '已下机' }
  252. ],
  253. patientStateVal: 0,
  254. treat_state: [
  255. { value: 0, label: '全部治疗' },
  256. { value: 1, label: '待开处方' },
  257. { value: 2, label: '待开小结' },
  258. { value: 3, label: '待医嘱核对' },
  259. ],
  260. treatStateVal: 0,
  261. schedule_options: [
  262. { value: 0, label: '全部班' },
  263. { value: 1, label: '上午' },
  264. { value: 2, label: '下午' },
  265. { value: 3, label: '晚上' }
  266. ],
  267. scheduleStateVal: 0,
  268. zone_options: [
  269. { id: 0, text: '全部分区' }
  270. ],
  271. zoneVal: 0,
  272. tableData: [],
  273. tableData1: [],
  274. arr: [],
  275. newName: '',
  276. newTime: '',
  277. scheudle_mode:"",
  278. showView:false,
  279. curPatient:{},
  280. queueConfig:{},
  281. stockType:[],
  282. preparestock:[],
  283. dialysisShow:false,
  284. mode_id:1
  285. }
  286. },
  287. created() {
  288. var patient_id = this.patientid
  289. var date = this.record_date
  290. this.patient_id = patient_id
  291. this.date = date
  292. var ymd = parseTime(new Date(), '{y}-{m}-{d}')
  293. getDialysisSchedules(ymd).then(rs => {
  294. var resp = rs.data
  295. if (resp.state == 1) {
  296. var schedules = resp.data.schedules
  297. let arr = []
  298. schedules.map(item => {
  299. if(item.patient_id == this.patient_id){
  300. arr.push(item.patient_id)
  301. console.log('item',item)
  302. this.mode_id = item.mode_id
  303. }
  304. })
  305. if(arr.length > 0){
  306. this.dialysisShow = true
  307. }else{
  308. this.dialysisShow = false
  309. }
  310. console.log('this.dialysisShowthis.dialysisShowthis.dialysisShow',this.dialysisShow)
  311. } else {
  312. this.$message.error(resp.msg)
  313. }
  314. })
  315. },
  316. mounted() {
  317. if(this.dialysisShow == true){
  318. this.getScheduleDetail()
  319. this.getLongAdvice()
  320. }
  321. },
  322. watch:{
  323. patientid:{
  324. handler(newVal){
  325. var ymd = parseTime(new Date(), '{y}-{m}-{d}')
  326. getDialysisSchedules(ymd).then(rs => {
  327. var resp = rs.data
  328. if (resp.state == 1) {
  329. var schedules = resp.data.schedules
  330. let arr = []
  331. schedules.map(item => {
  332. if(item.patient_id == this.patient_id){
  333. arr.push(item.patient_id)
  334. this.mode_id = item.mode_id
  335. }
  336. })
  337. if(arr.length > 0){
  338. this.dialysisShow = true
  339. }else{
  340. this.dialysisShow = false
  341. }
  342. console.log('this.dialysisShowthis.dialysisShowthis.dialysisShow',this.dialysisShow)
  343. } else {
  344. this.$message.error(resp.msg)
  345. }
  346. })
  347. console.log('执行执行执行执行执行执行',this.dialysisShow)
  348. if(this.dialysisShow == true){
  349. console.log('执行')
  350. this.patient_id = newVal
  351. this.getScheduleDetail()
  352. this.getLongAdvice()
  353. }
  354. },
  355. deep:true
  356. },
  357. },
  358. computed: {
  359. websocket() {
  360. return this.$store.state.user.websocket;
  361. },
  362. steps: function() {
  363. var steps = [
  364. { title: '透析处方', finish: false },
  365. { title: '接诊评估', finish: false },
  366. { title: '透前评估', finish: false },
  367. { title: '临时医嘱', finish: false },
  368. { title: '双人核对', finish: false },
  369. { title: '透析上机', finish: false },
  370. { title: '透析监测', finish: false },
  371. { title: '透析下机', finish: false },
  372. { title: '透后评估', finish: false },
  373. { title: '治疗小结', finish: false }
  374. ]
  375. steps[0].finish = this.prescription.id && this.prescription.creater > 0
  376. steps[1].finish = this.receiver_treatment_access.id > 0
  377. steps[2].finish =
  378. this.predialysis_evaluation.id > 0 &&
  379. this.predialysis_evaluation.creater > 0
  380. steps[3].finish = this.doctor_advices.length > 0
  381. steps[5].finish = this.dialysis_order.id > 0
  382. steps[7].finish =
  383. this.dialysis_order.id > 0 && this.dialysis_order.stage == 2
  384. steps[4].finish =
  385. this.double_check.id > 0 &&
  386. this.double_check.creater > 0 &&
  387. this.double_check.modifier > 0
  388. steps[6].finish = this.monitor_records.length > 0
  389. steps[8].finish =
  390. this.assessment_after_dislysis.id > 0 &&
  391. this.assessment_after_dislysis.creater > 0
  392. steps[9].finish = this.treatment_summary.id > 0
  393. return steps
  394. },
  395. filtedSchedules: function() {
  396. var search_keyword = this.search_keyword
  397. if (search_keyword.length > 0) {
  398. var schedules = []
  399. for (let o_i = 0; o_i < this.zone_schedules.length; o_i++) {
  400. const scheduleInfo = this.zone_schedules[o_i]
  401. var originSchedules = scheduleInfo.schedules
  402. if (originSchedules.length == 0) {
  403. continue
  404. }
  405. var filtedSchedules = []
  406. for (let s_i = 0; s_i < originSchedules.length; s_i++) {
  407. const schedule = originSchedules[s_i]
  408. if (schedule.patient.name.indexOf(search_keyword) != -1) {
  409. filtedSchedules.push(schedule)
  410. // break
  411. }
  412. }
  413. if (filtedSchedules.length > 0) {
  414. schedules.push({ zone_id: scheduleInfo.zone_id, zone_name: scheduleInfo.zone_name, schedules: filtedSchedules })
  415. }
  416. }
  417. return schedules
  418. }
  419. // var zone_selected = this.zoneVal
  420. // var timetype_selected = this.scheduleStateVal
  421. // if ((zone_selected == 0 && timetype_selected == 0) || this.zone_options.length <= 1) {
  422. // var schedules = []
  423. // for (let index = 0; index < this.zone_schedules.length; index++) {
  424. // const scheduleInfo = this.zone_schedules[index]
  425. // if (scheduleInfo.schedules.length != 0) {
  426. // schedules.push(scheduleInfo)
  427. // }
  428. // }
  429. // return schedules
  430. // }
  431. // var schedules = []
  432. // for (let o_i = 0; o_i < this.zone_schedules.length; o_i++) {
  433. // const scheduleInfo = this.zone_schedules[o_i]
  434. // if (zone_selected == scheduleInfo.zone_id && timetype_selected == 0) {
  435. // if (scheduleInfo.schedules.length == 0) {
  436. // return []
  437. // } else {
  438. // return [scheduleInfo]
  439. // }
  440. // }
  441. // var originSchedules = scheduleInfo.schedules
  442. // if (originSchedules.length == 0) {
  443. // continue
  444. // }
  445. // var filtedSchedules = []
  446. // for (let s_i = 0; s_i < originSchedules.length; s_i++) {
  447. // const schedule = originSchedules[s_i]
  448. // if (zone_selected != 0) {
  449. // if (zone_selected == schedule.device_number.zone.id) {
  450. // if (timetype_selected == 0 || schedule.schedule_type == timetype_selected) {
  451. // filtedSchedules.push(schedule)
  452. // }
  453. // }
  454. // } else {
  455. // if (timetype_selected == 0 || schedule.schedule_type == timetype_selected) {
  456. // filtedSchedules.push(schedule)
  457. // }
  458. // }
  459. // }
  460. // if (filtedSchedules.length > 0) {
  461. // schedules.push({ zone_id: scheduleInfo.zone_id, zone_name: scheduleInfo.zone_name, schedules: filtedSchedules })
  462. // }
  463. // }
  464. // return schedules
  465. }
  466. },
  467. methods: {
  468. adviceFunc() {
  469. this.getScheduleDetail()
  470. },
  471. getLongAdvice() {
  472. const params = {
  473. patient_id: this.patient_id
  474. }
  475. getLongAdvice(params).then(rs => {
  476. var resp = rs.data
  477. if (resp.state == 1) {
  478. var status = parseInt(resp.data.status)
  479. switch (status) {
  480. case 2:
  481. var totalAdvice = resp.data.advices
  482. var longAdvicesTwo = resp.data.advices_two
  483. var waitUploadAdvices = []
  484. for (let i = 0; i < totalAdvice.length; i++) {
  485. totalAdvice[i]['isCheck'] = 1
  486. }
  487. for (let i = 0; i < totalAdvice.length; i++) {
  488. for (let a = 0; a < longAdvicesTwo.length; a++) {
  489. if (
  490. totalAdvice[i].template_id ==
  491. longAdvicesTwo[a].template_id &&
  492. totalAdvice[i].frequency_type ==
  493. longAdvicesTwo[a].frequency_type
  494. ) {
  495. totalAdvice[i]['isCheck'] = 0
  496. }
  497. }
  498. }
  499. for (let i = 0; i < totalAdvice.length; i++) {
  500. if (totalAdvice[i].isCheck == 1) {
  501. waitUploadAdvices.push(totalAdvice[i])
  502. }
  503. }
  504. this.is_open = resp.data.is_open_remind
  505. if(this.his_is_open == 1){
  506. this.is_open = 0
  507. }
  508. this.longAdvices = totalAdvice
  509. this.waitUploadAdvices = waitUploadAdvices
  510. break
  511. }
  512. } else {
  513. this.$message.error(resp.msg)
  514. }
  515. })
  516. },
  517. assessmentAfterDislysisFunc: function(val) {
  518. for (var index in val) {
  519. this.$set(this.assessment_after_dislysis, index, val[index])
  520. }
  521. },
  522. didDelMonitor(record_id) {
  523. var mrl = this.monitor_records.length
  524. for (let index = 0; index < mrl; index++) {
  525. if (this.monitor_records[index].id == record_id) {
  526. this.monitor_records.splice(index, 1)
  527. break
  528. }
  529. }
  530. },
  531. getScheduleDetail: function() {
  532. this.loading = true
  533. // var dateStr = parseTime(this.date, '{y}-{m}-{d}')
  534. // if(this.$route.query.showView == true){
  535. // this.loading = false
  536. // return
  537. // }
  538. console.log('this.patient_id',this.patient_id)
  539. console.log('this.date',this.date)
  540. this.doctor_advices = []
  541. getDialysisScheduleDetail(this.patient_id, this.date).then(rs => {
  542. var resp = rs.data
  543. if (resp.state == 1) {
  544. var patient = resp.data.patient // 患者信息
  545. var schedual = resp.data.schedual // 患者排班信息
  546. var prescription = resp.data.prescription // 透析处方
  547. if (prescription != null) {
  548. if (prescription.body_fluid == -2) {
  549. prescription.body_fluid = 0
  550. }
  551. }
  552. var solution = resp.data.solution // 透析方案
  553. var receiver_treatment_access = resp.data.receiver_treatment_access // 接诊评估
  554. var predialysis_evaluation = resp.data.predialysis_evaluation // 透前评估
  555. console.log("透器评估",predialysis_evaluation)
  556. if (predialysis_evaluation != null) {
  557. if (predialysis_evaluation.blood_access_part_id == -2) {
  558. predialysis_evaluation.blood_access_part_id = 0
  559. }
  560. }
  561. var doctor_advices = resp.data.doctor_advices // 临时医嘱
  562. var double_check = resp.data.double_check // 双人核对
  563. var assessment_after_dislysis = resp.data.assessment_after_dislysis // 透后评估
  564. var treatment_summary = resp.data.treatment_summary // 治疗小结
  565. var monitor_records = resp.data.monitor_records // 透析监测
  566. var dialysis_order = resp.data.dialysis_order // 透析记录
  567. var niprocart_info = resp.data.niprocart_info
  568. var jms_info = resp.data.jms_info
  569. var fistula_needle_set_info = resp.data.fistula_needle_set_info
  570. var fistula_needle_set_16_info = resp.data.fistula_needle_set_16_info
  571. var hemoperfusion_info = resp.data.hemoperfusion_info
  572. var dialyser_sterilised_info = resp.data.dialyser_sterilised_info
  573. var filtryzer_info = resp.data.filtryzer_info
  574. var dialyzers_info = resp.data.dialyzers_info
  575. var injector_info = resp.data.injector_info
  576. var bloodlines_info = resp.data.bloodlines_info
  577. var tubingHemodialysis_info = resp.data.tubingHemodialysis_info
  578. var safe_package_info = resp.data.safe_package_info
  579. var aliquid_info = resp.data.aliquid_info
  580. var lastPredialysisEvaluation = resp.data.lastPredialysisEvaluation
  581. if (lastPredialysisEvaluation != null) {
  582. if (lastPredialysisEvaluation.blood_access_part_id == -2) {
  583. lastPredialysisEvaluation.blood_access_part_id = 0
  584. }
  585. }
  586. var lastMonitorRecord = resp.data.lastMonitorRecord
  587. var lastAssessmentAfterDislysis = resp.data.lastAssessmentAfterDislysis
  588. var lastDialysisPrescribe = resp.data.lastDialysisPrescribe
  589. var lastDryWeightDislysis = resp.data.lastDryWeightDislysis
  590. var system_prescribe = resp.data.system_prescribe
  591. var lastAssessment = resp.data.lastAssessment
  592. console.log("最后一次血管通路",lastAssessment)
  593. this.$refs.nav.setLastRecord(
  594. lastPredialysisEvaluation,
  595. lastMonitorRecord,
  596. lastAssessmentAfterDislysis,
  597. lastDialysisPrescribe,
  598. lastDryWeightDislysis,
  599. schedual,
  600. system_prescribe,
  601. lastAssessment,
  602. )
  603. var headNurses = resp.data.headNurse
  604. var config = resp.data.config
  605. this.lastPredialysisEvaluation = lastPredialysisEvaluation
  606. this.lastMonitorRecord = lastMonitorRecord
  607. this.lastAssessmentAfterDislysis = lastAssessmentAfterDislysis
  608. this.lastDialysisPrescribe = lastDialysisPrescribe
  609. this.lastDryWeightDislysis = lastDryWeightDislysis
  610. this.lastAssessment = lastAssessment
  611. this.headNurses = headNurses
  612. this.system_prescribe = system_prescribe
  613. this.niprocart_info = []
  614. this.jms_info = []
  615. this.fistula_needle_set_info = []
  616. this.fistula_needle_set_16_info = []
  617. this.hemoperfusion_info = []
  618. this.dialyser_sterilised_info = []
  619. this.filtryzer_info = []
  620. this.dialyzers_info = []
  621. this.injector_info = []
  622. this.bloodlines_info = []
  623. this.tubingHemodialysis_info = []
  624. this.safe_package_info = []
  625. this.aliquid_info = []
  626. this.niprocart_info = niprocart_info
  627. this.jms_info = jms_info
  628. this.fistula_needle_set_info = fistula_needle_set_info
  629. this.fistula_needle_set_16_info = fistula_needle_set_16_info
  630. this.hemoperfusion_info = hemoperfusion_info
  631. this.dialyser_sterilised_info = dialyser_sterilised_info
  632. this.filtryzer_info = filtryzer_info
  633. this.dialyzers_info = dialyzers_info
  634. this.injector_info = injector_info
  635. this.bloodlines_info = bloodlines_info
  636. this.tubingHemodialysis_info = tubingHemodialysis_info
  637. this.safe_package_info = safe_package_info
  638. this.aliquid_info = aliquid_info
  639. this.config = config
  640. this.patient = patient
  641. this.schedual = schedual == null ? { id: 0 } : schedual
  642. this.prescription = prescription == null ? { id: 0 } : prescription
  643. this.solution = solution == null ? { id: 0 } : solution
  644. this.receiver_treatment_access =
  645. receiver_treatment_access == null
  646. ? { id: 0 }
  647. : receiver_treatment_access
  648. this.predialysis_evaluation =
  649. predialysis_evaluation == null ? { id: 0 } : predialysis_evaluation
  650. this.doctor_advices = doctor_advices == null ? [] : doctor_advices
  651. this.double_check = double_check == null ? { id: 0 } : double_check
  652. this.assessment_after_dislysis =
  653. assessment_after_dislysis == null
  654. ? { id: 0 }
  655. : assessment_after_dislysis
  656. this.treatment_summary =
  657. treatment_summary == null ? { id: 0 } : treatment_summary
  658. this.monitor_records = monitor_records == null ? [] : monitor_records
  659. this.dialysis_order =
  660. dialysis_order == null ? { id: 0 } : dialysis_order
  661. this.admin_users = resp.data.doctors
  662. this.devices = resp.data.devices
  663. this.device_numbers = resp.data.device_numbers
  664. var his_doctor_advices = resp.data.his_advices
  665. this.his_is_open = resp.data.is_open_config.is_open
  666. console.log(this.his_is_open)
  667. var stockType = resp.data.stockType
  668. this.stockType = stockType
  669. console.log("stockTYPW",stockType)
  670. var prepare = resp.data.prepare
  671. this.preparestock = prepare
  672. console.log("prepare222222",prepare)
  673. for (let i = 0; i < this.doctor_advices.length; i++){
  674. this.doctor_advices[i]['origin'] = 1
  675. }
  676. if (his_doctor_advices != null) {
  677. for (let i = 0; i < his_doctor_advices.length; i++) {
  678. his_doctor_advices[i]['origin'] = 2
  679. his_doctor_advices[i]['way'] = 1
  680. this.doctor_advices.push(his_doctor_advices[i])
  681. }
  682. }
  683. const obj = {}
  684. this.doctor_advices = this.doctor_advices.reduce((cur, next) => {
  685. obj[next.id] ? '' : obj[next.id] = true && cur.push(next)
  686. return cur
  687. }, []) // 设置cur默认类型为数组,并且初始值为空的数组
  688. console.log(this.doctor_advices)
  689. var device_map = {}
  690. for (let index = 0; index < this.devices.length; index++) {
  691. const device = this.devices[index]
  692. device_map[device.id] = device
  693. }
  694. this.device_map = device_map
  695. var admin_map = {}
  696. for (let index = 0; index < this.admin_users.length; index++) {
  697. const admin = this.admin_users[index]
  698. admin_map[admin.id] = admin
  699. }
  700. this.admin_user_map = admin_map
  701. var device_number_map = {}
  702. for (let index = 0; index < this.device_numbers.length; index++) {
  703. const device_number = this.device_numbers[index]
  704. device_number_map[device_number.id] = device_number
  705. }
  706. this.device_number_map = device_number_map
  707. } else {
  708. // this.$message.error(resp.msg)
  709. console.log("报错提示")
  710. this.$message.error("该患者今日未排班,无法使用此模块,请先排班!")
  711. }
  712. if (this.lastDialysisPrescribe != null) {
  713. delete this.lastDialysisPrescribe.target_ultrafiltration
  714. }
  715. if (this.solution != null) {
  716. delete this.solution.target_ultrafiltration
  717. }
  718. if(this.predialysis_evaluation.id > 0){
  719. this.newTime = parseTime(this.predialysis_evaluation.created_time, '{h}:{i}')
  720. }
  721. this.loading = false
  722. })
  723. },
  724. printOrder() {
  725. var xtdate = parseTime(this.date, '{y}-{m}-{d}')
  726. this.$router.push(
  727. '/dialysis/print?xtdate=' + xtdate + '&xtno=' + this.patient.dialysis_no
  728. )
  729. },
  730. processedDialysisSchedules: function(schedules, zone_options) {
  731. var zoneMap = {}
  732. var scheduleMap = {}
  733. for (let z_i = 0; z_i < zone_options.length; z_i++) {
  734. const zone = zone_options[z_i]
  735. if (zone.id == 0) {
  736. continue
  737. }
  738. scheduleMap[zone.id] = []
  739. }
  740. for (let index = 0; index < schedules.length; index++) {
  741. const schedule = schedules[index]
  742. scheduleMap[schedule.device_number.zone.id].push(schedule)
  743. }
  744. var zone_schedules = []
  745. for (let index = 0; index < zone_options.length; index++) {
  746. const zone = zone_options[index]
  747. if (zone.id == 0) {
  748. continue
  749. }
  750. var schedules = scheduleMap[zone.id]
  751. zone_schedules.push({ zone_id: zone.id, zone_name: zone.text, schedules: schedules })
  752. }
  753. return zone_schedules
  754. },
  755. getTime(date){
  756. date = new Date(date * 1000)
  757. var Y = date.getFullYear() + '-';
  758. var M = (date.getMonth()+1 < 10 ? '0'+(date.getMonth()+1) : date.getMonth()+1);
  759. var D = (date.getDate() < 10 ? '0'+date.getDate() : date.getDate());
  760. var h = (date.getHours() < 10 ? '0'+date.getHours() : date.getHours());
  761. var m = (date.getMinutes() < 10 ? '0'+date.getMinutes() : date.getMinutes());
  762. var s = (date.getSeconds() < 10 ? '0'+date.getSeconds() : date.getSeconds());
  763. let strDate = h + ':' + m;
  764. return strDate;
  765. },
  766. getDates(time){
  767. return moment(time * 1000).format('HH:mm:ss')
  768. }
  769. }
  770. }
  771. </script>
  772. <style style="stylesheet/scss" lang="scss" scoped>
  773. .details-bg {
  774. background: #fff;
  775. margin: 0 15px;
  776. }
  777. .printForm {
  778. .title {
  779. font-size: 30px;
  780. font-weight: 500;
  781. text-align: center;
  782. line-height: 60px;
  783. }
  784. .info {
  785. ul {
  786. display: -webkit-box;
  787. display: -moz-box;
  788. display: -ms-flexbox;
  789. display: -webkit-flex;
  790. display: flex;
  791. align-items: center;
  792. -moz-box-sizing: border-box;
  793. -webkit-box-sizing: border-box;
  794. -o-box-sizing: border-box;
  795. -ms-box-sizing: border-box;
  796. box-sizing: border-box;
  797. -webkit-justify-content: space-around;
  798. -moz-justify-content: space-around;
  799. -ms-justify-content: space-around;
  800. -o-justify-content: space-around;
  801. justify-content: space-around;
  802. li {
  803. display: flex;
  804. box-sizing: border-box;
  805. justify-content: space-around;
  806. .name {
  807. }
  808. .InputBox {
  809. padding: 0;
  810. border: none;
  811. border-bottom: 1px #e5e5e5 solid;
  812. width: 60px;
  813. outline: none;
  814. }
  815. }
  816. }
  817. }
  818. .printTable {
  819. tr {
  820. padding: 2px;
  821. th {
  822. padding: 6px 4px;
  823. }
  824. td {
  825. padding: 6px 4px;
  826. }
  827. }
  828. }
  829. }
  830. .loadingBox{
  831. display: flex;
  832. .patientBox{
  833. background: #fff;
  834. }
  835. .tip1{
  836. background: #4fc7cb;
  837. border-radius: 5px;
  838. text-align: center;
  839. font-size: 12px;
  840. display: inline-block;
  841. width: 60px;
  842. color: #fff;
  843. }
  844. .tip2{
  845. background: #ee8556;
  846. border-radius: 5px;
  847. text-align: center;
  848. font-size: 12px;
  849. display: inline-block;
  850. width: 60px;
  851. color: #fff;
  852. }
  853. .tip3{
  854. background: #409eff;
  855. border-radius: 5px;
  856. text-align: center;
  857. font-size: 12px;
  858. display: inline-block;
  859. width: 60px;
  860. color: #fff;
  861. }
  862. .tip4{
  863. background: #a8b3ba;
  864. border-radius: 5px;
  865. text-align: center;
  866. font-size: 12px;
  867. display: inline-block;
  868. width: 60px;
  869. color: #fff;
  870. }
  871. .tip5{
  872. background: #7bce91;
  873. border-radius: 5px;
  874. text-align: center;
  875. font-size: 12px;
  876. display: inline-block;
  877. width: 60px;
  878. color: #fff;
  879. }
  880. }
  881. </style>
  882. <style lang="scss">
  883. .loadingBox{
  884. .el-loading-spinner{
  885. top:10%;
  886. }
  887. .el-button--small, .el-button--small.is-round{
  888. padding:9px 10px;
  889. }
  890. .el-date-editor{
  891. .el-input__inner{
  892. padding-right:0px;
  893. }
  894. }
  895. .el-table td, .el-table th{
  896. text-align: center;
  897. }
  898. .el-table .cell{
  899. padding: 0;
  900. }
  901. }
  902. </style>