血透系统pad前端

PrescriptionDialog.vue 72KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924
  1. <template>
  2. <div>
  3. <div v-if="isShowDialog" class="Dialog">
  4. <div class="DialogTit">
  5. <span @click="close()" class="iconfont">&#xe6e9;</span>
  6. <h1 class="name">透析处方</h1>
  7. <button @click="showmsgtip">{{patient.name}} [透析号 {{patient.dialysis_no}} ]</button>
  8. <span @click="commitInfo" class="success" v-if="isPermission()">完成</span>
  9. <span @click="commitInfo" class="success" v-if="!isPermission()"></span>
  10. </div>
  11. <div class="DialogContent" id="dialogTop">
  12. <div @click="showSubMenu('mode')" class="item" ref="mode" v-if="isShow('透析模式')">
  13. <label class="name" for="txms">透析模式</label>
  14. <div class="content">
  15. <span class="text" id="txms">{{GetModeByModeId(dialysisPrescription.mode_id)}}</span>
  16. <span class="iconfont">&#xe6f9;</span>
  17. </div>
  18. </div>
  19. <div class="item" @click="openPicker" v-if="isShow('透析时长')">
  20. <label class="name" for="txsc">透析时长</label>
  21. <div class="content">
  22. <span class="text" style="width: 100px">{{timeValue}}</span>
  23. <span class="iconfont">&#xe6f9;</span>
  24. </div>
  25. </div>
  26. <div class="item" v-if="isShow('血流量')">
  27. <label class="name" for="xll">血流量(ml/min)</label>
  28. <div class="content">
  29. <input type="tel" @focus="inputFocus" id="xll" v-model="dialysisPrescription.blood_flow_volume"/>
  30. </div>
  31. </div>
  32. <div class="item" v-if="isShow('目标超滤量')">
  33. <label class="name" for="mbcll" v-if="this.$store.getters.user.template_info.template_id == 6">目标超滤量(ml)</label>
  34. <label class="name" for="mbcll" v-if="this.$store.getters.user.template_info.template_id != 6">目标超滤量(L)</label>
  35. <div class="content">
  36. <input type="tel" @focus="inputFocus" id="mbcll" v-model="dialysisPrescription.target_ultrafiltration"/>
  37. </div>
  38. </div>
  39. <div @click="showSubMenu('dialysate_formulation')" class="item" ref="dialysate_formulation"
  40. v-if="isShow('透析液配方')">
  41. <label class="name" for="txypf">透析液配方</label>
  42. <div class="content">
  43. <span class="text"
  44. id="txypf">{{GetDialysateFormulationById(dialysisPrescription.dialysate_formulation)}}</span>
  45. <span class="iconfont">&#xe6f9;</span>
  46. </div>
  47. </div>
  48. <div @click="showSubMenu('anticoagulant')" class="item" ref="anticoagulant" v-if="isShow('抗凝剂')">
  49. <label class="name" for="knj">抗凝剂</label>
  50. <div class="content">
  51. <span class="text" id="knj">{{GetAnticoagulantById(dialysisPrescription.anticoagulant)}}</span>
  52. <span class="iconfont">&#xe6f9;</span>
  53. </div>
  54. </div>
  55. <div class="item" v-if="anticoagulant.shouji != -1&&isShow('首剂')">
  56. <label class="name" for="sj">首剂({{anticoagulant.shouji_unit}})</label>
  57. <div class="content">
  58. <input type="tel" @focus="inputFocus" id="sj" v-model="dialysisPrescription.anticoagulant_shouji"
  59. :disabled="anticoagulant.shouji==1?false:true"/>
  60. </div>
  61. </div>
  62. <div class="item" v-if="anticoagulant.weichi != -1&&isShow('维持')">
  63. <label class="name" for="wz">维持({{anticoagulant.weichi_unit}})</label>
  64. <div class="content">
  65. <input type="tel" @focus="inputFocus" id="wz" class="inputBox"
  66. v-model="dialysisPrescription.anticoagulant_weichi"
  67. :disabled="anticoagulant.weichi==1?false:true">
  68. </div>
  69. </div>
  70. <div class="item" v-if="anticoagulant.zongliang != -1 && isShow('总量')">
  71. <label class="name" for="zl" v-if="dialysisPrescription.anticoagulant == 2">总量(mg)</label>
  72. <label class="name" for="zl" v-if="dialysisPrescription.anticoagulant == 3">总量(IU)</label>
  73. <label class="name" for="zl" v-if="dialysisPrescription.anticoagulant == 4">总量(mg)</label>
  74. <label class="name" for="zl" v-if="dialysisPrescription.anticoagulant == 5">总量(mg)</label>
  75. <label class="name" for="zl" v-if="dialysisPrescription.anticoagulant == 1">总量(mg)</label>
  76. <div class="content">
  77. <input type="tel" @focus="inputFocus" id="zl" class="inputBox"
  78. v-model="dialysisPrescription.anticoagulant_zongliang"
  79. :disabled="anticoagulant.zongliang==1?false:true">
  80. </div>
  81. </div>
  82. <div class="item" v-if="anticoagulant.gaimingcheng != -1 && isShow('钙名称')">
  83. <label class="name" for="g">钙名称({{anticoagulant.gaimingcheng_unit}})</label>
  84. <div class="content">
  85. <input type="text" id="g" class="inputBox" v-model="dialysisPrescription.anticoagulant_gaimingcheng"
  86. :disabled="anticoagulant.gaimingcheng==1?false:true">
  87. </div>
  88. </div>
  89. <div class="item" v-if="anticoagulant.gaijiliang != -1 && isShow('钙剂量')">
  90. <label class="name" for="gjl">钙剂量</label>
  91. <div class="content">
  92. <input type="text" id="gjl" class="inputBox" v-model="dialysisPrescription.anticoagulant_gaimingcheng"
  93. :disabled="anticoagulant.gaimingcheng==1?false:true">
  94. </div>
  95. </div>
  96. <!-- <div class="item">
  97. <label class="name" for="gtz">干体重(kg)</label>
  98. <div class="content">
  99. <input type="tel" @focus="inputFocus" id="gtz" v-model="dialysisPrescription.dry_weight"/>
  100. </div>
  101. </div> -->
  102. <div class="line"></div>
  103. <div class="item" v-if="isShow('置换量')">
  104. <label class="name" for="zhy">置换量(L)</label>
  105. <div class="content">
  106. <input type="tel" @focus="inputFocus" id="zhy" v-model="dialysisPrescription.replacement_total"/>
  107. </div>
  108. </div>
  109. <!-- <div class="line"></div> -->
  110. <div class="item" v-if="isShow('钾')">
  111. <label class="name" for="j">钾(mmol/L)</label>
  112. <div class="content">
  113. <input type="tel" @focus="inputFocus" id="j" v-model="dialysisPrescription.kalium"/>
  114. </div>
  115. </div>
  116. <div class="item" v-if="isShow('钠')">
  117. <label class="name" for="n">钠(mmol/L):</label>
  118. <div class="content">
  119. <input type="tel" @focus="inputFocus" id="n" v-model="dialysisPrescription.sodium"/>
  120. </div>
  121. </div>
  122. <div class="item" v-if="isShow('钙')">
  123. <label class="name" for="gg">钙(mmol/L)</label>
  124. <div class="content">
  125. <input type="tel" @focus="inputFocus" id="gg" v-model="dialysisPrescription.calcium"/>
  126. </div>
  127. </div>
  128. <div class="item" v-if="isShow('碳酸氢盐')">
  129. <label class="name" for="tsqy">碳酸氢盐(mmol/L)</label>
  130. <div class="content">
  131. <input type="tel" @focus="inputFocus" id="tsqy" v-model="dialysisPrescription.bicarbonate"/>
  132. </div>
  133. </div>
  134. <div class="item" v-if="isShow('葡萄糖')">
  135. <label class="name" for="ptt">葡萄糖(mmol/L)</label>
  136. <div class="content">
  137. <input type="tel" @focus="inputFocus" id="ptt" v-model="dialysisPrescription.glucose"/>
  138. </div>
  139. </div>
  140. <div class="line"></div>
  141. <div class="item" v-if="isShow('透析液流量')">
  142. <label class="name" for="txyll">透析液流量(ml/min)</label>
  143. <div class="content">
  144. <input type="tel" @focus="inputFocus" id="txyll" v-model="dialysisPrescription.dialysate_flow"/>
  145. </div>
  146. </div>
  147. <div class="item" v-if="isShow('透析液温度')">
  148. <label class="name" for="txywd">透析液温度(℃)</label>
  149. <div class="content">
  150. <!--<span class="text">HD</span>-->
  151. <!--<span class="iconfont">&#xe6f9;</span>-->
  152. <input type="tel" @focus="inputFocus" id="txywd" v-model="dialysisPrescription.dialysate_temperature"/>
  153. </div>
  154. </div>
  155. <div class="item" v-if="isShow('电导度')">
  156. <label class="name" for="dtl">电导度(mS/m)</label>
  157. <div class="content">
  158. <input type="tel" @focus="inputFocus" id="dtl" v-model="dialysisPrescription.conductivity"/>
  159. </div>
  160. </div>
  161. <div class="item" v-if="isShow('透析器/灌流器')">
  162. <label class="name" for="dtl">透析器/灌流器</label>
  163. <div class="content">
  164. <input @focus="inputFocus" id="dt" v-model="dialysisPrescription.dialyzer_perfusion_apparatus"/>
  165. </div>
  166. </div>
  167. <div class="line"></div>
  168. <div @click="showSubMenu('body_fluid')" class="item" ref="body_fluid" v-if="isShow('体液过多症状')">
  169. <label class="name" for="knj">体液过多症状</label>
  170. <div class="content">
  171. <span class="text" id="knja">{{getBodyFluid(dialysisPrescription.body_fluid)}}</span>
  172. <span class="iconfont">&#xe6f9;</span>
  173. </div>
  174. </div>
  175. <div class="item" v-if="isShow('体液过多其他症状')">
  176. <label class="name" for="knj">体液过多其他症状</label>
  177. <div class="content">
  178. <input @focus="inputFocus" id="dt" v-model="dialysisPrescription.body_fluid_other"/>
  179. </div>
  180. </div>
  181. <div @click="showSubMenu('special_medicine')" class="item" ref="special_medicine" v-if="isShow('透析前使用特殊药物')">
  182. <label class="name" for="knj">透析前使用特殊药物</label>
  183. <div class="content">
  184. <span class="text" id="knjaa">{{getSpecialMedicine(dialysisPrescription.special_medicine)}}</span>
  185. <span class="iconfont">&#xe6f9;</span>
  186. </div>
  187. </div>
  188. <div class="item" v-if="isShow('透析前使用其他特殊药物')">
  189. <label class="name" for="knj">透析前使用其他特殊药物</label>
  190. <div class="content">
  191. <input @focus="inputFocus" id="dt" v-model="dialysisPrescription.special_medicine_other"/>
  192. </div>
  193. </div>
  194. <div @click="showSubMenu('displace_liqui_part')" class="item" ref="displace_liqui_part" v-if="isShow('置换液')">
  195. <label class="name" for="knj" v-if="this.$store.getters.user.template_info.template_id == 6">置换方式</label>
  196. <label class="name" for="knj" v-if="this.$store.getters.user.template_info.template_id != 6">置换液</label>
  197. <div class="content">
  198. <span class="text" id="knjaa">{{getDisplaceLiquiPart(dialysisPrescription.displace_liqui_part)}}</span>
  199. <span class="iconfont">&#xe6f9;</span>
  200. </div>
  201. </div>
  202. <div class="item" v-if="isShow('置换液总量')">
  203. <label class="name" for="knj">置换液总量(L)</label>
  204. <div class="content">
  205. <input @focus="inputFocus" id="dt" v-model="dialysisPrescription.displace_liqui_value"/>
  206. </div>
  207. </div>
  208. <div class="item" v-if="isShow('目标KT/V')">
  209. <label class="name" for="knj">目标KT/V</label>
  210. <div class="content">
  211. <input @focus="inputFocus" id="dt" v-model="dialysisPrescription.target_ktv"/>
  212. </div>
  213. </div>
  214. <div @click="showSubMenu('blood_access')" class="item" ref="blood_access" v-if="isShow('血管通路')">
  215. <label class="name" for="knj">血管通路</label>
  216. <div class="content">
  217. <span class="text" id="knjaa">{{getBloodAccess(dialysisPrescription.blood_access)}}</span>
  218. <span class="iconfont">&#xe6f9;</span>
  219. </div>
  220. </div>
  221. <div class="item" v-if="isShow('实际超滤量')">
  222. <label class="name" for="knj">实际超滤量(L)</label>
  223. <div class="content">
  224. <input @focus="inputFocus" id="dt" v-model="dialysisPrescription.ultrafiltration"/>
  225. </div>
  226. </div>
  227. <div @click="dialysisGoodsClick()" class="item" ref="consumable_material" v-if="config.is_open == 1">
  228. <label class="name" for="knj">透析耗材</label>
  229. <div class="content">
  230. <span class="text" id="knjaa"></span>
  231. <span class="iconfont">&#xe6f9;</span>
  232. </div>
  233. </div>
  234. <div class="item" style="display: none">
  235. <label class="name" for="dtl">医生签名</label>
  236. <div class="content">
  237. <div v-if="isShowDesc">医生尚未签名</div>
  238. <img v-if="isShowDoctorSign" style="width: 100px;height: 30px" :src="signUrl"
  239. alt="" srcset="">
  240. </div>
  241. </div>
  242. <div class="line"></div>
  243. <div>
  244. <div class="item">
  245. <label class="name" for="bz">备注</label>
  246. <div class="content">
  247. <span class="text"></span>
  248. </div>
  249. </div>
  250. <textarea class="textarea" id="bz" placeholder="请输入内容" v-model="dialysisPrescription.remark"
  251. @focus="lastInputFocus" @blur="lastInputBlur"></textarea>
  252. </div>
  253. <!--<div class="footer">-->
  254. <!--处方医生:刘小军 医生-->
  255. <!--</div>-->
  256. <div class="PrescSubmit">
  257. <button style="display: none" class="tj" @click="sign()">医生签名</button>
  258. <button class="tjcq" @click="commitSolutionInfo" v-if="isPermission()">保存并设为长期处方</button>
  259. <button class="tj" @click="commitInfo" v-if="isPermission()">保存</button>
  260. </div>
  261. </div>
  262. </div>
  263. <!--<two-menu title="二级菜单" v-show="isShowModeSubMenu"></two-menu>-->
  264. <check-box-sub-menu :visibility="visibility" v-on:menu-cancle="menuCancle" v-on:menu-comfirm="menuComfirm"
  265. v-on:menu-empty="menuEmpty"
  266. :propsForm="propForm"></check-box-sub-menu>
  267. <!--<multiple-sub-menu :goodTypes="types" :visibility="is_show" v-on:menu-cancle="menuCancle" v-on:menu-comfirm="menuComfirm" :propsForm="propForm"></multiple-sub-menu>-->
  268. <multiple-sub-menu :goodTypes="types" :info="info" :visibility="is_show" v-on:menu-cancel-two="menuCancleTwo"
  269. v-on:menu-comfirm-two="menuComfirmTwo" :propsForm="propForm"
  270. :dialysisPrescription="dialysisPrescription"></multiple-sub-menu>
  271. <mt-datetime-picker
  272. ref="picker"
  273. type="time"
  274. hourFormat="{value}小时"
  275. minuteFormat="{value}分钟"
  276. @confirm="handleTimeConfirm"
  277. v-model="time">
  278. </mt-datetime-picker>
  279. <long-advice-sub-menu :visibility="advice_visibility" v-on:menu-cancle-three="menuCancleThree"
  280. v-on:menu-comfirm-three="menuComfirmThree" :propsForm="advicePropForm"></long-advice-sub-menu>
  281. <msg-tip style="width:500px;" :visibility="msgtip_visibility" :predialysis="predialysis"
  282. :last_predialysis="last_predialysis"
  283. :record="record"
  284. :last_record="last_record"
  285. :patient_prop="patient"
  286. :prescription_prop="prescription_prop"
  287. v-on:menu-msg-tip="menuMsgTip"></msg-tip>
  288. </div>
  289. </template>
  290. <script>
  291. import CheckBoxSubMenu from './subMenu/checkBoxSubMenu'
  292. import MultipleSubMenu from './subMenu/multipleSubMenu'
  293. import {commitDialysisPrescription, CreateGroupAdvice, postSign, postSolution} from '@/api/dialysis'
  294. import {Toast} from 'vant'
  295. import {getDataConfig} from '@/utils/data'
  296. import {parseTime} from '@/utils'
  297. import LongAdviceSubMenu from './subMenu/LongAdviceSubMenu'
  298. import MsgTip from './subMenu/MsgTip'
  299. export default {
  300. name: 'PrescriptionDialog',
  301. props: {
  302. admin_users_prop: {
  303. type: Array,
  304. default: function () {
  305. return new Array()
  306. }
  307. },
  308. predialysis: {
  309. type: Object
  310. },
  311. last_predialysis: {
  312. type: Object
  313. },
  314. record: {
  315. type: Object
  316. },
  317. last_record: {
  318. type: Object
  319. },
  320. patient_prop: {
  321. type: Object
  322. },
  323. solution_prop: {
  324. type: Object
  325. },
  326. config: {
  327. type: Object
  328. },
  329. operators: {
  330. type: Array,
  331. default: function () {
  332. return new Array()
  333. }
  334. },
  335. types: {
  336. type: Array,
  337. default: function () {
  338. return new Array()
  339. }
  340. },
  341. info: {
  342. type: Array,
  343. default: function () {
  344. return new Array()
  345. }
  346. },
  347. prescription_prop: {
  348. type: Object,
  349. }, is_open: {
  350. type: Number,
  351. }, targetAdvices: {
  352. type: Array,
  353. default: function () {
  354. return new Array()
  355. }
  356. }, waitUploadAdvices: {
  357. type: Array,
  358. default: function () {
  359. return new Array()
  360. }
  361. },
  362. machines_prop: {
  363. type: Array,
  364. default: function () {
  365. return new Array()
  366. }
  367. }
  368. },
  369. data () {
  370. return {
  371. is_pre: 0,
  372. loading: false,
  373. signUrl: '',
  374. isShowDesc: true,
  375. advice_visibility: false,
  376. msgtip_visibility: false,
  377. time: '03:00',
  378. timeValue: '',
  379. isShowSign: false,
  380. anticoagulantsConfit: {},
  381. dialysateFormulationOptions: [],
  382. bodyFluidOptions: [],
  383. specialMedicineOptions: [],
  384. displaceLiquiPartOptions: [],
  385. bloodAccessOptions: [],
  386. advicePropForm: {
  387. list: [],
  388. result: [],
  389. operators: [],
  390. },
  391. is_show: false,
  392. perfusion_apparatus: {},
  393. replacementWays: [],
  394. dialyserList: [],
  395. modeOption: [],
  396. isShowDoctorBtn: true,
  397. isShowDoctorSign: false,
  398. visibility: false,
  399. isShowDialog: true,
  400. isShowModeSubMenu: false,
  401. dialysisPrescription: {
  402. mode_id: '',
  403. dialysis_duration: '',
  404. dialysis_duration_hour: '',
  405. dialysis_duration_minute: '',
  406. mode_name: '',
  407. dialyzer: '',
  408. perfusion_apparatus: '',
  409. blood_flow_volume: '',
  410. dewater_amount: '',
  411. displace_liqui: '',
  412. replacement_total: '',
  413. replacement_way: '',
  414. anticoagulant: '',
  415. anticoagulant_shouji: '',
  416. anticoagulant_weichi: '',
  417. anticoagulant_zongliang: '',
  418. anticoagulant_gaimingcheng: '',
  419. anticoagulant_gaijiliang: '',
  420. dialyzer_perfusion_apparatus: '',
  421. kalium: '',
  422. sodium: '',
  423. calcium: '',
  424. bicarbonate: '',
  425. glucose: '',
  426. prescription_doctor: '',
  427. // dry_weight: "",
  428. dialysate_flow: '',
  429. dialysate_temperature: '',
  430. target_ultrafiltration: '',
  431. dialysate_formulation: '',
  432. conductivity: '',
  433. doctor: '',
  434. remark: '',
  435. body_fluid: '',
  436. special_medicine: '',
  437. special_medicine_other: '',
  438. displace_liqui_part: '',
  439. displace_liqui_value: '',
  440. blood_access: '',
  441. ultrafiltration: '',
  442. body_fluid_other: '',
  443. niprocart: '',
  444. jms: '',
  445. fistula_needle_set: '',
  446. fistula_needle_set_16: '',
  447. hemoperfusion: '',
  448. dialyser_sterilised: '',
  449. filtryzer: '',
  450. target_ktv: '',
  451. dialyzers: '',
  452. injector: '',
  453. bloodlines: '',
  454. tubing_hemodialysis: '',
  455. package: '',
  456. a_liquid: '',
  457. creater: '',
  458. modifier: '',
  459. },
  460. anticoagulant: {
  461. id: 0,
  462. name: '',
  463. type: 1,
  464. shouji: 1,
  465. weichi: 1,
  466. zongliang: 1,
  467. gaimingcheng: -1,
  468. gaijiliang: -1,
  469. shouji_unit: 'mg',
  470. weichi_unit: 'mg/h',
  471. zongliang_unit: 'mg',
  472. gaimingcheng_unit: '',
  473. gaijiliang_unit: ''
  474. },
  475. zhiShow: true,
  476. totalShow: true,
  477. huShow: true,
  478. doctorAdvices: [],
  479. propForm: {
  480. title: '',
  481. list: [],
  482. optionList: [],
  483. isMultiple: 2,
  484. result: [], //选中的值
  485. type: 1, //用来区分不同子菜单,方便对返回值进行赋值
  486. selectId: 0
  487. }
  488. }
  489. },computed: {
  490. // 计算属性的 getter
  491. }, methods: {
  492. showmsgtip () {
  493. this.msgtip_visibility = true
  494. this.isShowDialog = false
  495. },
  496. isPermission () {
  497. if (this.$store.getters.user.user.user_type == 3 && (this.$store.getters.user.template_info.template_id == 2 || this.$store.getters.user.template_info.template_id == 6)) {
  498. return false
  499. } else {
  500. return true
  501. }
  502. },
  503. isShow (name) {
  504. var filedList = this.$store.getters.user.fileds
  505. for (let i = 0; i < filedList.length; i++) {
  506. if (filedList[i].module == 1 && filedList[i].filed_name_cn == name && filedList[i].is_show == 1) {
  507. return true
  508. }
  509. }
  510. return false
  511. },
  512. openPicker: function () {
  513. this.$refs.picker.open()
  514. },
  515. handleTimeConfirm: function (val) {
  516. val = val.replace('小时')
  517. val = val.replace('分钟')
  518. let timeArray = val.split(':')
  519. if (parseInt(timeArray[0].substring(0, 1)) == 0) {
  520. this.dialysisPrescription.dialysis_duration_hour = timeArray[0].charAt(timeArray[0].length - 1)
  521. } else {
  522. this.dialysisPrescription.dialysis_duration_hour = timeArray[0]
  523. }
  524. if (parseInt(timeArray[1].substring(0, 1)) == 0) {
  525. this.dialysisPrescription.dialysis_duration_minute = timeArray[1].charAt(timeArray[1].length - 1)
  526. } else {
  527. this.dialysisPrescription.dialysis_duration_minute = timeArray[1]
  528. }
  529. this.timeValue = this.dialysisPrescription.dialysis_duration_hour + '小时' + this.dialysisPrescription.dialysis_duration_minute + '分钟'
  530. this.dialysisPrescription.dialysis_duration = this.dialysisPrescription.dialysis_duration_hour + '.' + (this.dialysisPrescription.dialysis_duration_minute)
  531. },
  532. inputFocus: function (event) {
  533. var input = event.target
  534. setTimeout(function () {
  535. input.scrollIntoView()
  536. }, 0)
  537. if (input.setSelectionRange) {
  538. setTimeout(function () {
  539. input.setSelectionRange(0, input.value.length)
  540. }, 0)
  541. } else if (input.createTextRange) {
  542. var rng = input.createTextRange()
  543. rng.move('character', input.value.length)
  544. rng.select()
  545. }
  546. },
  547. lastInputFocus: function (event) {
  548. var input = event.target
  549. setTimeout(function () {
  550. input.style.marginBottom = '2rem'
  551. input.parentNode.scrollIntoView()
  552. }, 0)
  553. },
  554. lastInputBlur: function (event) {
  555. var input = event.target
  556. setTimeout(function () {
  557. input.style.marginBottom = ''
  558. }, 0)
  559. },
  560. showSubMenu: function (val) {
  561. switch (val) {
  562. case 'mode':
  563. this.propForm.type = 1
  564. this.isShowDialog = false
  565. this.propForm.title = '透析模式'
  566. this.visibility = true
  567. this.propForm.list = []
  568. this.propForm.optionList = this.modeOption
  569. this.propForm.isMultiple = 1
  570. this.propForm.selectId = this.dialysisPrescription.mode_id
  571. this.propForm.click_ref = 'mode'
  572. break
  573. case 'dialyzer':
  574. this.propForm.type = 2
  575. this.isShowDialog = false
  576. this.propForm.title = '透析器'
  577. this.visibility = true
  578. this.propForm.list = []
  579. this.propForm.optionList = this.machines_prop
  580. this.propForm.isMultiple = 1
  581. this.propForm.selectId = this.dialysisPrescription.dialyzer
  582. this.propForm.click_ref = 'dialyzer'
  583. break
  584. case 'perfusion_apparatus':
  585. this.propForm.type = 3
  586. this.isShowDialog = false
  587. this.propForm.title = '灌流器'
  588. this.visibility = true
  589. this.propForm.list = []
  590. this.propForm.optionList = this.perfusion_apparatus
  591. this.propForm.isMultiple = 1
  592. this.propForm.selectId = this.dialysisPrescription.perfusion_apparatus
  593. this.propForm.click_ref = 'perfusion_apparatus'
  594. break
  595. case 'replacement_way':
  596. this.propForm.type = 4
  597. this.isShowDialog = false
  598. this.propForm.title = '置换方式'
  599. this.visibility = true
  600. this.propForm.list = []
  601. this.propForm.optionList = this.replacementWays
  602. this.propForm.isMultiple = 1
  603. this.propForm.selectId = this.dialysisPrescription.replacement_way
  604. this.propForm.click_ref = 'replacement_way'
  605. break
  606. case 'anticoagulant':
  607. this.propForm.type = 5
  608. this.isShowDialog = false
  609. this.propForm.title = '抗疑剂'
  610. this.visibility = true
  611. this.propForm.list = []
  612. this.propForm.optionList = this.anticoagulantsConfit
  613. this.propForm.isMultiple = 1
  614. this.propForm.selectId = this.dialysisPrescription.anticoagulant
  615. this.propForm.click_ref = 'anticoagulant'
  616. break
  617. case 'dialysate_formulation':
  618. this.propForm.type = 6
  619. this.isShowDialog = false
  620. this.propForm.title = '透析液配方'
  621. this.visibility = true
  622. this.propForm.list = []
  623. this.propForm.optionList = this.dialysateFormulationOptions
  624. this.propForm.isMultiple = 1
  625. this.propForm.selectId = this.dialysisPrescription.dialysate_formulation
  626. this.propForm.click_ref = 'dialysate_formulation'
  627. break
  628. case 'body_fluid':
  629. this.propForm.type = 7
  630. this.isShowDialog = false
  631. this.propForm.title = '体液过多症状'
  632. this.visibility = true
  633. this.propForm.list = []
  634. this.propForm.optionList = this.bodyFluidOptions
  635. this.propForm.isMultiple = 1
  636. this.propForm.selectId = this.dialysisPrescription.body_fluid
  637. this.propForm.click_ref = 'body_fluid'
  638. break
  639. case 'special_medicine':
  640. this.propForm.type = 8
  641. this.isShowDialog = false
  642. this.propForm.title = '透析前使用特殊药物'
  643. this.visibility = true
  644. this.propForm.list = []
  645. this.propForm.optionList = this.specialMedicineOptions
  646. this.propForm.isMultiple = 1
  647. this.propForm.selectId = this.dialysisPrescription.special_medicine
  648. this.propForm.click_ref = 'special_medicine'
  649. break
  650. case 'displace_liqui_part':
  651. this.propForm.type = 9
  652. this.isShowDialog = false
  653. this.propForm.title = '置换液'
  654. this.visibility = true
  655. this.propForm.list = []
  656. this.propForm.optionList = this.displaceLiquiPartOptions
  657. this.propForm.isMultiple = 1
  658. this.propForm.selectId = this.dialysisPrescription.displace_liqui_part
  659. this.propForm.click_ref = 'displace_liqui_part'
  660. break
  661. case 'blood_access':
  662. this.propForm.type = 10
  663. this.isShowDialog = false
  664. this.propForm.title = '血管通路'
  665. this.visibility = true
  666. this.propForm.list = []
  667. this.propForm.optionList = this.bloodAccessOptions
  668. this.propForm.isMultiple = 1
  669. this.propForm.selectId = this.dialysisPrescription.blood_access
  670. this.propForm.click_ref = 'blood_access'
  671. break
  672. }
  673. },
  674. menuCancle: function () {
  675. this.visibility = false
  676. this.isShowDialog = true
  677. this.$nextTick(() => {
  678. if (this.$refs[this.propForm.click_ref] != undefined && this.$refs[this.propForm.click_ref] != null) {
  679. this.$refs[this.propForm.click_ref].scrollIntoView()
  680. }
  681. })
  682. },
  683. menuCancleThree: function () {
  684. this.advice_visibility = false
  685. this.isShowDialog = true
  686. },
  687. menuMsgTip: function () {
  688. this.msgtip_visibility = false
  689. this.isShowDialog = true
  690. },
  691. menuComfirmThree: function (targetAdvices) {
  692. if (targetAdvices.length > 0) {
  693. if (this.is_pre == 1) {
  694. Toast.loading({forbidClick: true, duration: 0})
  695. let ParamsQuery = this.dialysisPrescription
  696. ParamsQuery['patient'] = this.$route.query.patient_id
  697. ParamsQuery['record_date'] = this.record_date
  698. commitDialysisPrescription(ParamsQuery).then(response => {
  699. if (response.data.state == 0) {
  700. Toast.fail(response.data.msg)
  701. return false
  702. } else {
  703. var date = new Date();
  704. var year = date.getFullYear();
  705. var month = date.getMonth() + 1;
  706. var day = date.getDate();
  707. var hours = date.getHours();
  708. var minites = date.getMinutes();
  709. if (month < 10) {
  710. month = "0" + month;
  711. }
  712. if (day < 10) {
  713. day = "0" + day;
  714. }
  715. if (hours < 10) {
  716. hours = "0" + hours;
  717. }
  718. if (minites < 10) {
  719. minites = "0" + minites;
  720. }
  721. var nowDate = year + "-" + month + "-" + day +" " +hours+":"+ minites;
  722. Toast.success('提交成功')
  723. let params = {
  724. advices: targetAdvices,
  725. advice_date: parseTime(this.$route.query.date, '{y}-{m}-{d}'),
  726. advice_doctor: targetAdvices[0].advice_doctor,
  727. advice_type: targetAdvices[0].advice_type,
  728. parent_id: this.$route.query.patient_id,
  729. start_time: nowDate,
  730. remark: '',
  731. }
  732. CreateGroupAdvice(this.$route.query.patient_id, 0, params).then(rs => {
  733. var resp = rs.data
  734. if (resp.state == 1) {
  735. this.$emit('prescription', response.data.data.prescription,resp.data.advices)
  736. } else {
  737. }
  738. })
  739. this.finish()
  740. }
  741. })
  742. } else if (this.is_pre == 2) {
  743. Toast.loading({forbidClick: true, duration: 0})
  744. let ParamsQuery = this.dialysisPrescription
  745. ParamsQuery['patient'] = this.$route.query.patient_id
  746. ParamsQuery['record_date'] = this.record_date
  747. postSolution(ParamsQuery).then(response => {
  748. if (response.data.state == 0) {
  749. Toast.fail(response.data.msg)
  750. return false
  751. } else {
  752. Toast.success('提交成功')
  753. var date = new Date();
  754. var year = date.getFullYear();
  755. var month = date.getMonth() + 1;
  756. var day = date.getDate();
  757. var hours = date.getHours();
  758. var minites = date.getMinutes();
  759. if (month < 10) {
  760. month = "0" + month;
  761. }
  762. if (day < 10) {
  763. day = "0" + day;
  764. }
  765. if (hours < 10) {
  766. hours = "0" + hours;
  767. }
  768. if (minites < 10) {
  769. minites = "0" + minites;
  770. }
  771. var nowDate = year + "-" + month + "-" + day +" " +hours+":"+ minites;
  772. let params = {
  773. advices: targetAdvices,
  774. advice_date: parseTime(this.$route.query.date, '{y}-{m}-{d}'),
  775. advice_doctor: targetAdvices[0].advice_doctor,
  776. advice_type: targetAdvices[0].advice_type,
  777. parent_id: this.$route.query.patient_id,
  778. start_time: nowDate,
  779. remark: '',
  780. }
  781. CreateGroupAdvice(this.$route.query.patient_id, 0, params).then(rs => {
  782. var resp = rs.data
  783. if (resp.state == 1) {
  784. this.$emit('prescription', response.data.data.prescription,resp.data.advices)
  785. this.$emit('longSolution', response.data.data.solution,resp.data.advices)
  786. } else {
  787. }
  788. })
  789. this.finish()
  790. }
  791. })
  792. }
  793. } else {
  794. if (this.is_pre == 1) {
  795. Toast.loading({forbidClick: true, duration: 0})
  796. let ParamsQuery = this.dialysisPrescription
  797. ParamsQuery['patient'] = this.$route.query.patient_id
  798. ParamsQuery['record_date'] = this.record_date
  799. commitDialysisPrescription(ParamsQuery).then(response => {
  800. if (response.data.state == 0) {
  801. Toast.fail(response.data.msg)
  802. return false
  803. } else {
  804. Toast.success('提交成功')
  805. this.$emit('prescription', response.data.data.prescription, this.doctorAdvices)
  806. this.finish()
  807. }
  808. })
  809. } else if (this.is_pre == 2) {
  810. Toast.loading({forbidClick: true, duration: 0})
  811. let ParamsQuery = this.dialysisPrescription
  812. ParamsQuery['patient'] = this.$route.query.patient_id
  813. ParamsQuery['record_date'] = this.record_date
  814. postSolution(ParamsQuery).then(response => {
  815. if (response.data.state == 0) {
  816. Toast.fail(response.data.msg)
  817. return false
  818. } else {
  819. Toast.success('提交成功')
  820. this.$emit('longSolution', response.data.data.solution, this.doctorAdvices)
  821. this.$emit('prescription', response.data.data.prescription, this.doctorAdvices)
  822. this.finish()
  823. }
  824. })
  825. }
  826. }
  827. },
  828. menuComfirm: function (val) {
  829. this.visibility = false
  830. this.isShowDialog = true
  831. this.$nextTick(() => {
  832. if (this.$refs[this.propForm.click_ref] != undefined && this.$refs[this.propForm.click_ref] != null) {
  833. this.$refs[this.propForm.click_ref].scrollIntoView()
  834. }
  835. })
  836. switch (val.type) {
  837. case 1:
  838. this.dialysisPrescription.mode_id = val.selectId
  839. break
  840. case 2:
  841. this.dialysisPrescription.dialyzer = val.selectId
  842. break
  843. case 3:
  844. this.dialysisPrescription.perfusion_apparatus = val.selectId
  845. break
  846. case 4:
  847. this.dialysisPrescription.replacement_way = val.selectId
  848. console.log(this.dialysisPrescription.replacement_way)
  849. break
  850. case 5:
  851. this.dialysisPrescription.anticoagulant = val.selectId
  852. if (typeof this.anticoagulantsConfit[val.selectId] == 'undefined' || this.anticoagulantsConfit[val.selectId] == null) {
  853. return
  854. }
  855. this.anticoagulant = this.anticoagulantsConfit[val.selectId]
  856. break
  857. case 6:
  858. this.dialysisPrescription.dialysate_formulation = val.selectId
  859. break
  860. case 7:
  861. this.dialysisPrescription.body_fluid = val.selectId
  862. break
  863. case 8:
  864. this.dialysisPrescription.special_medicine = val.selectId
  865. break
  866. case 9:
  867. this.dialysisPrescription.displace_liqui_part = val.selectId
  868. break
  869. case 10:
  870. this.dialysisPrescription.blood_access = val.selectId
  871. break
  872. }
  873. },
  874. GetModeByModeId: function (val) {
  875. let treatment_mode_name = ''
  876. let treatment_mode = this.modeOption
  877. for (let keys in treatment_mode) {
  878. if (treatment_mode[keys].id == val) {
  879. treatment_mode_name = treatment_mode[keys].name
  880. }
  881. }
  882. // for (let keys in treatment_mode) {
  883. // if (treatment_mode[keys].id == val) {
  884. // treatment_mode_name = treatment_mode[keys].name
  885. // if (treatment_mode_name == 'HD') {
  886. // this.zhiShow = false
  887. // this.totalShow = false
  888. // this.huShow = false
  889. // } else {
  890. // this.zhiShow = true
  891. // this.totalShow = true
  892. // this.huShow = true
  893. // }
  894. // }
  895. // }
  896. return treatment_mode_name
  897. },
  898. GetDialysateFormulationById: function (val) {
  899. let name = ''
  900. let dfl = this.dialysateFormulationOptions.length
  901. for (let index = 0; index < dfl; index++) {
  902. if (this.dialysateFormulationOptions[index].id == val) {
  903. name = this.dialysateFormulationOptions[index].name
  904. break
  905. }
  906. }
  907. return name
  908. },
  909. GetDialyzerById: function (val) {
  910. let dialyzer_name = ''
  911. let machines = this.machines_prop
  912. for (let i = 0; i < machines.length; i++) {
  913. if (machines[i].id == val) {
  914. dialyzer_name = machines[i].name
  915. }
  916. }
  917. return dialyzer_name
  918. },
  919. GetPerfusionApparatusById: function (val) {
  920. let perfusion_apparatus_name = ''
  921. let perfusion_apparatus = this.perfusion_apparatus
  922. for (let i = 0; i < perfusion_apparatus.length; i++) {
  923. if (perfusion_apparatus[i].id == val) {
  924. perfusion_apparatus_name = perfusion_apparatus[i].name
  925. }
  926. }
  927. return perfusion_apparatus_name
  928. },
  929. GetReplacementWayById: function (val) {
  930. let replacement_ways_name = ''
  931. let replacement_ways = this.replacementWays
  932. for (let i = 0; i < replacement_ways.length; i++) {
  933. if (replacement_ways[i].id == val) {
  934. replacement_ways_name = replacement_ways[i].name
  935. }
  936. }
  937. return replacement_ways_name
  938. },
  939. GetAnticoagulantById: function (val) {
  940. let anticoagulan_name = ''
  941. let anticoagulant = this.anticoagulantsConfit
  942. for (let keys in anticoagulant) {
  943. if (anticoagulant[keys].id == val) {
  944. anticoagulan_name = anticoagulant[keys].name
  945. }
  946. }
  947. return anticoagulan_name
  948. },
  949. commitInfo: function () {
  950. if(this.$store.getters.user.template_info.template_id == 6) {
  951. if (this.dialysisPrescription.mode_id == 2) {
  952. if (this.dialysisPrescription.displace_liqui_part == 0 || this.dialysisPrescription.displace_liqui_part == -2 || this.dialysisPrescription.replacement_total == 0 || this.dialysisPrescription.replacement_total == "") {
  953. Toast.fail("HDF模式下置换方式和置换量不能为空!")
  954. return
  955. }
  956. }
  957. }
  958. this.is_pre = 1
  959. if (this.prescription_prop.id == '') {
  960. if (this.is_open == 0) {
  961. Toast.loading({forbidClick: true, duration: 0})
  962. let ParamsQuery = this.dialysisPrescription
  963. ParamsQuery['patient'] = this.$route.query.patient_id
  964. ParamsQuery['record_date'] = this.record_date
  965. commitDialysisPrescription(ParamsQuery).then(response => {
  966. if (response.data.state == 0) {
  967. Toast.fail(response.data.msg)
  968. return false
  969. } else {
  970. Toast.success('提交成功')
  971. this.$emit('prescription', response.data.data.prescription, this.doctorAdvices)
  972. this.finish()
  973. }
  974. })
  975. } else if (this.is_open == 1) {
  976. if (this.targetAdvices.length > 0) {
  977. //弹框推送提醒
  978. this.advicePropForm.list = this.targetAdvices
  979. this.advicePropForm.operators = this.admin_users_prop
  980. this.advice_visibility = true
  981. this.isShowDialog = false
  982. for (let i = 0; i < this.advicePropForm.list.length; i++) {
  983. if (this.advicePropForm.list[i].parent_id == 0 && this.advicePropForm.list[i].isCheck == 1) {
  984. this.advicePropForm.result.push(this.advicePropForm.list[i].id)
  985. }
  986. }
  987. } else {
  988. Toast.loading({forbidClick: true, duration: 0})
  989. let ParamsQuery = this.dialysisPrescription
  990. ParamsQuery['patient'] = this.$route.query.patient_id
  991. ParamsQuery['record_date'] = this.record_date
  992. commitDialysisPrescription(ParamsQuery).then(response => {
  993. if (response.data.state == 0) {
  994. Toast.fail(response.data.msg)
  995. return false
  996. } else {
  997. Toast.success('提交成功')
  998. this.$emit('prescription', response.data.data.prescription, this.doctorAdvices)
  999. this.finish()
  1000. }
  1001. })
  1002. }
  1003. } else if (this.is_open == 2) {
  1004. if (this.waitUploadAdvices.length > 0) {
  1005. Toast.loading({forbidClick: true, duration: 0})
  1006. let ParamsQuery = this.dialysisPrescription
  1007. ParamsQuery['patient'] = this.$route.query.patient_id
  1008. ParamsQuery['record_date'] = this.record_date
  1009. commitDialysisPrescription(ParamsQuery).then(response => {
  1010. if (response.data.state == 0) {
  1011. Toast.fail(response.data.msg)
  1012. return false
  1013. } else {
  1014. Toast.success('提交成功')
  1015. var date = new Date();
  1016. var year = date.getFullYear();
  1017. var month = date.getMonth() + 1;
  1018. var day = date.getDate();
  1019. var hours = date.getHours();
  1020. var minites = date.getMinutes();
  1021. if (month < 10) {
  1022. month = "0" + month;
  1023. }
  1024. if (day < 10) {
  1025. day = "0" + day;
  1026. }
  1027. if (hours < 10) {
  1028. hours = "0" + hours;
  1029. }
  1030. if (minites < 10) {
  1031. minites = "0" + minites;
  1032. }
  1033. var nowDate = year + "-" + month + "-" + day +" " +hours+":"+ minites;
  1034. let params = {
  1035. advices: this.waitUploadAdvices,
  1036. advice_date: parseTime(this.$route.query.date, '{y}-{m}-{d}'),
  1037. advice_doctor: this.waitUploadAdvices[0].advice_doctor,
  1038. advice_type: this.waitUploadAdvices[0].advice_type,
  1039. parent_id: this.$route.query.patient_id,
  1040. start_time: nowDate,
  1041. remark: '',
  1042. }
  1043. CreateGroupAdvice(this.$route.query.patient_id, 0, params).then(rs => {
  1044. var resp = rs.data
  1045. if (resp.state == 1) {
  1046. this.$emit('prescription', response.data.data.prescription, resp.data.advices)
  1047. } else {
  1048. }
  1049. })
  1050. this.finish()
  1051. }
  1052. })
  1053. } else {
  1054. Toast.loading({forbidClick: true, duration: 0})
  1055. let ParamsQuery = this.dialysisPrescription
  1056. ParamsQuery['patient'] = this.$route.query.patient_id
  1057. ParamsQuery['record_date'] = this.record_date
  1058. commitDialysisPrescription(ParamsQuery).then(response => {
  1059. if (response.data.state == 0) {
  1060. Toast.fail(response.data.msg)
  1061. return false
  1062. } else {
  1063. this.advice_visibility = false
  1064. Toast.success('提交成功')
  1065. this.$emit('prescription', response.data.data.prescription, this.doctorAdvices)
  1066. this.finish()
  1067. }
  1068. })
  1069. }
  1070. }
  1071. } else {
  1072. if (this.prescription_prop.creater == 0) {
  1073. if (this.is_open == 0) {
  1074. Toast.loading({forbidClick: true, duration: 0})
  1075. let ParamsQuery = this.dialysisPrescription
  1076. ParamsQuery['patient'] = this.$route.query.patient_id
  1077. ParamsQuery['record_date'] = this.record_date
  1078. commitDialysisPrescription(ParamsQuery).then(response => {
  1079. if (response.data.state == 0) {
  1080. Toast.fail(response.data.msg)
  1081. return false
  1082. } else {
  1083. Toast.success('提交成功')
  1084. this.$emit('prescription', response.data.data.prescription, this.doctorAdvices)
  1085. this.finish()
  1086. }
  1087. })
  1088. } else if (this.is_open == 1) {
  1089. if (this.targetAdvices.length > 0) {
  1090. //弹框推送提醒
  1091. this.advicePropForm.list = this.targetAdvices
  1092. this.advicePropForm.operators = this.admin_users_prop
  1093. this.advice_visibility = true
  1094. this.isShowDialog = false
  1095. for (let i = 0; i < this.advicePropForm.list.length; i++) {
  1096. if (this.advicePropForm.list[i].parent_id == 0 && this.advicePropForm.list[i].isCheck == 1) {
  1097. this.advicePropForm.result.push(this.advicePropForm.list[i].id)
  1098. }
  1099. }
  1100. } else {
  1101. Toast.loading({forbidClick: true, duration: 0})
  1102. let ParamsQuery = this.dialysisPrescription
  1103. ParamsQuery['patient'] = this.$route.query.patient_id
  1104. ParamsQuery['record_date'] = this.record_date
  1105. commitDialysisPrescription(ParamsQuery).then(response => {
  1106. if (response.data.state == 0) {
  1107. Toast.fail(response.data.msg)
  1108. return false
  1109. } else {
  1110. Toast.success('提交成功')
  1111. this.$emit('prescription', response.data.data.prescription, this.doctorAdvices)
  1112. this.finish()
  1113. }
  1114. })
  1115. }
  1116. } else if (this.is_open == 2) {
  1117. if (this.waitUploadAdvices.length > 0) {
  1118. Toast.loading({forbidClick: true, duration: 0})
  1119. let ParamsQuery = this.dialysisPrescription
  1120. ParamsQuery['patient'] = this.$route.query.patient_id
  1121. ParamsQuery['record_date'] = this.record_date
  1122. commitDialysisPrescription(ParamsQuery).then(response => {
  1123. if (response.data.state == 0) {
  1124. Toast.fail(response.data.msg)
  1125. return false
  1126. } else {
  1127. var date = new Date();
  1128. var year = date.getFullYear();
  1129. var month = date.getMonth() + 1;
  1130. var day = date.getDate();
  1131. var hours = date.getHours();
  1132. var minites = date.getMinutes();
  1133. if (month < 10) {
  1134. month = "0" + month;
  1135. }
  1136. if (day < 10) {
  1137. day = "0" + day;
  1138. }
  1139. if (hours < 10) {
  1140. hours = "0" + hours;
  1141. }
  1142. if (minites < 10) {
  1143. minites = "0" + minites;
  1144. }
  1145. var nowDate = year + "-" + month + "-" + day +" " +hours+":"+ minites;
  1146. let params = {
  1147. advices: this.waitUploadAdvices,
  1148. advice_date: parseTime(this.$route.query.date, '{y}-{m}-{d}'),
  1149. advice_doctor: this.waitUploadAdvices[0].advice_doctor,
  1150. advice_type: this.waitUploadAdvices[0].advice_type,
  1151. parent_id: this.$route.query.patient_id,
  1152. start_time: nowDate,
  1153. remark: '',
  1154. }
  1155. CreateGroupAdvice(this.$route.query.patient_id, 0, params).then(rs => {
  1156. var resp = rs.data
  1157. if (resp.state == 1) {
  1158. this.doctorAdvices = resp.data.advices
  1159. this.$emit('prescription', response.data.data.prescription, resp.data.advices)
  1160. } else {
  1161. }
  1162. })
  1163. Toast.success('提交成功')
  1164. this.finish()
  1165. }
  1166. })
  1167. } else {
  1168. Toast.loading({forbidClick: true, duration: 0})
  1169. let ParamsQuery = this.dialysisPrescription
  1170. ParamsQuery['patient'] = this.$route.query.patient_id
  1171. ParamsQuery['record_date'] = this.record_date
  1172. commitDialysisPrescription(ParamsQuery).then(response => {
  1173. if (response.data.state == 0) {
  1174. Toast.fail(response.data.msg)
  1175. return false
  1176. } else {
  1177. Toast.success('提交成功')
  1178. this.$emit('prescription', response.data.data.prescription, this.doctorAdvices)
  1179. this.finish()
  1180. }
  1181. })
  1182. }
  1183. }
  1184. } else {
  1185. Toast.loading({forbidClick: true, duration: 0})
  1186. let ParamsQuery = this.dialysisPrescription
  1187. ParamsQuery['patient'] = this.$route.query.patient_id
  1188. ParamsQuery['record_date'] = this.record_date
  1189. commitDialysisPrescription(ParamsQuery).then(response => {
  1190. if (response.data.state == 0) {
  1191. Toast.fail(response.data.msg)
  1192. return false
  1193. } else {
  1194. Toast.success('提交成功')
  1195. this.$emit('prescription', response.data.data.prescription, this.doctorAdvices)
  1196. this.finish()
  1197. }
  1198. })
  1199. }
  1200. }
  1201. }, commitSolutionInfo: function () {
  1202. if(this.$store.getters.user.template_info.template_id == 6) {
  1203. if (this.dialysisPrescription.mode_id == 2) {
  1204. if (this.dialysisPrescription.displace_liqui_part == 0 || this.dialysisPrescription.displace_liqui_part == -2 || this.dialysisPrescription.replacement_total == 0 || this.dialysisPrescription.replacement_total == "") {
  1205. Toast.fail("HDF模式下置换方式和置换量不能为空!")
  1206. return
  1207. }
  1208. }
  1209. }
  1210. this.is_pre = 2
  1211. if (this.prescription_prop.id == '') {
  1212. if (this.is_open == 0) {
  1213. Toast.loading({forbidClick: true, duration: 0})
  1214. let ParamsQuery = this.dialysisPrescription
  1215. ParamsQuery['patient'] = this.$route.query.patient_id
  1216. ParamsQuery['record_date'] = this.record_date
  1217. postSolution(ParamsQuery).then(response => {
  1218. if (response.data.state == 0) {
  1219. Toast.fail(response.data.msg)
  1220. return false
  1221. } else {
  1222. Toast.success('提交成功')
  1223. this.$emit('advice')
  1224. this.$emit('longSolution', response.data.data.solution)
  1225. this.$emit('prescription', response.data.data.prescription)
  1226. this.finish()
  1227. }
  1228. })
  1229. } else if (this.is_open == 1) {
  1230. if (this.targetAdvices.length > 0) {
  1231. //弹框推送提醒
  1232. this.advicePropForm.list = this.targetAdvices
  1233. this.advicePropForm.operators = this.admin_users_prop
  1234. this.advice_visibility = true
  1235. this.isShowDialog = false
  1236. for (let i = 0; i < this.advicePropForm.list.length; i++) {
  1237. if (this.advicePropForm.list[i].parent_id == 0 && this.advicePropForm.list[i].isCheck == 1) {
  1238. this.advicePropForm.result.push(this.advicePropForm.list[i].id)
  1239. }
  1240. }
  1241. } else {
  1242. Toast.loading({forbidClick: true, duration: 0})
  1243. let ParamsQuery = this.dialysisPrescription
  1244. ParamsQuery['patient'] = this.$route.query.patient_id
  1245. ParamsQuery['record_date'] = this.record_date
  1246. postSolution(ParamsQuery).then(response => {
  1247. if (response.data.state == 0) {
  1248. Toast.fail(response.data.msg)
  1249. return false
  1250. } else {
  1251. Toast.success('提交成功')
  1252. this.$emit('advice')
  1253. this.$emit('longSolution', response.data.data.solution)
  1254. this.$emit('prescription', response.data.data.prescription)
  1255. this.finish()
  1256. }
  1257. })
  1258. }
  1259. } else if (this.is_open == 2) {
  1260. if (this.waitUploadAdvices.length > 0) {
  1261. Toast.loading({forbidClick: true, duration: 0})
  1262. let ParamsQuery = this.dialysisPrescription
  1263. ParamsQuery['patient'] = this.$route.query.patient_id
  1264. ParamsQuery['record_date'] = this.record_date
  1265. postSolution(ParamsQuery).then(response => {
  1266. if (response.data.state == 0) {
  1267. Toast.fail(response.data.msg)
  1268. return false
  1269. } else {
  1270. Toast.success('提交成功')
  1271. var date = new Date();
  1272. var year = date.getFullYear();
  1273. var month = date.getMonth() + 1;
  1274. var day = date.getDate();
  1275. var hours = date.getHours();
  1276. var minites = date.getMinutes();
  1277. if (month < 10) {
  1278. month = "0" + month;
  1279. }
  1280. if (day < 10) {
  1281. day = "0" + day;
  1282. }
  1283. if (hours < 10) {
  1284. hours = "0" + hours;
  1285. }
  1286. if (minites < 10) {
  1287. minites = "0" + minites;
  1288. }
  1289. var nowDate = year + "-" + month + "-" + day +" " +hours+":"+ minites;
  1290. let params = {
  1291. advices: this.waitUploadAdvices,
  1292. advice_date: parseTime(this.$route.query.date, '{y}-{m}-{d}'),
  1293. advice_doctor: this.waitUploadAdvices[0].advice_doctor,
  1294. advice_type: this.waitUploadAdvices[0].advice_type,
  1295. parent_id: this.$route.query.patient_id,
  1296. start_time: nowDate,
  1297. remark: '',
  1298. }
  1299. CreateGroupAdvice(this.$route.query.patient_id, 0, params).then(rs => {
  1300. var resp = rs.data
  1301. if (resp.state == 1) {
  1302. this.doctorAdvices = resp.data.advices
  1303. this.$emit('longSolution', response.data.data.solution, resp.data.advices)
  1304. this.$emit('prescription', response.data.data.prescription, resp.data.advices)
  1305. } else {
  1306. }
  1307. })
  1308. this.finish()
  1309. }
  1310. })
  1311. } else {
  1312. Toast.loading({forbidClick: true, duration: 0})
  1313. let ParamsQuery = this.dialysisPrescription
  1314. ParamsQuery['patient'] = this.$route.query.patient_id
  1315. ParamsQuery['record_date'] = this.record_date
  1316. postSolution(ParamsQuery).then(response => {
  1317. if (response.data.state == 0) {
  1318. Toast.fail(response.data.msg)
  1319. return false
  1320. } else {
  1321. Toast.success('提交成功')
  1322. this.$emit('longSolution', response.data.data.solution)
  1323. this.$emit('prescription', response.data.data.prescription)
  1324. this.finish()
  1325. }
  1326. })
  1327. }
  1328. }
  1329. } else {
  1330. if (this.prescription_prop.creater == 0) {
  1331. if (this.is_open == 0) {
  1332. Toast.loading({forbidClick: true, duration: 0})
  1333. let ParamsQuery = this.dialysisPrescription
  1334. ParamsQuery['patient'] = this.$route.query.patient_id
  1335. ParamsQuery['record_date'] = this.record_date
  1336. postSolution(ParamsQuery).then(response => {
  1337. if (response.data.state == 0) {
  1338. Toast.fail(response.data.msg)
  1339. return false
  1340. } else {
  1341. Toast.success('提交成功')
  1342. this.$emit('longSolution', response.data.data.solution)
  1343. this.$emit('prescription', response.data.data.prescription)
  1344. this.finish()
  1345. }
  1346. })
  1347. } else if (this.is_open == 1) {
  1348. if (this.targetAdvices.length > 0) {
  1349. //弹框推送提醒
  1350. this.advicePropForm.list = this.targetAdvices
  1351. this.advicePropForm.operators = this.admin_users_prop
  1352. this.advice_visibility = true
  1353. this.isShowDialog = false
  1354. for (let i = 0; i < this.advicePropForm.list.length; i++) {
  1355. if (this.advicePropForm.list[i].parent_id == 0 && this.advicePropForm.list[i].isCheck == 1) {
  1356. this.advicePropForm.result.push(this.advicePropForm.list[i].id)
  1357. }
  1358. }
  1359. } else {
  1360. Toast.loading({forbidClick: true, duration: 0})
  1361. let ParamsQuery = this.dialysisPrescription
  1362. ParamsQuery['patient'] = this.$route.query.patient_id
  1363. ParamsQuery['record_date'] = this.record_date
  1364. postSolution(ParamsQuery).then(response => {
  1365. if (response.data.state == 0) {
  1366. Toast.fail(response.data.msg)
  1367. return false
  1368. } else {
  1369. Toast.success('提交成功')
  1370. this.$emit('longSolution', response.data.data.solution)
  1371. this.$emit('prescription', response.data.data.prescription)
  1372. this.finish()
  1373. }
  1374. })
  1375. }
  1376. } else if (this.is_open == 2) {
  1377. if (this.waitUploadAdvices.length > 0) {
  1378. Toast.loading({forbidClick: true, duration: 0})
  1379. let ParamsQuery = this.dialysisPrescription
  1380. ParamsQuery['patient'] = this.$route.query.patient_id
  1381. ParamsQuery['record_date'] = this.record_date
  1382. postSolution(ParamsQuery).then(response => {
  1383. if (response.data.state == 0) {
  1384. Toast.fail(response.data.msg)
  1385. return false
  1386. } else {
  1387. this.advice_visibility = false
  1388. var date = new Date();
  1389. var year = date.getFullYear();
  1390. var month = date.getMonth() + 1;
  1391. var day = date.getDate();
  1392. var hours = date.getHours();
  1393. var minites = date.getMinutes();
  1394. if (month < 10) {
  1395. month = "0" + month;
  1396. }
  1397. if (day < 10) {
  1398. day = "0" + day;
  1399. }
  1400. if (hours < 10) {
  1401. hours = "0" + hours;
  1402. }
  1403. if (minites < 10) {
  1404. minites = "0" + minites;
  1405. }
  1406. var nowDate = year + "-" + month + "-" + day +" " +hours+":"+ minites;
  1407. let params = {
  1408. advices: this.waitUploadAdvices,
  1409. advice_date: parseTime(this.$route.query.date, '{y}-{m}-{d}'),
  1410. advice_doctor: this.waitUploadAdvices[0].advice_doctor,
  1411. advice_type: this.waitUploadAdvices[0].advice_type,
  1412. parent_id: this.$route.query.patient_id,
  1413. start_time: nowDate,
  1414. remark: '',
  1415. }
  1416. CreateGroupAdvice(this.$route.query.patient_id, 0, params).then(rs => {
  1417. var resp = rs.data
  1418. if (resp.state == 1) {
  1419. this.doctorAdvices = resp.data.advices
  1420. this.$emit('longSolution', response.data.data.solution,resp.data.advices)
  1421. this.$emit('prescription', response.data.data.prescription,resp.data.advices)
  1422. } else {
  1423. }
  1424. })
  1425. Toast.success('提交成功')
  1426. this.finish()
  1427. }
  1428. })
  1429. } else {
  1430. Toast.loading({forbidClick: true, duration: 0})
  1431. let ParamsQuery = this.dialysisPrescription
  1432. ParamsQuery['patient'] = this.$route.query.patient_id
  1433. ParamsQuery['record_date'] = this.record_date
  1434. postSolution(ParamsQuery).then(response => {
  1435. if (response.data.state == 0) {
  1436. Toast.fail(response.data.msg)
  1437. return false
  1438. } else {
  1439. Toast.success('提交成功')
  1440. this.$emit('advice')
  1441. this.$emit('longSolution', response.data.data.solution)
  1442. this.$emit('prescription', response.data.data.prescription)
  1443. this.finish()
  1444. }
  1445. })
  1446. }
  1447. }
  1448. } else {
  1449. Toast.loading({forbidClick: true, duration: 0})
  1450. let ParamsQuery = this.dialysisPrescription
  1451. ParamsQuery['patient'] = this.$route.query.patient_id
  1452. ParamsQuery['record_date'] = this.record_date
  1453. postSolution(ParamsQuery).then(response => {
  1454. if (response.data.state == 0) {
  1455. Toast.fail(response.data.msg)
  1456. return false
  1457. } else {
  1458. Toast.success('提交成功')
  1459. this.$emit('longSolution', response.data.data.solution)
  1460. this.$emit('prescription', response.data.data.prescription)
  1461. this.finish()
  1462. }
  1463. })
  1464. }
  1465. }
  1466. }, finish: function () {
  1467. this.$emit('finish')
  1468. }, close: function () {
  1469. this.$emit('close')
  1470. }, open: function () {
  1471. this.isShowDialog = true
  1472. this.visibility = false
  1473. this.$refs.picker.close()
  1474. var dialogTop = document.querySelector('#dialogTop')
  1475. if (dialogTop != null) {
  1476. this.$nextTick(() => {
  1477. dialogTop.scrollTop = 0
  1478. })
  1479. }
  1480. }, sign: function () {
  1481. let params = {
  1482. patient_id: this.$route.query.patient_id,
  1483. date: this.record_date,
  1484. }
  1485. postSign(params).then(response => {
  1486. if (response.data.state == 0) {
  1487. Toast.fail(response.data.msg)
  1488. return false
  1489. } else {
  1490. this.isShowDesc = false
  1491. this.isShowDoctorSign = true
  1492. this.dialysisPrescription.prescription_doctor = response.data.data.doctor_id
  1493. for (let i = 0; i < this.operators.length; i++) {
  1494. if (this.operators[i].creator == response.data.data.doctor_id) {
  1495. console.log(this.operators[i].url)
  1496. this.signUrl = this.operators[i].url
  1497. }
  1498. }
  1499. Toast.success('签名成功')
  1500. }
  1501. })
  1502. }, getBodyFluid: function (val) {
  1503. let body_fluid_name = ''
  1504. let body_fluid = this.bodyFluidOptions
  1505. for (let i = 0; i < body_fluid.length; i++) {
  1506. if (body_fluid[i].id == val) {
  1507. body_fluid_name = body_fluid[i].name
  1508. }
  1509. }
  1510. return body_fluid_name
  1511. }, getSpecialMedicine: function (val) {
  1512. let special_medicine_name = ''
  1513. let special_medicine = this.specialMedicineOptions
  1514. for (let i = 0; i < special_medicine.length; i++) {
  1515. if (special_medicine[i].id == val) {
  1516. special_medicine_name = special_medicine[i].name
  1517. }
  1518. }
  1519. return special_medicine_name
  1520. }, getDisplaceLiquiPart: function (val) {
  1521. let displace_liqui_part_name = ''
  1522. let displace_liqui_part = this.displaceLiquiPartOptions
  1523. for (let i = 0; i < displace_liqui_part.length; i++) {
  1524. if (displace_liqui_part[i].id == val) {
  1525. displace_liqui_part_name = displace_liqui_part[i].name
  1526. }
  1527. }
  1528. return displace_liqui_part_name
  1529. }, getBloodAccess: function (val) {
  1530. let blood_access_name = ''
  1531. let blood_access = this.bloodAccessOptions
  1532. for (let i = 0; i < blood_access.length; i++) {
  1533. if (blood_access[i].id == val) {
  1534. blood_access_name = blood_access[i].name
  1535. }
  1536. }
  1537. return blood_access_name
  1538. }, menuEmpty: function (val) {
  1539. this.visibility = false
  1540. this.isShowDialog = true
  1541. switch (val.type) {
  1542. case 1:
  1543. this.dialysisPrescription.mode_id = ''
  1544. break
  1545. case 2:
  1546. this.dialysisPrescription.dialyzer = ''
  1547. break
  1548. case 3:
  1549. this.dialysisPrescription.perfusion_apparatus = ''
  1550. break
  1551. case 4:
  1552. this.dialysisPrescription.replacement_way = ''
  1553. break
  1554. case 5:
  1555. this.anticoagulant = ''
  1556. break
  1557. case 6:
  1558. this.dialysisPrescription.dialysate_formulation = ''
  1559. break
  1560. case 7:
  1561. this.dialysisPrescription.body_fluid = ''
  1562. break
  1563. case 8:
  1564. this.dialysisPrescription.special_medicine = ''
  1565. break
  1566. case 9:
  1567. this.dialysisPrescription.displace_liqui_part = ''
  1568. break
  1569. case 10:
  1570. this.dialysisPrescription.blood_access = ''
  1571. break
  1572. }
  1573. }, getFloat: function (x) {
  1574. if (x != '.') {
  1575. var f = Math.round(x * 100) / 100
  1576. var s = f.toString()
  1577. var rs = s.indexOf('.')
  1578. if (rs <= 0) {
  1579. rs = s.length
  1580. s += '.'
  1581. }
  1582. while (s.length <= rs + 1) {
  1583. s += '0'
  1584. }
  1585. return s
  1586. } else {
  1587. return '0.0'
  1588. }
  1589. }, dialysisGoodsClick: function () {
  1590. this.isShowDialog = false
  1591. this.is_show = true
  1592. }, menuCancleTwo: function () {
  1593. this.isShowDialog = true
  1594. this.is_show = false
  1595. }, menuComfirmTwo: function (dialysisPrescription) {
  1596. this.isShowDialog = true
  1597. this.is_show = false
  1598. this.dialysisPrescription.niprocart = dialysisPrescription.niprocart
  1599. this.dialysisPrescription.jms = dialysisPrescription.jms
  1600. this.dialysisPrescription.fistula_needle_set = dialysisPrescription.fistula_needle_set
  1601. this.dialysisPrescription.fistula_needle_set_16 = dialysisPrescription.fistula_needle_set_16
  1602. this.dialysisPrescription.hemoperfusion = dialysisPrescription.hemoperfusion
  1603. this.dialysisPrescription.dialyser_sterilised = dialysisPrescription.dialyser_sterilised
  1604. this.dialysisPrescription.filtryzer = dialysisPrescription.filtryzer
  1605. this.dialysisPrescription.dialyzers = dialysisPrescription.dialyzers
  1606. this.dialysisPrescription.injector = dialysisPrescription.injector
  1607. this.dialysisPrescription.bloodlines = dialysisPrescription.bloodlines
  1608. this.dialysisPrescription.tubing_hemodialysis = dialysisPrescription.tubing_hemodialysis
  1609. this.dialysisPrescription.package = dialysisPrescription.package
  1610. this.dialysisPrescription.a_liquid = dialysisPrescription.a_liquid
  1611. }
  1612. },
  1613. created () {
  1614. if (this.$store.getters.user.user.user_type == 2) {
  1615. this.isShowSign = true
  1616. }
  1617. this.modeOption = this.$store.getters.treatment_mode
  1618. delete this.modeOption['0']
  1619. var perfusion_apparatus = getDataConfig('hemodialysis', 'perfusion_apparatus')
  1620. this.perfusion_apparatus = perfusion_apparatus
  1621. this.anticoagulantsConfit = this.$store.getters.anticoagulants_confit
  1622. this.bodyFluidOptions = this.$store.getters.body_fluid
  1623. this.specialMedicineOptions = this.$store.getters.special_medicine
  1624. this.displaceLiquiPartOptions = this.$store.getters.displace_liqui
  1625. this.bloodAccessOptions = this.$store.getters.blood_access
  1626. this.dialysateFormulationOptions = getDataConfig('hemodialysis', 'dialysate_formulation')
  1627. this.replacementWays = getDataConfig('hemodialysis', 'replacement_ways')
  1628. this.patient = this.patient_prop
  1629. if (this.prescription_prop != null && typeof (this.prescription_prop.id) != 'undefined' && this.prescription_prop.id > 0) {
  1630. for (const key in this.prescription_prop) {
  1631. this.dialysisPrescription[key] = this.prescription_prop[key]
  1632. }
  1633. } else if (this.solution_prop != null && typeof this.solution_prop.id != 'undefined' && this.solution_prop.id) {
  1634. for (const key in this.solution_prop) {
  1635. this.dialysisPrescription[key] = this.solution_prop[key]
  1636. }
  1637. }
  1638. if (this.dialysisPrescription.dialysis_duration_hour.length == 0 || this.dialysisPrescription.dialysis_duration_minute.length == 0) {
  1639. this.timeValue = ''
  1640. this.time = '03:00'
  1641. } else {
  1642. this.timeValue = this.dialysisPrescription.dialysis_duration_hour + '小时' + this.dialysisPrescription.dialysis_duration_minute + '分钟'
  1643. this.time = (this.dialysisPrescription.dialysis_duration_hour > 10 ? this.dialysisPrescription.dialysis_duration_hour : '0' + this.dialysisPrescription.dialysis_duration_hour) + ':' + (this.dialysisPrescription.dialysis_duration_minute > 10 ? this.dialysisPrescription.dialysis_duration_minute : '0' + this.dialysisPrescription.dialysis_duration_minute)
  1644. }
  1645. this.dialyserList = this.machines_prop
  1646. // this.doctor = this.$store.getters.user.user.user_type;
  1647. var date = this.$route.query && this.$route.query.date
  1648. date *= 1000
  1649. var newDate = new Date(date)
  1650. var y = newDate.getFullYear()
  1651. var m = newDate.getMonth() + 1
  1652. var d = newDate.getDate()
  1653. if (isNaN(y) || isNaN(m) || isNaN(d)) {
  1654. newDate = new Date()
  1655. y = newDate.getFullYear()
  1656. m = newDate.getMonth() + 1
  1657. d = newDate.getDate()
  1658. }
  1659. this.record_date =
  1660. y + '-' + (m < 10 ? '0' + m : m) + '-' + (d < 10 ? '0' + d : d)
  1661. // this.patient.id = this.patient_prop.id
  1662. if (this.dialysisPrescription.prescription_doctor == '') {
  1663. this.isShowDesc = true
  1664. this.isShowDoctorSign = false
  1665. } else {
  1666. this.isShowDesc = false
  1667. this.isShowDoctorSign = true
  1668. for (let i = 0; i < this.operators.length; i++) {
  1669. if (this.operators[i].creator == this.dialysisPrescription.prescription_doctor) {
  1670. this.signUrl = this.operators[i].url
  1671. }
  1672. }
  1673. }
  1674. this.dialysisPrescription.kalium = this.getFloat(this.dialysisPrescription.kalium)
  1675. this.dialysisPrescription.sodium = this.getFloat(this.dialysisPrescription.sodium)
  1676. this.dialysisPrescription.calcium = this.getFloat(this.dialysisPrescription.calcium)
  1677. this.dialysisPrescription.ultrafiltration = this.getFloat(this.dialysisPrescription.ultrafiltration)
  1678. this.dialysisPrescription.target_ultrafiltration = this.getFloat(this.dialysisPrescription.target_ultrafiltration)
  1679. },
  1680. components: {
  1681. LongAdviceSubMenu,
  1682. MultipleSubMenu,
  1683. MsgTip,
  1684. // MultipleSubMenu,
  1685. CheckBoxSubMenu
  1686. },
  1687. watch: {
  1688. "dialysisPrescription.anticoagulant_shouji":function(val){
  1689. console.log(val)
  1690. this.dialysisPrescription.anticoagulant_zongliang = parseInt(this.dialysisPrescription.anticoagulant_shouji) + parseInt(this.dialysisPrescription.anticoagulant_weichi)
  1691. }, "dialysisPrescription.anticoagulant_weichi":function(val){
  1692. console.log(val)
  1693. this.dialysisPrescription.anticoagulant_zongliang = parseInt(this.dialysisPrescription.anticoagulant_shouji) + parseInt(this.dialysisPrescription.anticoagulant_weichi)
  1694. },
  1695. isShowDialog (val) {
  1696. if (val) {
  1697. this.advice_visibility = false
  1698. }
  1699. }
  1700. }
  1701. }
  1702. </script>
  1703. <style style="stylesheet/scss" lang="scss" scoped>
  1704. .DialogContent {
  1705. // padding-bottom:2rem !important;
  1706. .textarea {
  1707. width: 100%;
  1708. height: 2.4rem;
  1709. line-height: 0.6rem;
  1710. color: $pgh-color;
  1711. font-size: 0.28rem;
  1712. padding-left: 0.36rem;
  1713. border: none;
  1714. border-bottom: 1px #e5e5e5 solid;
  1715. }
  1716. }
  1717. </style>