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

dialysisPrescriptionDialog.vue 168KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002
  1. <template>
  2. <div>
  3. <el-dialog
  4. title="透析处方"
  5. :visible.sync="isVisibility"
  6. width="1010px"
  7. :modal-append-to-body="false"
  8. :append-to-body="true"
  9. class="newDialog"
  10. >
  11. <el-button
  12. style="position: absolute;left: 12%;top: 2%"
  13. @click="handlePatientInfo"
  14. >{{ patient.name }}
  15. </el-button
  16. >
  17. <div class="warnTxt" v-if="showTxt != ''">{{ showTxt }}</div>
  18. <el-form
  19. ref="dialysisPrescription"
  20. :model="dialysisPrescription"
  21. label-width="148px"
  22. >
  23. <el-row :gutter="24">
  24. <el-col :span="8" v-if="isShows('透析模式')">
  25. <el-form-item label="透析模式">
  26. <el-select
  27. v-model="dialysisPrescription.mode_id"
  28. @change="changePrescription(dialysisPrescription.mode_id)"
  29. >
  30. <el-option :key="0" label="请选择" :value="0"></el-option>
  31. <el-option
  32. v-for="(item, index) in treatment_mode"
  33. :label="item.name"
  34. :value="item.id"
  35. :key="index + 'q'"
  36. ></el-option>
  37. </el-select>
  38. </el-form-item>
  39. </el-col>
  40. <el-col :span="8" v-if="isShows('透析时长')">
  41. <el-form-item label="透析时长(h): ">
  42. <el-input
  43. type="number"
  44. v-model="dialysisPrescription.dialysis_duration_hour"
  45. ></el-input>
  46. </el-form-item>
  47. </el-col>
  48. <el-col :span="8" v-if="isShows('透析时长')">
  49. <el-form-item label="透析时长(min): ">
  50. <el-input
  51. type="number"
  52. v-model="dialysisPrescription.dialysis_duration_minute"
  53. ></el-input>
  54. </el-form-item>
  55. </el-col>
  56. <!-- </el-row>
  57. <el-row :gutter="20"> -->
  58. <el-col :span="8" v-if="isShows('血流量')">
  59. <el-form-item label="血流量(ml/min):">
  60. <el-input
  61. type="number"
  62. v-model="dialysisPrescription.blood_flow_volume"
  63. ></el-input>
  64. </el-form-item>
  65. </el-col>
  66. <el-col :span="8"
  67. v-if="isShows('预冲量') && (this.$store.getters.xt_user.template_info.template_id == 17 || this.$store.getters.xt_user.template_info.template_id == 9 || this.$store.getters.xt_user.template_info.template_id == 20 || this.$store.getters.xt_user.template_info.template_id == 21 || this.$store.getters.xt_user.template_info.template_id == 22 || this.$store.getters.xt_user.template_info.template_id == 23 || this.$store.getters.xt_user.template_info.template_id == 36)">
  68. <el-form-item label="预冲量(ml):">
  69. <el-input
  70. type="number"
  71. v-model="dialysisPrescription.pre_impulse"
  72. ></el-input>
  73. </el-form-item>
  74. </el-col>
  75. <el-col :span="8"
  76. v-if="isShows('预冲量') && this.$store.getters.xt_user.template_info.template_id != 17 && this.$store.getters.xt_user.template_info.template_id != 9 && this.$store.getters.xt_user.template_info.template_id != 20 && this.$store.getters.xt_user.template_info.template_id != 21 && this.$store.getters.xt_user.template_info.template_id != 22 && this.$store.getters.xt_user.template_info.template_id !=23 && this.$store.getters.xt_user.template_info.template_id !=36">
  77. <el-form-item label="预冲量(L):">
  78. <el-input
  79. type="number"
  80. v-model="dialysisPrescription.pre_impulse"
  81. ></el-input>
  82. </el-form-item>
  83. </el-col>
  84. <el-col :span="8"
  85. v-if="isShows('目标超滤量') && (this.$store.getters.xt_user.template_info.template_id == 17 || this.$store.getters.xt_user.template_info.template_id == 9 || this.$store.getters.xt_user.template_info.template_id == 20 || this.$store.getters.xt_user.template_info.template_id == 21 || this.$store.getters.xt_user.template_info.template_id == 22 || this.$store.getters.xt_user.template_info.template_id == 23 || this.$store.getters.xt_user.template_info.template_id == 24 || this.$store.getters.xt_user.template_info.template_id == 26 || this.$store.getters.xt_user.template_info.template_id == 28 || this.$store.getters.xt_user.template_info.template_id == 27 || this.$store.getters.xt_user.template_info.template_id == 29 || this.$store.getters.xt_user.template_info.template_id == 30 || this.$store.getters.xt_user.template_info.template_id == 31 || this.$store.getters.xt_user.template_info.template_id == 32 || this.$store.getters.xt_user.template_info.template_id == 34 || this.$store.getters.xt_user.template_info.template_id == 38 || this.$store.getters.xt_user.template_info.template_id == 40 || this.$store.getters.xt_user.template_info.template_id == 43 || this.$store.getters.xt_user.template_info.template_id == 45 || this.$store.getters.xt_user.template_info.template_id == 46 || this.$store.getters.xt_user.template_info.template_id == 48 || this.$store.getters.xt_user.template_info.org_id == 9555 )">
  86. <el-form-item label="目标超滤量(ml):">
  87. <el-input
  88. type="number"
  89. v-model="dialysisPrescription.target_ultrafiltration"
  90. ></el-input>
  91. </el-form-item>
  92. </el-col>
  93. <el-col :span="8"
  94. v-if="isShows('目标超滤量') && this.$store.getters.xt_user.template_info.template_id != 17 && this.$store.getters.xt_user.template_info.template_id != 9 && this.$store.getters.xt_user.template_info.template_id != 20 && this.$store.getters.xt_user.template_info.template_id != 21 && this.$store.getters.xt_user.template_info.template_id != 22 && this.$store.getters.xt_user.template_info.template_id != 23 && this.$store.getters.xt_user.template_info.template_id != 24 && this.$store.getters.xt_user.template_info.template_id != 26 && this.$store.getters.xt_user.template_info.template_id != 28 && this.$store.getters.xt_user.template_info.template_id != 27 && this.$store.getters.xt_user.template_info.template_id != 29 && this.$store.getters.xt_user.template_info.template_id != 30 && this.$store.getters.xt_user.template_info.template_id != 31 && this.$store.getters.xt_user.template_info.template_id != 32 && this.$store.getters.xt_user.template_info.template_id != 34 && this.$store.getters.xt_user.template_info.template_id != 38 && this.$store.getters.xt_user.template_info.template_id != 40 && this.$store.getters.xt_user.template_info.template_id != 43 && this.$store.getters.xt_user.template_info.template_id != 45 && this.$store.getters.xt_user.template_info.template_id != 46 && this.$store.getters.xt_user.template_info.template_id != 48 && this.$store.getters.xt_user.template_info.org_id != 9555 ">
  95. <el-form-item label="目标超滤量(L):">
  96. <el-input
  97. type="number"
  98. v-model="dialysisPrescription.target_ultrafiltration"
  99. ></el-input>
  100. </el-form-item>
  101. </el-col>
  102. <el-col :span="8" v-if="isShows('单超时长')">
  103. <el-form-item label="单超时长(h):">
  104. <el-input v-model="dialysisPrescription.single_time"></el-input>
  105. </el-form-item>
  106. </el-col>
  107. <el-col :span="8" v-if="isShows('单超脱水')">
  108. <el-form-item label="单超脱水(L):">
  109. <el-input v-model="dialysisPrescription.single_water"></el-input>
  110. </el-form-item>
  111. </el-col>
  112. <el-col :span="8" v-if="isShows('透析液配方')">
  113. <el-form-item label="透析液配方:">
  114. <!-- <el-input type="number" v-model="dialysisPrescription.dialysate_formulation"></el-input> -->
  115. <el-select
  116. v-model="dialysisPrescription.dialysate_formulation"
  117. placeholder="请选择"
  118. >
  119. <el-option :key="0" label="请选择" :value="0"></el-option>
  120. <el-option
  121. v-for="(option, index) in dialysate_formulation_options"
  122. :key="index + 'w'"
  123. :label="option.name"
  124. :value="option.id"
  125. ></el-option>
  126. </el-select>
  127. </el-form-item>
  128. </el-col>
  129. <!-- </el-row>
  130. <el-row :gutter="20"> -->
  131. <el-col :span="8" v-if="isShows('抗凝剂')">
  132. <el-form-item label="抗凝剂:">
  133. <el-select v-model="dialysisPrescription.anticoagulant" placeholder="请选择"
  134. style="width:100%;"
  135. @change="changeThisAnticoagulant">
  136. <el-option :key="0" label="请选择" :value="0"></el-option>
  137. <el-option v-if="dialysisPrescription.anticoagulant ==3" :key="3" label="低分子肝素"
  138. :value="3"></el-option>
  139. <el-option v-for="(item, index) in anticoagulantsConfit" :label="item.name"
  140. :key="index + 'e'"
  141. :value="item.id"></el-option>
  142. </el-select>
  143. </el-form-item>
  144. </el-col>
  145. <el-col :span="8" v-if="isShows('抗凝剂商品名称')">
  146. <el-form-item label="抗凝剂商品名称:">
  147. <el-input
  148. v-model="dialysisPrescription.antioxidant_commodity_name"
  149. ></el-input>
  150. </el-form-item>
  151. </el-col>
  152. <el-col :span="8" v-if="isShows('肝素钠') && dialysisPrescription.anticoagulant ==10">
  153. <el-form-item label="肝素钠(mg/h):">
  154. <el-input
  155. v-model="dialysisPrescription.heparin_sodium"
  156. ></el-input>
  157. </el-form-item>
  158. </el-col>
  159. <el-col :span="8" v-if="isShows('鱼精蛋白') && dialysisPrescription.anticoagulant ==10">
  160. <el-form-item label="鱼精蛋白(mg/h):">
  161. <el-input
  162. v-model="dialysisPrescription.nucleoprotamine"
  163. ></el-input>
  164. </el-form-item>
  165. </el-col>
  166. <el-col :span="8" v-if="isShows('下机前推注鱼精蛋白') && dialysisPrescription.anticoagulant ==10">
  167. <el-form-item label="下机前推注鱼精蛋白(mg):">
  168. <el-input
  169. v-model="dialysisPrescription.push_the_protamine"
  170. ></el-input>
  171. </el-form-item>
  172. </el-col>
  173. <el-col :span="8" v-if="isShows('无肝素备注') && dialysisPrescription.anticoagulant ==1">
  174. <el-form-item label="无肝素备注:">
  175. <el-input
  176. v-model="dialysisPrescription.no_heparin_remarks"
  177. ></el-input>
  178. </el-form-item>
  179. </el-col>
  180. <el-col :span="8" v-if="anticoagulant.shouji != -1 && isShows('首剂')">
  181. <div v-if="this.$store.getters.xt_user.template_info.org_id != 10157">
  182. <div v-if="this.$store.getters.xt_user.template_info.org_id != 10101 && this.$store.getters.xt_user.template_info.template_id != 45">
  183. <el-form-item
  184. v-if='this.$store.getters.xt_user.template_info.template_id != 21 && this.$store.getters.xt_user.template_info.template_id != 23 && this.$store.getters.xt_user.template_info.template_id != 38 && this.$store.getters.xt_user.template_info.org_id != 9987'
  185. :label="'首剂(' + anticoagulant.shouji_unit + ') : '">
  186. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  187. v-model="dialysisPrescription.anticoagulant_shouji"></el-input>
  188. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  189. v-model="dialysisPrescription.no_anticoagulant_shouji"></el-input>
  190. </el-form-item>
  191. <el-form-item
  192. v-if='dialysisPrescription.anticoagulant == 2 && this.$store.getters.xt_user.template_info.template_id == 21 || this.$store.getters.xt_user.template_info.template_id == 23 || this.$store.getters.xt_user.template_info.template_id == 38 || this.$store.getters.xt_user.template_info.org_id == 9987 && dialysisPrescription.anticoagulant == 2'
  193. :label="'首剂(mg) : '">
  194. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  195. v-model="dialysisPrescription.anticoagulant_shouji"></el-input>
  196. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  197. v-model="dialysisPrescription.no_anticoagulant_shouji"></el-input>
  198. </el-form-item>
  199. </div>
  200. <div v-else>
  201. <el-form-item v-if="dialysisPrescription.anticoagulant == 2" :label="'首剂(mg) : '">
  202. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  203. v-model="dialysisPrescription.anticoagulant_shouji"></el-input>
  204. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  205. v-model="dialysisPrescription.no_anticoagulant_shouji"></el-input>
  206. </el-form-item>
  207. <el-form-item v-else :label="'首剂(iu) : '">
  208. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  209. v-model="dialysisPrescription.anticoagulant_shouji"></el-input>
  210. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  211. v-model="dialysisPrescription.no_anticoagulant_shouji"></el-input>
  212. </el-form-item>
  213. </div>
  214. </div>
  215. <div v-else>
  216. <el-form-item v-if="dialysisPrescription.anticoagulant == 2" :label="'首剂(mg) : '">
  217. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  218. v-model="dialysisPrescription.anticoagulant_shouji"></el-input>
  219. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  220. v-model="dialysisPrescription.no_anticoagulant_shouji"></el-input>
  221. </el-form-item>
  222. <el-form-item v-else :label="'首剂(' + anticoagulant.shouji_unit + ') : '">
  223. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  224. v-model="dialysisPrescription.anticoagulant_shouji"></el-input>
  225. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  226. v-model="dialysisPrescription.no_anticoagulant_shouji"></el-input>
  227. </el-form-item>
  228. </div>
  229. </el-col>
  230. <el-col :span="8" v-if="anticoagulant.weichi != -1 && isShows('维持')">
  231. <div v-if="this.$store.getters.xt_user.template_info.org_id != 10157">
  232. <div v-if="this.$store.getters.xt_user.template_info.org_id != 10101 && this.$store.getters.xt_user.template_info.template_id != 45">
  233. <el-form-item :label="'维持(' + anticoagulant.weichi_unit + ') : '"
  234. v-if="anticoagulant.weichi != -1 && this.$store.getters.xt_user.template_info.template_id != 21 && this.$store.getters.xt_user.template_info.template_id != 23 && this.$store.getters.xt_user.template_info.template_id != 38 && this.$store.getters.xt_user.template_info.org_id != 9987">
  235. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  236. v-model="dialysisPrescription.anticoagulant_weichi"></el-input>
  237. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  238. v-model="dialysisPrescription.no_anticoagulant_weichi"></el-input>
  239. </el-form-item>
  240. <el-form-item :label="'维持(mg/h) : '"
  241. v-if="anticoagulant.weichi != -1 && this.$store.getters.xt_user.template_info.template_id == 21 || this.$store.getters.xt_user.template_info.template_id == 23 || this.$store.getters.xt_user.template_info.template_id == 38 || this.$store.getters.xt_user.template_info.org_id == 9987 ">
  242. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  243. v-model="dialysisPrescription.anticoagulant_weichi"></el-input>
  244. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  245. v-model="dialysisPrescription.no_anticoagulant_weichi"></el-input>
  246. </el-form-item>
  247. </div>
  248. <div v-else>
  249. <el-form-item :label="'维持(iu/h) : '"
  250. v-if="anticoagulant.weichi != -1 && dialysisPrescription.anticoagulant != 2">
  251. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  252. v-model="dialysisPrescription.anticoagulant_weichi"></el-input>
  253. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  254. v-model="dialysisPrescription.no_anticoagulant_weichi"></el-input>
  255. </el-form-item>
  256. <el-form-item :label="'维持(mg/h) : '"
  257. v-if="anticoagulant.weichi != -1 && dialysisPrescription.anticoagulant == 2">
  258. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  259. v-model="dialysisPrescription.anticoagulant_weichi"></el-input>
  260. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  261. v-model="dialysisPrescription.no_anticoagulant_weichi"></el-input>
  262. </el-form-item>
  263. </div>
  264. </div>
  265. <div v-else>
  266. <el-form-item v-if="dialysisPrescription.anticoagulant == 2" :label="'维持(mg/h) : '">
  267. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  268. v-model="dialysisPrescription.anticoagulant_weichi"></el-input>
  269. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  270. v-model="dialysisPrescription.no_anticoagulant_weichi"></el-input>
  271. </el-form-item>
  272. <el-form-item :label="'维持(' + anticoagulant.weichi_unit + ') : '" v-else>
  273. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  274. v-model="dialysisPrescription.anticoagulant_weichi"></el-input>
  275. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  276. v-model="dialysisPrescription.no_anticoagulant_weichi"></el-input>
  277. </el-form-item>
  278. </div>
  279. </el-col>
  280. <el-col :span="8" v-if="anticoagulant.zongliang != -1 && isShows('总量')">
  281. <div v-if="this.$store.getters.xt_user.template_info.org_id != 10157">
  282. <div v-if="this.$store.getters.xt_user.template_info.org_id != 10101 && this.$store.getters.xt_user.template_info.template_id != 45">
  283. <el-form-item
  284. v-if='this.$store.getters.xt_user.template_info.template_id != 21 && this.$store.getters.xt_user.template_info.template_id != 23 && this.$store.getters.xt_user.template_info.template_id != 38 && this.$store.getters.xt_user.template_info.org_id != 9987'
  285. :label="'总量(' + anticoagulant.zongliang_unit + ') : '">
  286. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  287. v-model="dialysisPrescription.anticoagulant_zongliang"></el-input>
  288. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  289. v-model="dialysisPrescription.no_anticoagulant_zongliang"></el-input>
  290. </el-form-item>
  291. <el-form-item
  292. v-if='this.$store.getters.xt_user.template_info.template_id == 21 || this.$store.getters.xt_user.template_info.template_id == 23 || this.$store.getters.xt_user.template_info.template_id == 38|| this.$store.getters.xt_user.template_info.org_id == 9987'
  293. :label="'总量(mg) : '">
  294. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  295. v-model="dialysisPrescription.anticoagulant_zongliang"></el-input>
  296. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  297. v-model="dialysisPrescription.no_anticoagulant_zongliang"></el-input>
  298. </el-form-item>
  299. </div>
  300. <div v-else>
  301. <el-form-item
  302. v-if='dialysisPrescription.anticoagulant != 2'
  303. :label="'总量(iu) : '">
  304. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  305. v-model="dialysisPrescription.anticoagulant_zongliang"></el-input>
  306. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  307. v-model="dialysisPrescription.no_anticoagulant_zongliang"></el-input>
  308. </el-form-item>
  309. <el-form-item
  310. v-if='dialysisPrescription.anticoagulant == 2'
  311. :label="'总量(mg) : '">
  312. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  313. v-model="dialysisPrescription.anticoagulant_zongliang"></el-input>
  314. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  315. v-model="dialysisPrescription.no_anticoagulant_zongliang"></el-input>
  316. </el-form-item>
  317. </div>
  318. </div>
  319. <div v-else>
  320. <el-form-item v-if="dialysisPrescription.anticoagulant == 2" :label="'总量(mg) : '">
  321. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  322. v-model="dialysisPrescription.anticoagulant_zongliang"></el-input>
  323. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  324. v-model="dialysisPrescription.no_anticoagulant_zongliang"></el-input>
  325. </el-form-item>
  326. <el-form-item v-else :label="'总量(' + anticoagulant.zongliang_unit + ') : '">
  327. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  328. v-model="dialysisPrescription.anticoagulant_zongliang"></el-input>
  329. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  330. v-model="dialysisPrescription.no_anticoagulant_zongliang"></el-input>
  331. </el-form-item>
  332. </div>
  333. </el-col>
  334. <el-col :span="8"
  335. v-if="isShows('置换量') && (this.$store.getters.xt_user.template_info.template_id == 20 || this.$store.getters.xt_user.template_info.template_id == 28 || this.$store.getters.xt_user.template_info.template_id == 29 || this.$store.getters.xt_user.template_info.template_id == 46)"
  336. v-show="zhiShow">
  337. <el-form-item label="置换量(ml):">
  338. <el-input
  339. type="number"
  340. v-model="dialysisPrescription.replacement_total"
  341. ></el-input>
  342. </el-form-item>
  343. </el-col>
  344. <el-col :span="8"
  345. v-if="isShows('置换量') && this.$store.getters.xt_user.template_info.template_id != 20 && this.$store.getters.xt_user.template_info.template_id != 28 && this.$store.getters.xt_user.template_info.template_id != 29 && this.$store.getters.xt_user.template_info.template_id != 40 && this.$store.getters.xt_user.template_info.template_id != 46"
  346. v-show="zhiShow">
  347. <el-form-item label="置换量(L):">
  348. <el-input
  349. type="number"
  350. v-model="dialysisPrescription.replacement_total"
  351. ></el-input>
  352. </el-form-item>
  353. </el-col>
  354. <el-col :span="8" v-if="isShows('置换速度')" v-show="totalShow">
  355. <el-form-item label="置换速度(ml/min)">
  356. <el-input
  357. v-model="dialysisPrescription.displace_speed"
  358. ></el-input>
  359. </el-form-item>
  360. </el-col>
  361. <el-col
  362. :span="8"
  363. v-if="anticoagulant.gaimingcheng != -1 && isShows('钙名称')"
  364. >
  365. <el-form-item label="钙名称 : ">
  366. <el-input
  367. v-model="dialysisPrescription.anticoagulant_gaimingcheng"
  368. :disabled="anticoagulant.gaimingcheng == 1 ? false : true"
  369. placeholder="钙名称"
  370. ></el-input>
  371. </el-form-item>
  372. </el-col>
  373. <el-col
  374. :span="8"
  375. v-if="anticoagulant.gaijiliang != -1 && isShows('钙剂量')"
  376. >
  377. <el-form-item label="钙剂量(ml) : ">
  378. <el-input
  379. type="number"
  380. v-model="dialysisPrescription.anticoagulant_gaijiliang"
  381. :disabled="anticoagulant.gaijiliang == 1 ? false : true"
  382. placeholder="钙剂量"
  383. ></el-input>
  384. </el-form-item>
  385. </el-col>
  386. <el-col :span="8" v-if="isShows('钾')">
  387. <el-form-item label="钾(mmol/L): ">
  388. <el-input
  389. type="number"
  390. v-model="dialysisPrescription.kalium"
  391. ></el-input>
  392. </el-form-item>
  393. </el-col>
  394. <el-col :span="8" v-if="isShows('钠')">
  395. <el-form-item label="钠(mmol/L):">
  396. <el-input
  397. type="number"
  398. v-model="dialysisPrescription.sodium"
  399. ></el-input>
  400. </el-form-item>
  401. </el-col>
  402. <el-col :span="8" v-if="isShows('钙')">
  403. <el-form-item label="钙(mmol/L):">
  404. <el-input
  405. type="number"
  406. v-model="dialysisPrescription.calcium"
  407. ></el-input>
  408. </el-form-item>
  409. </el-col>
  410. <el-col :span="8" v-if="isShows('碳酸氢盐')">
  411. <el-form-item label="碳酸氢盐(mmol/L):">
  412. <el-input
  413. type="number"
  414. v-model="dialysisPrescription.bicarbonate"
  415. ></el-input>
  416. </el-form-item>
  417. </el-col>
  418. <!-- <el-col :span="8" v-if="isShows('葡萄糖')">
  419. <el-form-item label="葡萄糖(mmol/L):">
  420. <el-input
  421. type="number"
  422. v-model="dialysisPrescription.glucose"
  423. ></el-input>
  424. </el-form-item>
  425. </el-col> -->
  426. <el-col :span="8" v-if="isShows('透析液流量')">
  427. <el-form-item label="透析液流量(ml/min):">
  428. <el-input
  429. type="number"
  430. v-model="dialysisPrescription.dialysate_flow"
  431. ></el-input>
  432. </el-form-item>
  433. </el-col>
  434. <el-col :span="8" v-if="isShows('透析液温度')">
  435. <el-form-item label="透析液温度(°C):">
  436. <el-input
  437. type="number"
  438. v-model="dialysisPrescription.dialysate_temperature"
  439. ></el-input>
  440. </el-form-item>
  441. </el-col>
  442. <el-col :span="8" v-if="isShows('电导率')">
  443. <el-form-item label="电导率(mS/cm): ">
  444. <el-input
  445. type="number"
  446. v-model="dialysisPrescription.conductivity"
  447. ></el-input>
  448. </el-form-item>
  449. </el-col>
  450. <el-col :span="8" v-if="isShows('透析器/灌流器')">
  451. <el-form-item label="透析器/灌流器">
  452. <el-input v-model="dialysisPrescription.dialyzer_perfusion_apparatus"
  453. @focus="showInnerDialog('5')"></el-input>
  454. </el-form-item>
  455. </el-col>
  456. <el-col :span="8" v-if="isShows('透析器')">
  457. <el-form-item label="透析器:">
  458. <el-input v-model="dialysisPrescription.dialysis_dialyszers"
  459. @focus="showInnerDialog('7')"></el-input>
  460. </el-form-item>
  461. </el-col>
  462. <el-col :span="8" v-if="isShows('灌流器')">
  463. <el-form-item label="灌流器:">
  464. <el-input v-model="dialysisPrescription.dialysis_irrigation"
  465. @focus="showInnerDialog('8')"></el-input>
  466. </el-form-item>
  467. </el-col>
  468. <el-col :span="8" v-if="isShows('血浆分离器')">
  469. <el-form-item label="血浆分离器:">
  470. <el-input v-model="dialysisPrescription.plasma_separator"
  471. @focus="showInnerDialog('9')"></el-input>
  472. </el-form-item>
  473. </el-col>
  474. <el-col :span="8" v-if="isShows('胆红素吸附柱')">
  475. <el-form-item label="胆红素吸附柱:">
  476. <el-input v-model="dialysisPrescription.bilirubin_adsorption_column"
  477. @focus="showInnerDialog('10')"></el-input>
  478. </el-form-item>
  479. </el-col>
  480. <el-col :span="8" v-if="isShows('体液过多症状')">
  481. <el-form-item label="体液过多症状:">
  482. <el-select
  483. v-model="dialysisPrescription.body_fluid"
  484. placeholder="请选择"
  485. style="width:100%;"
  486. >
  487. <el-option :key="0" label="请选择" :value="0"></el-option>
  488. <el-option
  489. v-for="(item, index) in body_fluid_option"
  490. :label="item.name"
  491. :key="index + 't'"
  492. :value="item.id"
  493. ></el-option>
  494. </el-select>
  495. </el-form-item>
  496. </el-col>
  497. <el-col :span="8" v-if="isShows('体液过多其他症状')">
  498. <el-form-item label="体液过多其他症状">
  499. <el-input
  500. v-model="dialysisPrescription.body_fluid_other"
  501. ></el-input>
  502. </el-form-item>
  503. </el-col>
  504. <el-col :span="8" v-if="isShows('透析前使用特殊药物')">
  505. <el-form-item label="透析前使用特殊药物">
  506. <el-select
  507. v-model="dialysisPrescription.special_medicine"
  508. placeholder="请选择"
  509. style="width:100%;"
  510. >
  511. <el-option :key="0" label="请选择" :value="0"></el-option>
  512. <el-option
  513. v-for="(item, index) in special_medicine_option"
  514. :label="item.name"
  515. :key="index + 'y'"
  516. :value="item.id"
  517. ></el-option>
  518. </el-select>
  519. </el-form-item>
  520. </el-col>
  521. <el-col :span="8" v-if="isShows('透析前使用其他特殊药物')">
  522. <el-form-item label="透析前使用其他特殊药物">
  523. <el-input
  524. v-model="dialysisPrescription.special_medicine_other"
  525. ></el-input>
  526. </el-form-item>
  527. </el-col>
  528. <el-col :span="8">
  529. <el-form-item
  530. label="置换液:"
  531. v-if="isShows('置换液')"
  532. v-show="huShow"
  533. >
  534. <el-select
  535. v-model="dialysisPrescription.displace_liqui_part"
  536. placeholder="请选择"
  537. >
  538. <el-option :key="0" label="请选择" :value="0"></el-option>
  539. <el-option
  540. v-for="(option, index) in displace_liqui_part_option"
  541. :key="index + 'u'"
  542. :label="option.name"
  543. :value="option.id"
  544. ></el-option>
  545. </el-select>
  546. </el-form-item>
  547. </el-col>
  548. <el-col :span="8"
  549. v-if="isShows('置换液总量') && (this.$store.getters.xt_user.template_info.template_id == 21 || this.$store.getters.xt_user.template_info.template_id == 29 || this.$store.getters.xt_user.template_info.template_id ==24)"
  550. v-show="totalShow">
  551. <el-form-item label="置换液总量(ml)">
  552. <el-input
  553. v-model="dialysisPrescription.displace_liqui_value"
  554. ></el-input>
  555. </el-form-item>
  556. </el-col>
  557. <el-col :span="8"
  558. v-if="isShows('置换液总量') && this.$store.getters.xt_user.template_info.template_id != 21 && this.$store.getters.xt_user.template_info.template_id != 29 && this.$store.getters.xt_user.template_info.template_id !=24"
  559. v-show="totalShow">
  560. <el-form-item label="置换液总量(L)">
  561. <el-input
  562. v-model="dialysisPrescription.displace_liqui_value"
  563. ></el-input>
  564. </el-form-item>
  565. </el-col>
  566. <el-col :span="8" v-if="isShows('目标KT/V')">
  567. <el-form-item label="目标KT/V">
  568. <el-input v-model="dialysisPrescription.target_ktv"></el-input>
  569. </el-form-item>
  570. </el-col>
  571. <el-col :span="8" v-if="isShows('血管通路')">
  572. <el-form-item label="血管通路:">
  573. <el-select
  574. v-model="dialysisPrescription.blood_access"
  575. placeholder="请选择"
  576. >
  577. <el-option :key="0" label="请选择" :value="0"></el-option>
  578. <el-option
  579. v-for="(option, index) in blood_access_option"
  580. :key="index + 'i'"
  581. :label="option.name"
  582. :value="option.id"
  583. ></el-option>
  584. </el-select>
  585. </el-form-item>
  586. </el-col>
  587. <el-col :span="8" v-if="isShows('抗凝提前停止')">
  588. <el-form-item label="抗凝提前停止(h): ">
  589. <el-input
  590. type="number"
  591. v-model="dialysisPrescription.anticoagulant_stop_time_hour"
  592. ></el-input>
  593. </el-form-item>
  594. </el-col>
  595. <el-col :span="8" v-if="isShows('抗凝提前停止')">
  596. <el-form-item label="抗凝提前停止(min): ">
  597. <el-input
  598. type="number"
  599. v-model="dialysisPrescription.anticoagulant_stop_time_min"
  600. ></el-input>
  601. </el-form-item>
  602. </el-col>
  603. <el-col :span="8" v-if="isShows('抽血')">
  604. <el-form-item label="抽血:">
  605. <el-input v-model="dialysisPrescription.blood" @focus="showInnerDialog('6')"></el-input>
  606. </el-form-item>
  607. </el-col>
  608. <el-col :span="8" v-if="isShows('病情')">
  609. <el-form-item label="病情:">
  610. <el-select v-model="dialysisPrescription.illness" placeholder="请选择">
  611. <el-option :key="0" label="请选择" :value="0"></el-option>
  612. <el-option
  613. v-for="(item, index) in illnessList "
  614. :key="index"
  615. :label="item.name"
  616. :value="item.id"
  617. ></el-option>
  618. </el-select>
  619. </el-form-item>
  620. </el-col>
  621. <el-col :span="8" v-if="isShows('葡萄糖')">
  622. <el-form-item label="葡萄糖:">
  623. <el-input v-model="dialysisPrescription.amylaceum"></el-input>
  624. </el-form-item>
  625. </el-col>
  626. <el-col :span="8" v-if="isShows('置换流量')">
  627. <el-form-item label="置换流量(L/h):">
  628. <el-input v-model="dialysisPrescription.replacement_flow"></el-input>
  629. </el-form-item>
  630. </el-col>
  631. <el-col :span="8" v-if="isShows('吸氧')">
  632. <el-form-item label="吸氧:">
  633. <el-select v-model="dialysisPrescription.oxygen_uptake" placeholder="请选择"
  634. @change="changeOxygenList">
  635. <el-option :key="0" label="请选择" :value="0"></el-option>
  636. <el-option
  637. v-for="(item, index) in oxygenList "
  638. :key="index"
  639. :label="item.name"
  640. :value="item.id"
  641. ></el-option>
  642. </el-select>
  643. </el-form-item>
  644. </el-col>
  645. <el-col :span="8" v-if="isShows('吸氧') && oxygenShow == true">
  646. <el-form-item label="吸氧流量(L/分):">
  647. <el-input v-model="dialysisPrescription.oxygen_flow"></el-input>
  648. </el-form-item>
  649. </el-col>
  650. <el-col :span="8" v-if="isShows('吸氧') && oxygenShow == true">
  651. <el-form-item label="吸氧时长(h):">
  652. <el-input v-model="dialysisPrescription.oxygen_time"></el-input>
  653. </el-form-item>
  654. </el-col>
  655. <el-col :span="8" v-if="isShows('透析管路')">
  656. <el-form-item label="透析管路:">
  657. <el-select
  658. v-model="dialysisPrescription.hemodialysis_pipelines"
  659. placeholder="请选择"
  660. style="width:100%;"
  661. >
  662. <el-option :key="0" label="请选择" :value="0"></el-option>
  663. <el-option
  664. v-for="(item, index) in hemodialysisPipelinesOptions"
  665. :label="item.name"
  666. :key="index + 't'"
  667. :value="item.name"
  668. ></el-option>
  669. </el-select>
  670. </el-form-item>
  671. </el-col>
  672. <el-col :span="8" v-if="isShows('透析管路支数')">
  673. <el-form-item label="透析管路支数">
  674. <el-input oninput="value=value.replace(/\D|^0/g,'')" v-model="dialysisPrescription.hemodialysis_pipelines_count"
  675. ></el-input>
  676. </el-form-item>
  677. </el-col>
  678. <el-col :span="8" v-if="isShows('穿刺针')">
  679. <el-form-item label="穿刺针">
  680. <el-input v-model="dialysisPrescription.puncture_needle"
  681. @focus="showInnerDialog('11')"></el-input>
  682. </el-form-item>
  683. </el-col>
  684. <el-col :span="8" v-if="isShows('穿刺针支数')">
  685. <el-form-item label="穿刺针支数">
  686. <el-input oninput="value=value.replace(/\D|^0/g,'')" v-model="dialysisPrescription.puncture_needle_count"
  687. ></el-input>
  688. </el-form-item>
  689. </el-col>
  690. <el-col :span="8" v-if="isShows('促红素')">
  691. <el-form-item label="促红素:">
  692. <el-select
  693. v-model="dialysisPrescription.epo"
  694. placeholder="请选择"
  695. style="width:100%;"
  696. >
  697. <el-option :key="0" label="请选择" :value="0"></el-option>
  698. <el-option
  699. v-for="(item, index) in epoOptions"
  700. :label="item.name"
  701. :key="index + 't'"
  702. :value="item.name"
  703. ></el-option>
  704. </el-select>
  705. </el-form-item>
  706. </el-col>
  707. <el-col :span="8" v-if="isShows('促红素支数')">
  708. <el-form-item label="促红素支数">
  709. <el-input oninput="value=value.replace(/\D|^0/g,'')" v-model="dialysisPrescription.epo_count"></el-input>
  710. </el-form-item>
  711. </el-col>
  712. <el-col :span="8" v-if="isShows('最大超滤率')">
  713. <el-form-item label="最大超滤率(ml/h)">
  714. <el-input oninput="value=value.replace(/\D|^0/g,'')" v-model="dialysisPrescription.max_ultrafiltration_rate"></el-input>
  715. </el-form-item>
  716. </el-col>
  717. </el-row>
  718. <el-row :gutter="20">
  719. <el-col :span="24">
  720. <el-form-item label="备注: ">
  721. <el-input
  722. type="textarea"
  723. v-model="dialysisPrescription.remark"
  724. :rows="5"
  725. ></el-input>
  726. </el-form-item>
  727. </el-col>
  728. </el-row>
  729. </el-form>
  730. <span slot="footer" class="dialog-footer">
  731. <el-button @click="handleCancle">取 消</el-button>
  732. <!-- <el-button type="primary" @click="handleCommit" v-if="isPermission()">保 存</el-button> -->
  733. <el-button type="primary" @click="handleCommit" :loading="isLoading">保 存</el-button>
  734. <el-button type="primary" @click="handleSolution" :loading="isLoading"
  735. >保存为长期处方</el-button
  736. >
  737. </span>
  738. </el-dialog>
  739. <el-dialog
  740. title="长期医嘱推送"
  741. :visible.sync="isShowRemindAdvice"
  742. width="1010px"
  743. :modal-append-to-body="false"
  744. :append-to-body="true"
  745. >
  746. <div style='display:flex;align-items:center;'>
  747. <span style="font-weight: bold;color: #409eff;width:80px;">开始时间:</span>
  748. <el-date-picker
  749. type="datetime"
  750. format="yyyy-MM-dd HH:mm"
  751. value-format="yyyy-MM-dd HH:mm"
  752. placeholder="选择时间"
  753. v-model="start_time"
  754. ></el-date-picker>
  755. <!--<span style="display: inline-block;border: 1px solid #ccc;padding: 10px 20px;border-radius: 5px;" @click="changeStartTime">{{ advice_start_time }}</span>-->
  756. </div>
  757. <el-checkbox-group v-model="checkedCities">
  758. <el-checkbox
  759. style="display: flex;align-items: center"
  760. v-for="(advice, index) in targetAdvices"
  761. :label="advice.id"
  762. :key="index+'q'"
  763. :value="advice.id"
  764. :name="advice.id"
  765. >
  766. <div style="padding-top: 10px;padding-left: 10px">
  767. 开嘱医生&nbsp;{{ getDoctorName(advice.advice_doctor) }}
  768. </div>
  769. <br/>
  770. <div style="padding-left: 10px">
  771. 开嘱时间&nbsp;{{ getTime(advice.created_time) }}
  772. </div>
  773. <br/>
  774. <div style="padding-bottom: 10px;padding-left: 10px">
  775. 医嘱内容&nbsp;{{ getContent(advice) }}
  776. </div>
  777. <div
  778. style="padding-bottom: 10px;padding-left: 10px"
  779. v-if="advice.frequency_type == 1"
  780. >
  781. 推送频率 每次必推
  782. </div>
  783. <div
  784. style="padding-bottom: 10px;padding-left: 10px"
  785. v-if="advice.frequency_type == 2"
  786. >
  787. 推送频率&nbsp;{{ advice.day_count }}天/次
  788. </div>
  789. <div
  790. style="padding-bottom: 10px;padding-left: 10px"
  791. v-if="advice.frequency_type == 3"
  792. >
  793. 推送频率&nbsp;每周{{ advice.week_day }}
  794. </div>
  795. </el-checkbox>
  796. </el-checkbox-group>
  797. <span slot="footer" class="dialog-footer">
  798. <el-button @click="handleAdviceCancle">取 消</el-button>
  799. <el-button type="primary" @click="handleAdviceCommit" :loading="isLoading">保 存</el-button>
  800. </span>
  801. </el-dialog>
  802. <el-dialog
  803. :title="patient.name"
  804. :visible.sync="msgtip_visibility"
  805. :close-on-click-modal="false"
  806. :close-on-press-escape="false"
  807. :show-close="false"
  808. width="30%"
  809. >
  810. <div class="newLine">
  811. <span>本次透析日期</span>
  812. <span>{{ dialysis_date }}</span>
  813. </div>
  814. <div class="newLine">
  815. <span>透前称重(kg)</span>
  816. <span>{{ getBeforeWeight(predialysis) }}</span>
  817. </div>
  818. <div class="newLine">
  819. <span>干体重(kg)</span>
  820. <span>{{ getDryWeight() }}</span>
  821. </div>
  822. <div class="newLine">
  823. <span>衣物重(kg)</span>
  824. <span>{{ predialysis.additional_weight }}</span>
  825. </div>
  826. <div class="newLine">
  827. <span>体重增加(kg)</span>
  828. <span>{{ add_weight }}</span>
  829. </div>
  830. <div class="newLine">
  831. <span>透后称重(kg)</span>
  832. <span>{{ getAfterWeight(record) }}</span>
  833. </div>
  834. <div class="newLine">
  835. <span>体重减少(kg)</span>
  836. <span>{{ record.weight_loss }}</span>
  837. </div>
  838. <div class="newLine">
  839. <span>上次透后称重(kg)</span>
  840. <span>{{ getLastAfterWeight(last_record) }}</span>
  841. </div>
  842. <span slot="footer" class="dialog-footer">
  843. <el-button @click="cancleMsg()">取 消</el-button>
  844. <el-button type="primary" @click="cancleMsg()">确 定</el-button>
  845. </span>
  846. </el-dialog>
  847. <multi-select-box
  848. :propsForm="InnerDialogProps"
  849. v-on:dialog-comfirm="innerDialogComfirm"
  850. v-on:dialog-cancle="innerDialogCancle"
  851. ></multi-select-box>
  852. </div>
  853. </template>
  854. <script>
  855. import { CreateGroupAdvice, GetSolution, postPrescription, postSoulution } from '@/api/dialysis'
  856. import { getDataConfig } from '@/utils/data'
  857. import { calculateAnticoagulantZL, uParseTime } from '@/utils/tools'
  858. import store from '@/store'
  859. import MsgTip from './MsgTip'
  860. import request from '@/utils/request'
  861. import multiSelectBox from './MultiSelectBox'
  862. export default {
  863. name: 'dialysisPrescriptionDialog',
  864. components: { MsgTip, multiSelectBox },
  865. props: {
  866. mode_id: {
  867. type: Number
  868. },
  869. schedual: {
  870. type: Object
  871. },
  872. is_open: {
  873. type: Number,
  874. default: () => {
  875. return 0
  876. }
  877. },
  878. waitUploadAdvices: {
  879. type: Array,
  880. default: () => {
  881. return []
  882. }
  883. },
  884. targetAdvices: {
  885. type: Array,
  886. default: () => {
  887. return []
  888. }
  889. },
  890. admin_users: {
  891. type: Array,
  892. default: () => {
  893. return []
  894. }
  895. },
  896. niprocart_info: {
  897. type: Array,
  898. default: () => {
  899. return []
  900. }
  901. },
  902. jms_info: {
  903. type: Array,
  904. default: () => {
  905. return []
  906. }
  907. },
  908. fistula_needle_set_info: {
  909. type: Array,
  910. default: () => {
  911. return []
  912. }
  913. },
  914. fistula_needle_set_16_info: {
  915. type: Array,
  916. default: () => {
  917. return []
  918. }
  919. },
  920. hemoperfusion_info: {
  921. type: Array,
  922. default: () => {
  923. return []
  924. }
  925. },
  926. dialyser_sterilised_info: {
  927. type: Array,
  928. default: () => {
  929. return []
  930. }
  931. },
  932. filtryzer_info: {
  933. type: Array,
  934. default: () => {
  935. return []
  936. }
  937. },
  938. dialyzers_info: {
  939. type: Array,
  940. default: () => {
  941. return []
  942. }
  943. },
  944. injector_info: {
  945. type: Array,
  946. default: () => {
  947. return []
  948. }
  949. },
  950. bloodlines_info: {
  951. type: Array,
  952. default: () => {
  953. return []
  954. }
  955. },
  956. tubingHemodialysis_info: {
  957. type: Array,
  958. default: () => {
  959. return []
  960. }
  961. },
  962. safe_package_info: {
  963. type: Array,
  964. default: () => {
  965. return []
  966. }
  967. },
  968. aliquid_info: {
  969. type: Array,
  970. default: () => {
  971. return []
  972. }
  973. },
  974. config: {
  975. type: Object,
  976. default: () => {
  977. return { id: 0 }
  978. }
  979. },
  980. prescription: {
  981. // 透析处方
  982. type: Object,
  983. default: () => {
  984. return { id: 0 }
  985. }
  986. },
  987. solution: {
  988. // 长期处方
  989. type: Object,
  990. default: () => {
  991. return { id: 0 }
  992. }
  993. },
  994. dialysis_order: {
  995. // 透析记录
  996. type: Object,
  997. default: () => {
  998. return { id: 0 }
  999. }
  1000. },
  1001. patient: {
  1002. // 患者信息
  1003. type: Object,
  1004. default: () => {
  1005. return { id: 0 }
  1006. }
  1007. },
  1008. devices: {
  1009. type: Array,
  1010. default: function() {
  1011. return new Array()
  1012. }
  1013. },
  1014. predialysis: {
  1015. type: Object,
  1016. default: () => {
  1017. return { id: 0 }
  1018. }
  1019. },
  1020. last_predialysis: {
  1021. type: Object,
  1022. default: () => {
  1023. return { id: 0 }
  1024. }
  1025. },
  1026. record: {
  1027. type: Object,
  1028. default: () => {
  1029. return { id: 0 }
  1030. }
  1031. },
  1032. last_record: {
  1033. type: Object,
  1034. default: () => {
  1035. return { id: 0 }
  1036. }
  1037. },
  1038. dry_weight: {
  1039. type: Object,
  1040. default: () => {
  1041. return { id: 0 }
  1042. }
  1043. },
  1044. last_prescription: {
  1045. type: Object,
  1046. default: () => {
  1047. return { id: 0 }
  1048. }
  1049. },
  1050. scheudle_mode: Number,
  1051. stockType: {
  1052. type: Array,
  1053. default: () => {
  1054. return []
  1055. }
  1056. },
  1057. lastAssessment: {
  1058. type: Object,
  1059. default: () => {
  1060. return { id: 0 }
  1061. }
  1062. }
  1063. },
  1064. computed: {
  1065. dialysis_date: function() {
  1066. if (this.$route.query.date) {
  1067. return uParseTime(this.$route.query.date, '{y}/{m}/{d}')
  1068. } else {
  1069. return this.record_date
  1070. }
  1071. }
  1072. },
  1073. data() {
  1074. return {
  1075. InnerDialogProps: {
  1076. values: [],
  1077. visibility: false,
  1078. isShowTextArea: true,
  1079. customContent: '',
  1080. titles: '',
  1081. type: '' // 不同弹框类型,用来匹配数据
  1082. },
  1083. advice_start_time: '',
  1084. showTxt: '',
  1085. start_time: '',
  1086. hasPermission: true,
  1087. zhiShow: false,
  1088. totalShow: false,
  1089. huShow: false,
  1090. showName: '',
  1091. isShowRemindAdvice: false,
  1092. checkedCities: [],
  1093. isVisibility: false,
  1094. isShowTime: false,
  1095. isClose: false,
  1096. isShow: false,
  1097. record_date: '',
  1098. time: '',
  1099. treatment_mode: [],
  1100. timeValue: '',
  1101. deviceList: [],
  1102. replacement_ways: [],
  1103. anticoagulantsConfit: {},
  1104. dialysate_formulation_options: [],
  1105. add_weight: 0,
  1106. body_fluid_option: [],
  1107. special_medicine_option: [],
  1108. displace_liqui_part_option: [],
  1109. blood_access_option: [],
  1110. is_pre: 0,
  1111. msgtip_visibility: false,
  1112. dialysisPrescription: {
  1113. replacement_total: '',
  1114. mode_id: '',
  1115. dialysis_duration: '',
  1116. dialysis_duration_hour: '',
  1117. dialysis_duration_minute: '',
  1118. mode_name: '',
  1119. dialyzer: '',
  1120. perfusion_apparatus: '',
  1121. blood_flow_volume: '',
  1122. dewater_amount: '',
  1123. displace_liqui: '',
  1124. replacement_way: '',
  1125. anticoagulant: '',
  1126. anticoagulant_shouji: '',
  1127. anticoagulant_weichi: '',
  1128. anticoagulant_zongliang: '',
  1129. anticoagulant_gaimingcheng: '',
  1130. anticoagulant_gaijiliang: '',
  1131. kalium: '',
  1132. sodium: '',
  1133. calcium: '',
  1134. bicarbonate: '',
  1135. glucose: '',
  1136. dry_weight: '',
  1137. dialysate_flow: '',
  1138. dialysate_temperature: '',
  1139. target_ultrafiltration: '',
  1140. dialysate_formulation: '',
  1141. conductivity: '',
  1142. doctor: '',
  1143. remark: '',
  1144. dialyzer_perfusion_apparatus: '',
  1145. body_fluid: '',
  1146. body_fluid_other: '',
  1147. special_medicine: '',
  1148. special_medicine_other: '',
  1149. displace_liqui_part: '',
  1150. displace_liqui_value: '',
  1151. ultrafiltration: '',
  1152. blood_access: '',
  1153. niprocart: '',
  1154. jms: '',
  1155. fistula_needle_set: '',
  1156. fistula_needle_set_16: '',
  1157. hemoperfusion: '',
  1158. dialyser_sterilised: '',
  1159. filtryzer: '',
  1160. target_ktv: '',
  1161. dialyzers: '',
  1162. injector: '',
  1163. bloodlines: '',
  1164. tubing_hemodialysis: '',
  1165. package: '',
  1166. a_liquid: '',
  1167. no_anticoagulant_shouji: '0',
  1168. no_anticoagulant_weichi: '0',
  1169. no_anticoagulant_zongliang: '0',
  1170. creater: 0,
  1171. pre_impulse: 0, //预冲量
  1172. anticoagulant_stop_time_hour: '',
  1173. anticoagulant_stop_time_min: '',
  1174. push_the_protamine: '',//下机前推注鱼精蛋白
  1175. heparin_sodium: '', //肝素钠
  1176. nucleoprotamine: '',//鱼精蛋白
  1177. no_heparin_remarks: '',
  1178. blood: '',
  1179. dialysis_dialyszers: '',
  1180. dialysis_irrigation: '',
  1181. irrigation: '',
  1182. antioxidant_commodity_name: '',
  1183. displace_speed: '',
  1184. illness: '',
  1185. amylaceum: '',
  1186. single_time: '',
  1187. single_water: '',
  1188. replacement_flow: '',
  1189. plasma_separator: '',
  1190. bilirubin_adsorption_column: '',
  1191. oxygen_uptake: '',
  1192. oxygen_flow: '',
  1193. oxygen_time: '',
  1194. hemodialysis_pipelines: '',
  1195. hemodialysis_pipelines_count: '',
  1196. puncture_needle: '',
  1197. puncture_needle_count: '',
  1198. epo: '',
  1199. epo_count: '',
  1200. max_ultrafiltration_rate:'',
  1201. hemodialysisPipelinesOptions: [],
  1202. punctureNeedleOptions: [],
  1203. epoOptions: [],
  1204. impulse:0,
  1205. },
  1206. anticoagulant: {
  1207. id: 0,
  1208. name: '',
  1209. type: 1,
  1210. shouji: 1,
  1211. weichi: 1,
  1212. zongliang: 1,
  1213. gaimingcheng: -1,
  1214. gaijiliang: -1,
  1215. shouji_unit: 'mg',
  1216. weichi_unit: 'mg/h',
  1217. zongliang_unit: 'mg',
  1218. gaimingcheng_unit: '',
  1219. gaijiliang_unit: ''
  1220. },
  1221. doctorAdvices: [],
  1222. dialyzerPerfusionApparatus: [],
  1223. bloods: [],
  1224. irrigations: [],
  1225. dialyzers: [],
  1226. illnessList: [],
  1227. plasmaSeparatorList: [],
  1228. bilirubinAdsorptionColumn: [],
  1229. oxygenList: [
  1230. { id: 1, name: '需' },
  1231. { id: 2, name: '无' }
  1232. ],
  1233. oxygenShow: false,
  1234. hemodialysisPipelinesOptions: [],
  1235. epoOptions: [],
  1236. isLoading: false
  1237. }
  1238. },
  1239. methods: {
  1240. changeOxygenList(val) {
  1241. if (val == 1) {
  1242. this.oxygenShow = true
  1243. }
  1244. if (val == 2) {
  1245. this.oxygenShow = false
  1246. this.prescription.oxygen_flow = ''
  1247. this.prescription.oxygen_time = ''
  1248. }
  1249. },
  1250. changeTime: function(val) {
  1251. this.advice_start_time = val
  1252. },
  1253. showInnerDialog: function(val) {
  1254. this.InnerDialogProps.visibility = true
  1255. switch (val) {
  1256. case '5': // 透析器/灌流器
  1257. this.InnerDialogProps.values = this.dialyzerPerfusionApparatus
  1258. this.InnerDialogProps.titles = '透析器/灌流器'
  1259. this.InnerDialogProps.type = 'dialyzer_perfusion_apparatus'
  1260. this.InnerDialogProps.selected = this.dialysisPrescription.dialyzer_perfusion_apparatus
  1261. this.InnerDialogProps.isShowTextArea = false
  1262. break
  1263. case '6': // 透析器/灌流器
  1264. this.InnerDialogProps.values = this.bloods
  1265. this.InnerDialogProps.titles = '抽血'
  1266. this.InnerDialogProps.type = 'blood'
  1267. this.InnerDialogProps.selected = this.dialysisPrescription.blood
  1268. this.InnerDialogProps.isShowTextArea = false
  1269. case '7': // 透析器
  1270. for (let i = 0; i < this.dialyzers.length; i++) {
  1271. this.dialyzers[i].name = this.dialyzers[i].specification_name
  1272. }
  1273. this.InnerDialogProps.values = this.dialyzers
  1274. this.InnerDialogProps.titles = '透析器'
  1275. this.InnerDialogProps.type = 'dialyzers'
  1276. this.InnerDialogProps.selected = this.dialysisPrescription.dialysis_dialyszers
  1277. this.InnerDialogProps.isShowTextArea = false
  1278. break
  1279. case '8':
  1280. for (let i = 0; i < this.irrigations.length; i++) {
  1281. this.irrigations[i].name = this.irrigations[i].specification_name
  1282. }
  1283. this.InnerDialogProps.values = this.irrigations
  1284. this.InnerDialogProps.titles = '透析器'
  1285. this.InnerDialogProps.type = 'irrigations'
  1286. this.InnerDialogProps.selected = this.dialysisPrescription.dialysis_irrigation
  1287. this.InnerDialogProps.isShowTextArea = false
  1288. break
  1289. case '9': // 血浆灌流器
  1290. this.InnerDialogProps.values = this.plasmaSeparatorList
  1291. this.InnerDialogProps.titles = '血浆灌流器'
  1292. this.InnerDialogProps.type = 'plasma_separator'
  1293. this.InnerDialogProps.selected = this.dialysisPrescription.plasma_separator
  1294. this.InnerDialogProps.isShowTextArea = false
  1295. break
  1296. case '10': // 胆红素吸附柱
  1297. this.InnerDialogProps.values = this.bilirubinAdsorptionColumn
  1298. this.InnerDialogProps.titles = '胆红素吸附柱'
  1299. this.InnerDialogProps.type = 'bilirubin_adsorption_column'
  1300. this.InnerDialogProps.selected = this.dialysisPrescription.bilirubin_adsorption_column
  1301. this.InnerDialogProps.isShowTextArea = false
  1302. break
  1303. case '11': //穿刺针
  1304. this.InnerDialogProps.values = this.punctureNeedleOptions
  1305. this.InnerDialogProps.titles = '穿刺针'
  1306. this.InnerDialogProps.type = 'puncture_needle'
  1307. this.InnerDialogProps.selected = this.dialysisPrescription.puncture_needle
  1308. this.InnerDialogProps.isShowTextArea = false
  1309. break
  1310. }
  1311. },
  1312. innerDialogComfirm: function(val) {
  1313. this.InnerDialogProps.visibility = false
  1314. switch (val.type) {
  1315. case 'dialyzer_perfusion_apparatus':
  1316. this.dialysisPrescription.dialyzer_perfusion_apparatus = val.value.join(',')
  1317. break
  1318. case 'blood':
  1319. this.dialysisPrescription.blood = val.value.join(',')
  1320. break
  1321. case 'dialyzers':
  1322. this.dialysisPrescription.dialysis_dialyszers = val.value.join(',')
  1323. break
  1324. case 'irrigations':
  1325. this.dialysisPrescription.dialysis_irrigation = val.value.join(',')
  1326. break
  1327. case 'plasma_separator':
  1328. this.dialysisPrescription.plasma_separator = val.value.join(',')
  1329. break
  1330. case 'bilirubin_adsorption_column':
  1331. this.dialysisPrescription.bilirubin_adsorption_column = val.value.join(',')
  1332. break
  1333. case 'puncture_needle':
  1334. this.dialysisPrescription.puncture_needle = val.value.join(',')
  1335. break
  1336. }
  1337. },
  1338. innerDialogCancle: function() {
  1339. this.InnerDialogProps.visibility = false
  1340. },
  1341. getDryWeight() {
  1342. if (this.dry_weight != null && this.dry_weight.id > 0) {
  1343. return this.dry_weight.dry_weight
  1344. } else {
  1345. if (this.last_predialysis != null && this.last_predialysis.id > 0) {
  1346. return this.last_predialysis.dry_weight
  1347. } else {
  1348. return ''
  1349. }
  1350. }
  1351. },
  1352. getLastAfterWeight(record) {
  1353. if (record != null && record.id > 0) {
  1354. if (record.weight_after > 0) {
  1355. let additional_weight = 0
  1356. if (this.predialysis.additional_weight != undefined) {
  1357. additional_weight = this.predialysis.additional_weight
  1358. }
  1359. return parseFloat(record.weight_after - additional_weight).toFixed(1)
  1360. } else {
  1361. return ''
  1362. }
  1363. }
  1364. },
  1365. getBeforeWeight(predialysis) {
  1366. if (predialysis.id > 0) {
  1367. if (predialysis.weight_before > 0) {
  1368. return parseFloat(predialysis.weight_before - predialysis.additional_weight).toFixed(1)
  1369. } else {
  1370. return ''
  1371. }
  1372. }
  1373. },
  1374. getAfterWeight(record) {
  1375. if (record.id > 0) {
  1376. if (record.weight_after > 0) {
  1377. return parseFloat(record.weight_after - this.predialysis.additional_weight).toFixed(1)
  1378. } else {
  1379. return ''
  1380. }
  1381. }
  1382. },
  1383. setLastRecord: function(schedual, lastAssessmentAfterDislysis, lastPredialysisEvaluation, lastDialysisPrescribe, lastDryWeightDislysis, system_prescribe) {
  1384. this.treatment_mode = this.$store.getters.treatment_mode
  1385. // console.log("99999",this.treatment_mode)
  1386. this.perfusion_apparatus = getDataConfig(
  1387. 'hemodialysis',
  1388. 'perfusion_apparatus'
  1389. )
  1390. this.replacement_ways = getDataConfig('hemodialysis', 'replacement_ways')
  1391. this.dialysate_formulation_options = getDataConfig(
  1392. 'hemodialysis',
  1393. 'dialysate_formulation'
  1394. )
  1395. // this.anticoagulantsConfit = this.$store.getters.anticoagulants_confit
  1396. var anticoagulantsConfitOne = this.$store.getters.anticoagulants_confit
  1397. // for (let i = 0; i < anticoagulantsConfitOne.length; i++) {
  1398. // console.log('anticoagulantsConfitOne', anticoagulantsConfitOne[i].name)
  1399. // }
  1400. // var anticoagulantsConfit = getDataConfig('hemodialysis', 'anticoagulant')
  1401. // const arr = []
  1402. // anticoagulantsConfit.map((item, index) => {
  1403. // const objChild = { ...item }
  1404. // arr.push(objChild)
  1405. // })
  1406. // var arrthree = {}
  1407. // arrthree = { ...arr }
  1408. // console.log('arrthree', arrthree)
  1409. const arrFour = []
  1410. Object.keys(anticoagulantsConfitOne).map((item, index) => {
  1411. if (index != 2) {
  1412. arrFour.push(anticoagulantsConfitOne[item])
  1413. }
  1414. })
  1415. this.anticoagulantsConfit = arrFour
  1416. this.dialysisList = this.devices
  1417. this.body_fluid_option = this.$store.getters.body_fluid
  1418. this.special_medicine_option = this.$store.getters.special_medicine
  1419. this.displace_liqui_part_option = this.$store.getters.displace_liqui
  1420. this.hemodialysisPipelinesOptions = getDataConfig('hemodialysis', 'hemodialysis_pipelines')
  1421. this.punctureNeedleOptions = getDataConfig('hemodialysis', 'puncture_needle')
  1422. this.epoOptions = getDataConfig('hemodialysis', 'epo')
  1423. // this.blood_access_option = this.$store.getters.blood_access_internal_fistula;
  1424. this.blood_access_option = getDataConfig(
  1425. 'hemodialysis',
  1426. 'vascular_access_desc'
  1427. )
  1428. // console.log('血管通路', this.blood_access_option)
  1429. this.dialyzerPerfusionApparatus = getDataConfig(
  1430. 'hemodialysis',
  1431. 'dialyzer_perfusion_apparatus'
  1432. )
  1433. // console.log('3333333', this.dialyzerPerfusionApparatus)
  1434. this.bloods = getDataConfig(
  1435. 'hemodialysis',
  1436. 'blood'
  1437. )
  1438. // dialyzerPerfusionApparatus.map(item => {
  1439. // item.name = item.name.toUpperCase()
  1440. // })
  1441. // //去重
  1442. // var arr = this.unique(dialyzerPerfusionApparatus)
  1443. // this.dialyzerPerfusionApparatus = arr
  1444. // console.log('灌流器', arr)
  1445. if (this.$route.query && this.$route.query.date) {
  1446. var date = this.$route.query && this.$route.query.date
  1447. this.record_date = uParseTime(date, '{y}-{m}-{d}')
  1448. } else {
  1449. var date = schedual.schedule_date
  1450. this.record_date = uParseTime(date, '{y}-{m}-{d}')
  1451. }
  1452. if (this.prescription != null && typeof this.prescription.id !== 'undefined' && this.prescription.id > 0) {
  1453. for (const key in this.prescription) {
  1454. this.dialysisPrescription[key] = this.prescription[key]
  1455. }
  1456. } else if (this.solution != null && typeof this.solution.id !== 'undefined' && this.solution.id > 0) {
  1457. for (const key in this.solution) {
  1458. if (key != 'target_ultrafiltration') {
  1459. this.dialysisPrescription[key] = this.solution[key]
  1460. }
  1461. }
  1462. } else if (lastDialysisPrescribe != null && typeof lastDialysisPrescribe.id !== 'undefined' && lastDialysisPrescribe.id > 0) {
  1463. for (const key in lastDialysisPrescribe) {
  1464. if (key != 'target_ultrafiltration') {
  1465. this.dialysisPrescription[key] = lastDialysisPrescribe[key]
  1466. }
  1467. }
  1468. } else if (system_prescribe != null && typeof system_prescribe.id !== 'undefined' && system_prescribe.id > 0) {
  1469. for (const key in system_prescribe) {
  1470. if (key != 'target_ultrafiltration') {
  1471. this.dialysisPrescription[key] = system_prescribe[key]
  1472. }
  1473. }
  1474. } else {
  1475. if (schedual.mode_id == 2 || schedual.mode_id == 5 || schedual.mode_id == 12) {
  1476. this.zhiShow = true
  1477. this.huShow = true
  1478. this.totalShow = true
  1479. } else {
  1480. this.zhiShow = false
  1481. this.huShow = false
  1482. this.totalShow = false
  1483. }
  1484. // this.dialysisPrescription.mode_id = schedual.mode_id
  1485. }
  1486. var thismode = parseInt(this.dialysisPrescription.anticoagulant)
  1487. if (isNaN(thismode) || thismode <= 0) {
  1488. return false
  1489. }
  1490. if (
  1491. typeof this.anticoagulantsConfit[thismode] === 'undefined' ||
  1492. this.anticoagulantsConfit[thismode] == null
  1493. ) {
  1494. return false
  1495. }
  1496. this.anticoagulant = this.$store.getters.anticoagulants_confit[thismode]
  1497. },
  1498. menuMsgTip: function() {
  1499. this.msgtip_visibility = false
  1500. this.isVisibility = true
  1501. },
  1502. handleAdviceCommit() {
  1503. //
  1504. let results = []
  1505. for (let i = 0; i < this.targetAdvices.length; i++) {
  1506. for (let a = 0; a < this.checkedCities.length; a++) {
  1507. if (this.targetAdvices[i].id == this.checkedCities[a]) {
  1508. results.push(this.targetAdvices[i])
  1509. }
  1510. }
  1511. }
  1512. var obj5 = {}
  1513. results = results.reduce((cur, next) => {
  1514. obj5[next.id] ? '' : (obj5[next.id] = true && cur.push(next))
  1515. return cur
  1516. }, [])
  1517. var date = new Date()
  1518. var hour = date.getHours() < 10 ? '0' + date.getHours() : date.getHours()
  1519. var minute =
  1520. date.getMinutes() < 10 ? '0' + date.getMinutes() : date.getMinutes()
  1521. if (results.length > 0) {
  1522. if(!this.isLoading){
  1523. if (this.is_pre == 1) {
  1524. if (this.patient.id <= 0) {
  1525. this.$message.error('没有选择患者')
  1526. this.loading = false
  1527. return
  1528. }
  1529. var arr = this.dialysisPrescription
  1530. // console.log('arr', arr)
  1531. const ParamsQuery = arr
  1532. // console.log('医嘱推送2', ParamsQuery)
  1533. ParamsQuery['patient'] = this.patient.id
  1534. ParamsQuery['record_date'] = this.record_date
  1535. ParamsQuery['patient_id'] = this.$route.query.patient_id
  1536. if (this.prescription.creater <= 0) {
  1537. ParamsQuery['mode'] = '1'
  1538. } else {
  1539. ParamsQuery['mode'] = '2'
  1540. if (
  1541. this.$store.getters.xt_user.user.id !=
  1542. this.dialysisPrescription.creater
  1543. ) {
  1544. ParamsQuery['mode'] = '3'
  1545. }
  1546. }
  1547. this.isLoading = true
  1548. postPrescription(ParamsQuery).then(response => {
  1549. if (response.data.state == 0) {
  1550. this.$message.error(response.data.msg)
  1551. this.isLoading = false
  1552. return false
  1553. } else {
  1554. this.$notify({
  1555. title: '成功',
  1556. message: '提交成功',
  1557. type: 'success',
  1558. duration: 2000
  1559. })
  1560. var date = new Date()
  1561. // console.log(this.start_time)
  1562. const params = {
  1563. advices: results,
  1564. advice_date: this.start_time.split(' ')[0],
  1565. advice_doctor: results[0].advice_doctor,
  1566. advice_type: results[0].advice_type,
  1567. parent_id: this.patient_id,
  1568. start_time: this.start_time,
  1569. remark: ''
  1570. }
  1571. CreateGroupAdvice(this.$route.query.patient_id, 0, params).then(
  1572. rs => {
  1573. var resp = rs.data
  1574. if (resp.state == 1) {
  1575. this.doctorAdvices = resp.data.advices
  1576. this.$emit('advice')
  1577. this.isLoading = false
  1578. } else {
  1579. this.isLoading = false
  1580. }
  1581. }
  1582. )
  1583. const prescription_resp = response.data.data.prescription
  1584. var prescription = this.prescription
  1585. for (var index in prescription_resp) {
  1586. // prescription[index] = prescription_resp[index];
  1587. this.$set(prescription, index, prescription_resp[index])
  1588. }
  1589. this.hide()
  1590. }
  1591. })
  1592. } else if (this.is_pre == 2) {
  1593. if (this.patient.id <= 0) {
  1594. this.$message.error('没有选择患者')
  1595. this.loading = false
  1596. return
  1597. }
  1598. var arr = this.dialysisPrescription
  1599. // console.log('arr', arr)
  1600. const ParamsQuery = arr
  1601. // console.log('医嘱推送3', ParamsQuery)
  1602. ParamsQuery['patient'] = this.patient.id
  1603. ParamsQuery['record_date'] = this.record_date
  1604. ParamsQuery['mode'] = 1
  1605. postSoulution(ParamsQuery).then(response => {
  1606. if (response.data.state == 0) {
  1607. this.$message.error(response.data.msg)
  1608. this.isLoading = false
  1609. return false
  1610. } else {
  1611. this.$notify({
  1612. title: '成功',
  1613. message: '提交成功',
  1614. type: 'success',
  1615. duration: 2000
  1616. })
  1617. // console.log(hour + ':' + minute)
  1618. var date = new Date()
  1619. var hour =
  1620. date.getHours() < 10 ? '0' + date.getHours() : date.getHours()
  1621. var minute =
  1622. date.getMinutes() < 10
  1623. ? '0' + date.getMinutes()
  1624. : date.getMinutes()
  1625. const params = {
  1626. advices: results,
  1627. advice_date: this.start_time.split(' ')[0],
  1628. advice_doctor: results[0].advice_doctor,
  1629. advice_type: results[0].advice_type,
  1630. parent_id: this.patient_id,
  1631. start_time: this.start_time,
  1632. remark: ''
  1633. }
  1634. CreateGroupAdvice(this.$route.query.patient_id, 0, params).then(
  1635. rs => {
  1636. var resp = rs.data
  1637. if (resp.state == 1) {
  1638. // this.doctorAdvices = resp.data.advices
  1639. this.$emit('advice')
  1640. this.isLoading = false
  1641. } else {
  1642. this.isLoading = false
  1643. }
  1644. }
  1645. )
  1646. const prescription_resp = response.data.data.prescription
  1647. const solution_resp = response.data.data.solution
  1648. var prescription = this.prescription
  1649. var solution = this.solution
  1650. for (var index in prescription_resp) {
  1651. // prescription[index] = prescription_resp[index];
  1652. this.$set(prescription, index, prescription_resp[index])
  1653. }
  1654. for (var index in solution_resp) {
  1655. // solution[index] = solution_resp[index];
  1656. this.$set(solution, index, solution_resp[index])
  1657. }
  1658. this.hide()
  1659. }
  1660. })
  1661. }
  1662. }
  1663. } else {
  1664. if (this.is_pre == 1) {
  1665. if (this.patient.id <= 0) {
  1666. this.$message.error('没有选择患者')
  1667. this.loading = false
  1668. return
  1669. }
  1670. var arr = this.dialysisPrescription
  1671. const ParamsQuery = arr
  1672. // console.log('医嘱推送4', ParamsQuery)
  1673. ParamsQuery['patient'] = this.patient.id
  1674. ParamsQuery['record_date'] = this.record_date
  1675. // console.log(this.prescription)
  1676. let mode = ''
  1677. if (this.prescription.creater <= 0) {
  1678. mode = 1
  1679. } else {
  1680. mode = 2
  1681. }
  1682. ParamsQuery['mode'] = mode
  1683. console.log("paramsquery",ParamsQuery)
  1684. postPrescription(ParamsQuery).then(response => {
  1685. if (response.data.state == 0) {
  1686. this.$message.error(response.data.msg)
  1687. return false
  1688. } else {
  1689. this.$notify({
  1690. title: '成功',
  1691. message: '提交成功',
  1692. type: 'success',
  1693. duration: 2000
  1694. })
  1695. const prescription_resp = response.data.data.prescription
  1696. var prescription = this.prescription
  1697. for (var index in prescription_resp) {
  1698. // prescription[index] = prescription_resp[index];
  1699. this.$set(prescription, index, prescription_resp[index])
  1700. }
  1701. this.hide()
  1702. }
  1703. })
  1704. } else if (this.is_pre == 2) {
  1705. if (this.patient.id <= 0) {
  1706. this.$message.error('没有选择患者')
  1707. this.loading = false
  1708. return
  1709. }
  1710. var arr = this.dialysisPrescription
  1711. const ParamsQuery = arr
  1712. ParamsQuery['patient'] = this.patient.id
  1713. ParamsQuery['record_date'] = this.record_date
  1714. ParamsQuery['mode'] = 1
  1715. postSoulution(ParamsQuery).then(response => {
  1716. if (response.data.state == 0) {
  1717. this.$message.error(response.data.msg)
  1718. return false
  1719. } else {
  1720. this.$notify({
  1721. title: '成功',
  1722. message: '提交成功',
  1723. type: 'success',
  1724. duration: 2000
  1725. })
  1726. const prescription_resp = response.data.data.prescription
  1727. const solution_resp = response.data.data.solution
  1728. var prescription = this.prescription
  1729. var solution = this.solution
  1730. for (var index in prescription_resp) {
  1731. // prescription[index] = prescription_resp[index];
  1732. this.$set(prescription, index, prescription_resp[index])
  1733. }
  1734. for (var index in solution_resp) {
  1735. // solution[index] = solution_resp[index];
  1736. this.$set(solution, index, solution_resp[index])
  1737. }
  1738. this.hide()
  1739. }
  1740. })
  1741. }
  1742. }
  1743. this.isShowRemindAdvice = false
  1744. this.isVisibility = true
  1745. },
  1746. handleAdviceCancle() {
  1747. this.isShowRemindAdvice = false
  1748. this.isVisibility = true
  1749. },
  1750. getTime(val) {
  1751. return uParseTime(val, '{y}-{m}-{d} {h}:{i}')
  1752. },
  1753. show(pre, schedual, last, his_is_open,is_advice_open) {
  1754. if (pre != undefined) {
  1755. if (pre.oxygen_uptake == 1) {
  1756. this.oxygenShow = true
  1757. }
  1758. if (pre.oxygen_uptake == 2) {
  1759. this.oxygenShow = false
  1760. this.prescription.oxygen_flow = ''
  1761. this.prescription.oxygen_time = ''
  1762. }
  1763. }
  1764. if (his_is_open == 1) {
  1765. this.is_open = 0
  1766. }
  1767. if(is_advice_open == 1){
  1768. this.is_open = 1
  1769. }
  1770. if(this.$store.getters.xt_user.org.id == 10101){
  1771. if (this.predialysis.id > 0 && this.predialysis.created_time > 0) {
  1772. var date = new Date(this.predialysis.created_time * 1000)
  1773. var year = date.getFullYear()
  1774. var month = date.getMonth() + 1
  1775. var day = date.getDate()
  1776. var hours = date.getHours()
  1777. var minites = date.getMinutes()
  1778. if (month < 10) {
  1779. month = '0' + month
  1780. }
  1781. if (day < 10) {
  1782. day = '0' + day
  1783. }
  1784. if (hours < 10) {
  1785. hours = '0' + hours
  1786. }
  1787. if (minites < 10) {
  1788. minites = '0' + minites
  1789. }
  1790. this.start_time = year + '-' + month + '-' + day + ' ' + hours + ':' + minites
  1791. } else {
  1792. var date = new Date()
  1793. var year = date.getFullYear()
  1794. var month = date.getMonth() + 1
  1795. var day = date.getDate()
  1796. var hours = date.getHours()
  1797. var minites = date.getMinutes()
  1798. if (month < 10) {
  1799. month = '0' + month
  1800. }
  1801. if (day < 10) {
  1802. day = '0' + day
  1803. }
  1804. if (hours < 10) {
  1805. hours = '0' + hours
  1806. }
  1807. if (minites < 10) {
  1808. minites = '0' + minites
  1809. }
  1810. this.start_time = year + '-' + month + '-' + day + ' ' + hours + ':' + minites
  1811. }
  1812. }else{
  1813. var date = new Date()
  1814. var year = date.getFullYear()
  1815. var month = date.getMonth() + 1
  1816. var day = date.getDate()
  1817. var hours = date.getHours()
  1818. var minites = date.getMinutes()
  1819. if (month < 10) {
  1820. month = '0' + month
  1821. }
  1822. if (day < 10) {
  1823. day = '0' + day
  1824. }
  1825. if (hours < 10) {
  1826. hours = '0' + hours
  1827. }
  1828. if (minites < 10) {
  1829. minites = '0' + minites
  1830. }
  1831. if (this.$store.getters.xt_user.org.id == 10016 || this.$store.getters.xt_user.org.id == 10121 || this.$store.getters.xt_user.org.id == 4 || this.$store.getters.xt_user.org.id == 10013 || this.$store.getters.xt_user.org.id == 10014 ) {
  1832. this.start_time = year + '-' + month + '-' + day + ' ' + hours + ':' + minites
  1833. }else if(this.$store.getters.xt_user.org.id == 10234 || this.$store.getters.xt_user.org.id == 9671){
  1834. if (schedual.schedule_type == 1) {
  1835. this.start_time = year + '-' + month + '-' + day + ' ' + '06:00'
  1836. } else if (schedual.schedule_type == 2) {
  1837. this.start_time = year + '-' + month + '-' + day + ' ' + '11:00'
  1838. } else if (schedual.schedule_type == 3) {
  1839. this.start_time = year + '-' + month + '-' + day + ' ' + '18:00'
  1840. }
  1841. } else {
  1842. if (schedual.schedule_type == 1) {
  1843. this.start_time = year + '-' + month + '-' + day + ' ' + '07:00'
  1844. } else if (schedual.schedule_type == 2) {
  1845. this.start_time = year + '-' + month + '-' + day + ' ' + '12:00'
  1846. } else if (schedual.schedule_type == 3) {
  1847. this.start_time = year + '-' + month + '-' + day + ' ' + '18:00'
  1848. }
  1849. }
  1850. }
  1851. if (pre.anticoagulant == 3) {
  1852. this.dialysisPrescription.anticoagulant = '低分子肝素'
  1853. }
  1854. // 入口
  1855. var pre = pre
  1856. this.dialysisPrescription.mode_id = this.$route.query.mode_id ? this.$route.query.mode_id : this.mode_id
  1857. if (pre.id > 0) {
  1858. this.dialysisPrescription.mode_id = pre.mode_id
  1859. }
  1860. // console.log('this.dialysisPrescription.mode_id', this.dialysisPrescription.mode_id)
  1861. // console.log('this.schedual', schedual.mode_id)
  1862. if (pre.mode_id == 2 || pre.mode_id == 5 || pre.mode_id == 12 || schedual.mode_id == 2 || schedual.mode_id == 5 || schedual.mode_id == 12) {
  1863. this.zhiShow = true
  1864. this.huShow = true
  1865. this.totalShow = true
  1866. } else if (
  1867. pre.mode_id == 1 ||
  1868. pre.mode_id == 3 ||
  1869. pre.mode_id == 4 ||
  1870. pre.mode_id == 6 ||
  1871. pre.mode_id == 7 ||
  1872. pre.mode_id == 8 ||
  1873. pre.mode_id == 9 ||
  1874. pre.mode_id == 10 ||
  1875. pre.mode_id == 11 ||
  1876. pre.mode_id == 13 ||
  1877. pre.mode_id == 14 ||
  1878. pre.mode_id == 19
  1879. ) {
  1880. this.zhiShow = false
  1881. this.huShow = false
  1882. this.totalShow = false
  1883. }
  1884. this.pre = pre
  1885. // console.log("pre1", pre);
  1886. this.getPermission()
  1887. let last_weight_after = 0
  1888. let weight_before = 0
  1889. if (this.last_record == null) {
  1890. last_weight_after = 0
  1891. } else {
  1892. last_weight_after = this.last_record.weight_after
  1893. }
  1894. console.log("last2323232323232332",last)
  1895. if (this.predialysis == null || this.predialysis.id == 0) {
  1896. if (last != null) {
  1897. this.dialysisPrescription.niprocart = last.niprocart
  1898. this.dialysisPrescription.jms = last.jms
  1899. this.dialysisPrescription.fistula_needle_set = last.fistula_needle_set
  1900. this.dialysisPrescription.fistula_needle_set_16 = last.fistula_needle_set_16
  1901. this.dialysisPrescription.hemoperfusion = last.hemoperfusion
  1902. this.dialysisPrescription.dialyser_sterilised = last.dialyser_sterilised
  1903. this.dialysisPrescription.filtryzer = last.filtryzer
  1904. this.dialysisPrescription.target_ktv = last.target_ktv
  1905. this.dialysisPrescription.dialyzers = last.dialyzers
  1906. this.dialysisPrescription.injector = last.injector
  1907. this.dialysisPrescription.bloodlines = last.bloodlines
  1908. this.dialysisPrescription.tubing_hemodialysis = last.tubing_hemodialysis
  1909. this.dialysisPrescription.package = last.package
  1910. this.dialysisPrescription.a_liquid = last.a_liquid
  1911. weight_before = 0
  1912. }
  1913. } else {
  1914. weight_before = this.predialysis.weight_before
  1915. }
  1916. if (weight_before > 0 && last_weight_after > 0) {
  1917. this.add_weight = parseFloat(weight_before - last_weight_after).toFixed(
  1918. 2
  1919. )
  1920. // console.log('体重增加', this.add_weight)
  1921. }
  1922. this.isVisibility = true
  1923. this.checkedCities = []
  1924. for (let i = 0; i < this.targetAdvices.length; i++) {
  1925. if (this.targetAdvices[i].isCheck == 1) {
  1926. this.checkedCities.push(this.targetAdvices[i].id)
  1927. }
  1928. }
  1929. },
  1930. hide() {
  1931. this.isVisibility = false
  1932. },
  1933. changeThisAnticoagulant: function(val) {
  1934. console.log("val",val)
  1935. var thismode = val
  1936. if (isNaN(thismode) || thismode <= 0) {
  1937. return false
  1938. }
  1939. if (val <= 2) {
  1940. this.anticoagulant = this.anticoagulantsConfit[thismode - 1]
  1941. }
  1942. if (val > 2) {
  1943. this.anticoagulant = this.anticoagulantsConfit[thismode - 2]
  1944. }
  1945. if ((this.$store.getters.xt_user.template_info.template_id == 13 || this.$store.getters.xt_user.template_info.template_id == 41 || this.$store.getters.xt_user.template_info.template_id == 6) && val == 2) {
  1946. if(val == 2){
  1947. this.anticoagulant.shouji_unit = 'mg'
  1948. }else{
  1949. this.anticoagulant.shouji_unit = 'iu'
  1950. }
  1951. this.anticoagulant.weichi_unit = 'mg/h'
  1952. this.anticoagulant.zongliang_unit = 'mg'
  1953. }
  1954. if (this.$store.getters.xt_user.template_info.template_id == 27 && val == 4) {
  1955. this.anticoagulant.shouji_unit = 'ml'
  1956. this.anticoagulant.weichi_unit = 'ml'
  1957. this.anticoagulant.zongliang_unit = 'ml'
  1958. }
  1959. if(this.$store.getters.xt_user.template_info.template_id == 41 && this.$store.getters.xt_user.template_info.template_id == 6 && this.dialysisPrescription.anticoagulant == 2){
  1960. this.dialysisPrescription.anticoagulant_zongliang = ""
  1961. this.dialysisPrescription.anticoagulant_zongliang = parseInt(this.dialysisPrescription.anticoagulant_shouji) + parseInt(this.dialysisPrescription.anticoagulant_weichi)
  1962. }
  1963. },
  1964. handleCommit: function() {
  1965. if(!this.isLoading){
  1966. if (this.dialysisPrescription.anticoagulant == '低分子肝素') {
  1967. this.dialysisPrescription.anticoagulant = 3
  1968. }
  1969. if (this.dialysisPrescription.anticoagulant == 1) {
  1970. this.dialysisPrescription.anticoagulant_weichi = '0'
  1971. this.dialysisPrescription.anticoagulant_shouji = '0'
  1972. this.dialysisPrescription.anticoagulant_zongliang = '0'
  1973. }
  1974. if (this.$store.getters.xt_user.template_info.template_id == 6) {
  1975. if (this.dialysisPrescription.mode_id == 2) {
  1976. if (
  1977. this.dialysisPrescription.displace_liqui_part == 0 ||
  1978. this.dialysisPrescription.displace_liqui_part == -2 ||
  1979. this.dialysisPrescription.displace_liqui_value == 0 ||
  1980. this.dialysisPrescription.displace_liqui_value == ''
  1981. ) {
  1982. this.$message.error('HDF模式下置换液和置换液总量不能为空!')
  1983. return
  1984. }
  1985. }
  1986. }
  1987. this.is_pre = 1
  1988. if (this.prescription.id == 0) {
  1989. if (this.is_open == 0) {
  1990. if (this.patient.id <= 0) {
  1991. this.$message.error('没有选择患者')
  1992. this.loading = false
  1993. return
  1994. }
  1995. var arr = this.dialysisPrescription
  1996. const ParamsQuery = arr
  1997. // console.log('night', ParamsQuery)
  1998. ParamsQuery['patient'] = this.patient.id
  1999. ParamsQuery['record_date'] = this.record_date
  2000. ParamsQuery['mode'] = '1'
  2001. ParamsQuery['patient_id'] = this.patient.id
  2002. console.log('第一', ParamsQuery)
  2003. postPrescription(ParamsQuery).then(response => {
  2004. if (response.data.state == 0) {
  2005. this.$message.error(response.data.msg)
  2006. return false
  2007. } else {
  2008. this.$notify({
  2009. title: '成功',
  2010. message: '提交成功',
  2011. type: 'success',
  2012. duration: 2000
  2013. })
  2014. const prescription_resp = response.data.data.prescription
  2015. var prescription = this.prescription
  2016. for (var index in prescription_resp) {
  2017. // prescription[index] = prescription_resp[index];
  2018. this.$set(prescription, index, prescription_resp[index])
  2019. }
  2020. this.hide()
  2021. }
  2022. })
  2023. } else if (this.is_open == 1) {
  2024. if (this.targetAdvices.length > 0) {
  2025. // 弹框推送提醒
  2026. this.isShowRemindAdvice = true
  2027. this.isVisibility = false
  2028. } else {
  2029. if (this.patient.id <= 0) {
  2030. this.$message.error('没有选择患者')
  2031. this.loading = false
  2032. return
  2033. }
  2034. var arr = this.dialysisPrescription
  2035. const ParamsQuery = arr
  2036. // console.log('ParamsQuerytwo', ParamsQuery)
  2037. ParamsQuery['patient'] = this.patient.id
  2038. ParamsQuery['record_date'] = this.record_date
  2039. ParamsQuery['mode'] = '1'
  2040. ParamsQuery['patient_id'] = this.patient.id
  2041. console.log('第二')
  2042. postPrescription(ParamsQuery).then(response => {
  2043. if (response.data.state == 0) {
  2044. this.$message.error(response.data.msg)
  2045. return false
  2046. } else {
  2047. this.$notify({
  2048. title: '成功',
  2049. message: '提交成功',
  2050. type: 'success',
  2051. duration: 2000
  2052. })
  2053. const prescription_resp = response.data.data.prescription
  2054. var prescription = this.prescription
  2055. for (var index in prescription_resp) {
  2056. // prescription[index] = prescription_resp[index];
  2057. this.$set(prescription, index, prescription_resp[index])
  2058. }
  2059. this.hide()
  2060. }
  2061. })
  2062. }
  2063. } else if (this.is_open == 2) {
  2064. var date = new Date()
  2065. var hour =
  2066. date.getHours() < 10 ? '0' + date.getHours() : date.getHours()
  2067. var minute =
  2068. date.getMinutes() < 10
  2069. ? '0' + date.getMinutes()
  2070. : date.getMinutes()
  2071. if (this.waitUploadAdvices.length > 0) {
  2072. if (this.patient.id <= 0) {
  2073. this.$message.error('没有选择患者')
  2074. this.loading = false
  2075. return
  2076. }
  2077. var arr = this.dialysisPrescription
  2078. const ParamsQuery = arr
  2079. console.log('paramsquerythree', ParamsQuery)
  2080. ParamsQuery['patient'] = this.patient.id
  2081. ParamsQuery['record_date'] = this.record_date
  2082. ParamsQuery['mode'] = '1'
  2083. ParamsQuery['patient_id'] = this.patient.id
  2084. console.log('第三')
  2085. postPrescription(ParamsQuery).then(response => {
  2086. if (response.data.state == 0) {
  2087. this.$message.error(response.data.msg)
  2088. return false
  2089. } else {
  2090. this.$notify({
  2091. title: '成功',
  2092. message: '提交成功',
  2093. type: 'success',
  2094. duration: 2000
  2095. })
  2096. const params = {
  2097. advices: this.waitUploadAdvices,
  2098. advice_date: uParseTime(
  2099. this.$route.query.date,
  2100. '{y}-{m}-{d}'
  2101. ),
  2102. advice_doctor: this.waitUploadAdvices[0].advice_doctor,
  2103. advice_type: this.waitUploadAdvices[0].advice_type,
  2104. parent_id: this.patient_id,
  2105. // start_time: uParseTime(this.$route.query.date, '{y}-{m}-{d}'),
  2106. start_time:
  2107. uParseTime(this.$route.query.date, '{y}-{m}-{d}') +
  2108. ' ' +
  2109. this.advice_start_time,
  2110. remark: ''
  2111. }
  2112. console.log('params--------', params)
  2113. CreateGroupAdvice(this.$route.query.patient_id, 0, params).then(
  2114. rs => {
  2115. var resp = rs.data
  2116. if (resp.state == 1) {
  2117. // this.doctorAdvices = resp.data.advices
  2118. this.$emit('advice')
  2119. } else {
  2120. }
  2121. }
  2122. )
  2123. const prescription_resp = response.data.data.prescription
  2124. var prescription = this.prescription
  2125. for (var index in prescription_resp) {
  2126. // prescription[index] = prescription_resp[index];
  2127. this.$set(prescription, index, prescription_resp[index])
  2128. }
  2129. this.hide()
  2130. }
  2131. })
  2132. } else {
  2133. if (this.patient.id <= 0) {
  2134. this.$message.error('没有选择患者')
  2135. this.loading = false
  2136. return
  2137. }
  2138. var arr = this.dialysisPrescription
  2139. const ParamsQuery = arr
  2140. // console.log('paramsqueryfour', ParamsQuery)
  2141. // console.log('创建者', this.prescription.creater)
  2142. // if (this.prescription.creater <= 0) {
  2143. // mode = 1;
  2144. // } else {
  2145. // mode = 2;
  2146. // }
  2147. ParamsQuery['patient'] = this.patient.id
  2148. ParamsQuery['record_date'] = this.record_date
  2149. // console.log(this.prescription);
  2150. console.log('第四')
  2151. ParamsQuery['patient_id'] = this.patient.id
  2152. postPrescription(ParamsQuery).then(response => {
  2153. if (response.data.state == 0) {
  2154. this.$message.error(response.data.msg)
  2155. return false
  2156. } else {
  2157. this.$notify({
  2158. title: '成功',
  2159. message: '提交成功',
  2160. type: 'success',
  2161. duration: 2000
  2162. })
  2163. const prescription_resp = response.data.data.prescription
  2164. // console.log("aaaaaaa", prescription_resp);
  2165. var prescription = this.prescription
  2166. for (var index in prescription_resp) {
  2167. // prescription[index] = prescription_resp[index];
  2168. this.$set(prescription, index, prescription_resp[index])
  2169. }
  2170. this.hide()
  2171. }
  2172. })
  2173. }
  2174. }
  2175. } else {
  2176. if (this.prescription.creater == 0) {
  2177. if (this.is_open == 0) {
  2178. if (this.patient.id <= 0) {
  2179. this.$message.error('没有选择患者')
  2180. this.loading = false
  2181. return
  2182. }
  2183. var arr = this.dialysisPrescription
  2184. // console.log('arr', arr)
  2185. const ParamsQuery = arr
  2186. // console.log('paramsqueryfive', ParamsQuery)
  2187. ParamsQuery['patient'] = this.patient.id
  2188. ParamsQuery['record_date'] = this.record_date
  2189. ParamsQuery['mode'] = '1'
  2190. ParamsQuery['patient_id'] = this.patient.id
  2191. console.log('第五')
  2192. postPrescription(ParamsQuery).then(response => {
  2193. if (response.data.state == 0) {
  2194. this.$message.error(response.data.msg)
  2195. return false
  2196. } else {
  2197. this.$notify({
  2198. title: '成功',
  2199. message: '提交成功',
  2200. type: 'success',
  2201. duration: 2000
  2202. })
  2203. const prescription_resp = response.data.data.prescription
  2204. var prescription = this.prescription
  2205. for (var index in prescription_resp) {
  2206. // prescription[index] = prescription_resp[index];
  2207. this.$set(prescription, index, prescription_resp[index])
  2208. }
  2209. this.hide()
  2210. }
  2211. })
  2212. } else if (this.is_open == 1) {
  2213. if (this.targetAdvices.length > 0) {
  2214. // 弹框推送提醒
  2215. this.isShowRemindAdvice = true
  2216. this.isVisibility = false
  2217. } else {
  2218. if (this.patient.id <= 0) {
  2219. this.$message.error('没有选择患者')
  2220. this.loading = false
  2221. return
  2222. }
  2223. var arr = this.dialysisPrescription
  2224. // console.log('arr', arr)
  2225. const ParamsQuery = arr
  2226. // console.log('ParamsQuerysix', ParamsQuery)
  2227. ParamsQuery['patient'] = this.patient.id
  2228. ParamsQuery['record_date'] = this.record_date
  2229. ParamsQuery['mode'] = '1'
  2230. console.log('第6')
  2231. ParamsQuery['patient_id'] = this.patient.id
  2232. postPrescription(ParamsQuery).then(response => {
  2233. if (response.data.state == 0) {
  2234. this.$message.error(response.data.msg)
  2235. return false
  2236. } else {
  2237. this.$notify({
  2238. title: '成功',
  2239. message: '提交成功',
  2240. type: 'success',
  2241. duration: 2000
  2242. })
  2243. const prescription_resp = response.data.data.prescription
  2244. var prescription = this.prescription
  2245. for (var index in prescription_resp) {
  2246. // prescription[index] = prescription_resp[index];
  2247. this.$set(prescription, index, prescription_resp[index])
  2248. }
  2249. this.hide()
  2250. }
  2251. })
  2252. }
  2253. } else if (this.is_open == 2) {
  2254. var date = new Date()
  2255. var hour =
  2256. date.getHours() < 10 ? '0' + date.getHours() : date.getHours()
  2257. var minute =
  2258. date.getMinutes() < 10
  2259. ? '0' + date.getMinutes()
  2260. : date.getMinutes()
  2261. if (this.waitUploadAdvices.length > 0) {
  2262. if (this.patient.id <= 0) {
  2263. this.$message.error('没有选择患者')
  2264. this.loading = false
  2265. return
  2266. }
  2267. var arr = this.dialysisPrescription
  2268. // console.log('arr', arr)
  2269. const ParamsQuery = arr
  2270. // console.log('parasmqueryseven', parasmqueryseven)
  2271. ParamsQuery['patient'] = this.patient.id
  2272. ParamsQuery['record_date'] = this.record_date
  2273. ParamsQuery['mode'] = '1'
  2274. console.log('第七')
  2275. ParamsQuery['patient_id'] = this.patient.id
  2276. postPrescription(ParamsQuery).then(response => {
  2277. if (response.data.state == 0) {
  2278. this.$message.error(response.data.msg)
  2279. return false
  2280. } else {
  2281. this.$notify({
  2282. title: '成功',
  2283. message: '提交成功',
  2284. type: 'success',
  2285. duration: 2000
  2286. })
  2287. const params = {
  2288. advices: this.waitUploadAdvices,
  2289. advice_date: uParseTime(
  2290. this.$route.query.date,
  2291. '{y}-{m}-{d}'
  2292. ),
  2293. advice_doctor: this.waitUploadAdvices[0].advice_doctor,
  2294. advice_type: this.waitUploadAdvices[0].advice_type,
  2295. parent_id: this.patient_id,
  2296. // start_time: uParseTime(this.$route.query.date, '{y}-{m}-{d}'),
  2297. start_time:
  2298. uParseTime(this.$route.query.date, '{y}-{m}-{d}') +
  2299. ' ' +
  2300. hour +
  2301. ':' +
  2302. minute,
  2303. remark: ''
  2304. }
  2305. CreateGroupAdvice(
  2306. this.$route.query.patient_id,
  2307. 0,
  2308. params
  2309. ).then(rs => {
  2310. var resp = rs.data
  2311. if (resp.state == 1) {
  2312. // this.doctorAdvices = resp.data.advices
  2313. this.$emit('advice')
  2314. } else {
  2315. }
  2316. })
  2317. const prescription_resp = response.data.data.prescription
  2318. var prescription = this.prescription
  2319. for (var index in prescription_resp) {
  2320. // prescription[index] = prescription_resp[index];
  2321. this.$set(prescription, index, prescription_resp[index])
  2322. }
  2323. this.hide()
  2324. }
  2325. })
  2326. } else {
  2327. if (this.patient.id <= 0) {
  2328. this.$message.error('没有选择患者')
  2329. this.loading = false
  2330. return
  2331. }
  2332. var arr = this.dialysisPrescription
  2333. // console.log('arr', arr)
  2334. const ParamsQuery = arr
  2335. // console.log('eight', ParamsQuery)
  2336. ParamsQuery['patient'] = this.patient.id
  2337. ParamsQuery['record_date'] = this.record_date
  2338. ParamsQuery['mode'] = '1'
  2339. ParamsQuery['patient_id'] = this.patient.id
  2340. console.log('第八')
  2341. postPrescription(ParamsQuery).then(response => {
  2342. if (response.data.state == 0) {
  2343. this.$message.error(response.data.msg)
  2344. return false
  2345. } else {
  2346. this.$notify({
  2347. title: '成功',
  2348. message: '提交成功',
  2349. type: 'success',
  2350. duration: 2000
  2351. })
  2352. const prescription_resp = response.data.data.prescription
  2353. var prescription = this.prescription
  2354. for (var index in prescription_resp) {
  2355. // prescription[index] = prescription_resp[index];
  2356. this.$set(prescription, index, prescription_resp[index])
  2357. }
  2358. this.hide()
  2359. }
  2360. })
  2361. }
  2362. }
  2363. } else {
  2364. if (this.patient.id <= 0) {
  2365. this.$message.error('没有选择患者')
  2366. this.loading = false
  2367. return
  2368. }
  2369. var arr = this.dialysisPrescription
  2370. // console.log('arr', arr)
  2371. const ParamsQuery = arr
  2372. // console.log('night', ParamsQuery)
  2373. ParamsQuery['patient'] = this.patient.id
  2374. ParamsQuery['record_date'] = this.record_date
  2375. ParamsQuery['mode'] = '2'
  2376. ParamsQuery['patient_id'] = this.patient.id
  2377. if (
  2378. this.$store.getters.xt_user.user.id !=
  2379. this.dialysisPrescription.creater
  2380. ) {
  2381. ParamsQuery['mode'] = '3'
  2382. }
  2383. console.log('第九',ParamsQuery)
  2384. postPrescription(ParamsQuery).then(response => {
  2385. if (response.data.state == 0) {
  2386. this.$message.error(response.data.msg)
  2387. return false
  2388. } else {
  2389. this.$notify({
  2390. title: '成功',
  2391. message: '提交成功',
  2392. type: 'success',
  2393. duration: 2000
  2394. })
  2395. const prescription_resp = response.data.data.prescription
  2396. var prescription = this.prescription
  2397. for (var index in prescription_resp) {
  2398. // prescription[index] = prescription_resp[index];
  2399. this.$set(prescription, index, prescription_resp[index])
  2400. }
  2401. this.hide()
  2402. }
  2403. })
  2404. }
  2405. }
  2406. }
  2407. },
  2408. handleCancle: function() {
  2409. this.hide()
  2410. },
  2411. handleSolution: function() {
  2412. if(!this.isLoading){
  2413. if (this.dialysisPrescription.anticoagulant == 1) {
  2414. this.dialysisPrescription.anticoagulant_weichi = '0'
  2415. this.dialysisPrescription.anticoagulant_shouji = '0'
  2416. this.dialysisPrescription.anticoagulant_zongliang = '0'
  2417. }
  2418. if (this.$store.getters.xt_user.template_info.template_id == 6) {
  2419. if (this.dialysisPrescription.mode_id == 2) {
  2420. if (
  2421. this.dialysisPrescription.displace_liqui_part == 0 ||
  2422. this.dialysisPrescription.displace_liqui_part == -2 ||
  2423. this.dialysisPrescription.displace_liqui_value == 0 ||
  2424. this.dialysisPrescription.displace_liqui_value == ''
  2425. ) {
  2426. this.$message.error('HDF模式下置换液和置换液总量不能为空!')
  2427. return
  2428. }
  2429. }
  2430. }
  2431. this.is_pre = 2
  2432. if (this.prescription.id == 0) {
  2433. if (this.is_open == 0) {
  2434. if (this.patient.id <= 0) {
  2435. this.$message.error('没有选择患者')
  2436. this.loading = false
  2437. return
  2438. }
  2439. console.log("预充了2",this.dialysisPrescription.pre_impulse)
  2440. this.dialysisPrescription.impulse = this.dialysisPrescription.pre_impulse
  2441. var arr = this.dialysisPrescription
  2442. const ParamsQuery = arr
  2443. ParamsQuery['patient'] = this.patient.id
  2444. ParamsQuery['record_date'] = this.record_date
  2445. ParamsQuery['mode'] = '1'
  2446. postSoulution(ParamsQuery).then(response => {
  2447. if (response.data.state == 0) {
  2448. this.$message.error(response.data.msg)
  2449. return false
  2450. } else {
  2451. this.$notify({
  2452. title: '成功',
  2453. message: '提交成功',
  2454. type: 'success',
  2455. duration: 2000
  2456. })
  2457. const prescription_resp = response.data.data.prescription
  2458. const solution_resp = response.data.data.solution
  2459. var prescription = this.prescription
  2460. var solution = this.solution
  2461. for (var index in prescription_resp) {
  2462. // prescription[index] = prescription_resp[index];
  2463. this.$set(prescription, index, prescription_resp[index])
  2464. }
  2465. for (var index in solution_resp) {
  2466. // solution[index] = solution_resp[index];
  2467. this.$set(solution, index, solution_resp[index])
  2468. }
  2469. this.hide()
  2470. }
  2471. })
  2472. } else if (this.is_open == 1) {
  2473. if (this.targetAdvices.length > 0) {
  2474. // 弹框推送提
  2475. this.isShowRemindAdvice = true
  2476. this.isVisibility = false
  2477. } else {
  2478. if (this.patient.id <= 0) {
  2479. this.$message.error('没有选择患者')
  2480. this.loading = false
  2481. return
  2482. }
  2483. console.log("预充了3",this.dialysisPrescription.pre_impulse)
  2484. this.dialysisPrescription.impulse = this.dialysisPrescription.pre_impulse
  2485. var arr = this.dialysisPrescription
  2486. console.log('arr3', arr)
  2487. const ParamsQuery = arr
  2488. // console.log('长期处方2', ParamsQuery)
  2489. ParamsQuery['patient'] = this.patient.id
  2490. ParamsQuery['record_date'] = this.record_date
  2491. ParamsQuery['mode'] = '1'
  2492. postSoulution(ParamsQuery).then(response => {
  2493. if (response.data.state == 0) {
  2494. this.$message.error(response.data.msg)
  2495. return false
  2496. } else {
  2497. this.$notify({
  2498. title: '成功',
  2499. message: '提交成功',
  2500. type: 'success',
  2501. duration: 2000
  2502. })
  2503. const prescription_resp = response.data.data.prescription
  2504. const solution_resp = response.data.data.solution
  2505. var prescription = this.prescription
  2506. var solution = this.solution
  2507. for (var index in prescription_resp) {
  2508. // prescription[index] = prescription_resp[index];
  2509. this.$set(prescription, index, prescription_resp[index])
  2510. }
  2511. for (var index in solution_resp) {
  2512. // solution[index] = solution_resp[index];
  2513. this.$set(solution, index, solution_resp[index])
  2514. }
  2515. this.hide()
  2516. }
  2517. })
  2518. }
  2519. } else if (this.is_open == 2) {
  2520. var date = new Date()
  2521. var hour =
  2522. date.getHours() < 10 ? '0' + date.getHours() : date.getHours()
  2523. var minute =
  2524. date.getMinutes() < 10
  2525. ? '0' + date.getMinutes()
  2526. : date.getMinutes()
  2527. if (this.waitUploadAdvices.length > 0) {
  2528. // if (this.patient.id <= 0) {
  2529. // this.$message.error('没有选择患者')
  2530. // this.loading = false
  2531. // return
  2532. // }
  2533. this.dialysisPrescription.impulse = this.dialysisPrescription.pre_impulse
  2534. var arr = this.dialysisPrescription
  2535. const ParamsQuery = arr
  2536. // console.log('长期处方3', ParamsQuery)
  2537. ParamsQuery['patient'] = this.patient.id
  2538. ParamsQuery['record_date'] = this.record_date
  2539. // console.log(this.prescription)
  2540. ParamsQuery['mode'] = '1'
  2541. postPrescription(ParamsQuery).then(response => {
  2542. if (response.data.state == 0) {
  2543. this.$message.error(response.data.msg)
  2544. return false
  2545. } else {
  2546. this.$notify({
  2547. title: '成功',
  2548. message: '提交成功',
  2549. type: 'success',
  2550. duration: 2000
  2551. })
  2552. const params = {
  2553. advices: this.waitUploadAdvices,
  2554. advice_date: uParseTime(
  2555. this.$route.query.date,
  2556. '{y}-{m}-{d}'
  2557. ),
  2558. advice_doctor: this.waitUploadAdvices[0].advice_doctor,
  2559. advice_type: this.waitUploadAdvices[0].advice_type,
  2560. parent_id: this.patient_id,
  2561. // start_time: uParseTime(this.$route.query.date, '{y}-{m}-{d}'),
  2562. start_time:
  2563. uParseTime(this.$route.query.date, '{y}-{m}-{d}') +
  2564. ' ' +
  2565. hour +
  2566. ':' +
  2567. minute,
  2568. remark: ''
  2569. }
  2570. CreateGroupAdvice(this.$route.query.patient_id, 0, params).then(
  2571. rs => {
  2572. var resp = rs.data
  2573. if (resp.state == 1) {
  2574. // this.doctorAdvices = resp.data.advices
  2575. this.$emit('advice')
  2576. } else {
  2577. }
  2578. }
  2579. )
  2580. const prescription_resp = response.data.data.prescription
  2581. var prescription = this.prescription
  2582. for (var index in prescription_resp) {
  2583. // prescription[index] = prescription_resp[index];
  2584. this.$set(prescription, index, prescription_resp[index])
  2585. }
  2586. this.hide()
  2587. }
  2588. })
  2589. } else {
  2590. if (this.patient.id <= 0) {
  2591. this.$message.error('没有选择患者')
  2592. this.loading = false
  2593. return
  2594. }
  2595. console.log("预充了5",this.dialysisPrescription.pre_impulse)
  2596. this.dialysisPrescription.impulse = this.dialysisPrescription.pre_impulse
  2597. var arr = this.dialysisPrescription
  2598. console.log('arr5', arr)
  2599. const ParamsQuery = arr
  2600. // console.log('长期处方5', ParamsQuery)
  2601. ParamsQuery['patient'] = this.patient.id
  2602. ParamsQuery['record_date'] = this.record_date
  2603. ParamsQuery['mode'] = '1'
  2604. postSoulution(ParamsQuery).then(response => {
  2605. if (response.data.state == 0) {
  2606. this.$message.error(response.data.msg)
  2607. return false
  2608. } else {
  2609. this.$notify({
  2610. title: '成功',
  2611. message: '提交成功',
  2612. type: 'success',
  2613. duration: 2000
  2614. })
  2615. const prescription_resp = response.data.data.prescription
  2616. const solution_resp = response.data.data.solution
  2617. var prescription = this.prescription
  2618. var solution = this.solution
  2619. for (var index in prescription_resp) {
  2620. // prescription[index] = prescription_resp[index];
  2621. this.$set(prescription, index, prescription_resp[index])
  2622. }
  2623. for (var index in solution_resp) {
  2624. // solution[index] = solution_resp[index];
  2625. this.$set(solution, index, solution_resp[index])
  2626. }
  2627. this.hide()
  2628. }
  2629. })
  2630. }
  2631. }
  2632. } else {
  2633. if (this.prescription.creater == 0) {
  2634. if (this.is_open == 0) {
  2635. if (this.patient.id <= 0) {
  2636. this.$message.error('没有选择患者')
  2637. this.loading = false
  2638. return
  2639. }
  2640. this.dialysisPrescription.impulse = this.dialysisPrescription.pre_impulse
  2641. var arr = this.dialysisPrescription
  2642. console.log('arr', arr)
  2643. const ParamsQuery = arr
  2644. // console.log('长期处方6', ParamsQuery)
  2645. ParamsQuery['patient'] = this.patient.id
  2646. ParamsQuery['record_date'] = this.record_date
  2647. ParamsQuery['mode'] = '1'
  2648. postSoulution(ParamsQuery).then(response => {
  2649. if (response.data.state == 0) {
  2650. this.$message.error(response.data.msg)
  2651. return false
  2652. } else {
  2653. this.$notify({
  2654. title: '成功',
  2655. message: '提交成功',
  2656. type: 'success',
  2657. duration: 2000
  2658. })
  2659. const prescription_resp = response.data.data.prescription
  2660. const solution_resp = response.data.data.solution
  2661. var prescription = this.prescription
  2662. var solution = this.solution
  2663. for (var index in prescription_resp) {
  2664. // prescription[index] = prescription_resp[index];
  2665. this.$set(prescription, index, prescription_resp[index])
  2666. }
  2667. for (var index in solution_resp) {
  2668. // solution[index] = solution_resp[index];
  2669. this.$set(solution, index, solution_resp[index])
  2670. }
  2671. this.hide()
  2672. }
  2673. })
  2674. } else if (this.is_open == 1) {
  2675. if (this.targetAdvices.length > 0) {
  2676. // 弹框推送提醒
  2677. this.isShowRemindAdvice = true
  2678. this.isVisibility = false
  2679. } else {
  2680. if (this.patient.id <= 0) {
  2681. this.$message.error('没有选择患者')
  2682. this.loading = false
  2683. return
  2684. }
  2685. console.log("预充了7",this.dialysisPrescription.pre_impulse)
  2686. this.dialysisPrescription.impulse = this.dialysisPrescription.pre_impulse
  2687. var arr = this.dialysisPrescription
  2688. // console.log('arr', arr)
  2689. const ParamsQuery = arr
  2690. console.log('长期处方7', ParamsQuery)
  2691. ParamsQuery['patient'] = this.patient.id
  2692. ParamsQuery['record_date'] = this.record_date
  2693. ParamsQuery['mode'] = '1'
  2694. postSoulution(ParamsQuery).then(response => {
  2695. if (response.data.state == 0) {
  2696. this.$message.error(response.data.msg)
  2697. return false
  2698. } else {
  2699. this.$notify({
  2700. title: '成功',
  2701. message: '提交成功',
  2702. type: 'success',
  2703. duration: 2000
  2704. })
  2705. const prescription_resp = response.data.data.prescription
  2706. const solution_resp = response.data.data.solution
  2707. var prescription = this.prescription
  2708. var solution = this.solution
  2709. for (var index in prescription_resp) {
  2710. // prescription[index] = prescription_resp[index];
  2711. this.$set(prescription, index, prescription_resp[index])
  2712. }
  2713. for (var index in solution_resp) {
  2714. // solution[index] = solution_resp[index];
  2715. this.$set(solution, index, solution_resp[index])
  2716. }
  2717. this.hide()
  2718. }
  2719. })
  2720. }
  2721. } else if (this.is_open == 2) {
  2722. var date = new Date()
  2723. var hour =
  2724. date.getHours() < 10 ? '0' + date.getHours() : date.getHours()
  2725. var minute =
  2726. date.getMinutes() < 10
  2727. ? '0' + date.getMinutes()
  2728. : date.getMinutes()
  2729. if (this.waitUploadAdvices.length > 0) {
  2730. if (this.patient.id <= 0) {
  2731. this.$message.error('没有选择患者')
  2732. this.loading = false
  2733. return
  2734. }
  2735. this.dialysisPrescription.impulse = this.dialysisPrescription.pre_impulse
  2736. var arr = this.dialysisPrescription
  2737. const ParamsQuery = arr
  2738. // console.log('长期处方8', ParamsQuery)
  2739. ParamsQuery['patient'] = this.patient.id
  2740. ParamsQuery['record_date'] = this.record_date
  2741. ParamsQuery['mode'] = '1'
  2742. postSoulution(ParamsQuery).then(response => {
  2743. if (response.data.state == 0) {
  2744. this.$message.error(response.data.msg)
  2745. return false
  2746. } else {
  2747. this.$notify({
  2748. title: '成功',
  2749. message: '提交成功',
  2750. type: 'success',
  2751. duration: 2000
  2752. })
  2753. const params = {
  2754. advices: this.waitUploadAdvices,
  2755. advice_date: uParseTime(
  2756. this.$route.query.date,
  2757. '{y}-{m}-{d}'
  2758. ),
  2759. advice_doctor: this.waitUploadAdvices[0].advice_doctor,
  2760. advice_type: this.waitUploadAdvices[0].advice_type,
  2761. parent_id: this.patient_id,
  2762. // start_time: uParseTime(this.$route.query.date, '{y}-{m}-{d} {h}{i}'),
  2763. start_time:
  2764. uParseTime(this.$route.query.date, '{y}-{m}-{d}') +
  2765. ' ' +
  2766. hour +
  2767. ':' +
  2768. minute,
  2769. remark: ''
  2770. }
  2771. CreateGroupAdvice(
  2772. this.$route.query.patient_id,
  2773. 0,
  2774. params
  2775. ).then(rs => {
  2776. var resp = rs.data
  2777. if (resp.state == 1) {
  2778. // this.doctorAdvices = resp.data.advices
  2779. this.$emit('advice')
  2780. } else {
  2781. }
  2782. })
  2783. const prescription_resp = response.data.data.prescription
  2784. const solution_resp = response.data.data.solution
  2785. var prescription = this.prescription
  2786. var solution = this.solution
  2787. for (var index in prescription_resp) {
  2788. // prescription[index] = prescription_resp[index];
  2789. this.$set(prescription, index, prescription_resp[index])
  2790. }
  2791. for (var index in solution_resp) {
  2792. // solution[index] = solution_resp[index];
  2793. this.$set(solution, index, solution_resp[index])
  2794. }
  2795. this.hide()
  2796. }
  2797. })
  2798. } else {
  2799. if (this.patient.id <= 0) {
  2800. this.$message.error('没有选择患者')
  2801. this.loading = false
  2802. return
  2803. }
  2804. console.log("预充了99999",this.dialysisPrescription.pre_impulse)
  2805. this.dialysisPrescription.impulse = this.dialysisPrescription.pre_impulse
  2806. var arr = this.dialysisPrescription
  2807. console.log('arr', arr)
  2808. const ParamsQuery = arr
  2809. // console.log('长期处方9', ParamsQuery)
  2810. ParamsQuery['patient'] = this.patient.id
  2811. ParamsQuery['record_date'] = this.record_date
  2812. ParamsQuery['mode'] = '1'
  2813. postSoulution(ParamsQuery).then(response => {
  2814. if (response.data.state == 0) {
  2815. this.$message.error(response.data.msg)
  2816. return false
  2817. } else {
  2818. this.$notify({
  2819. title: '成功',
  2820. message: '提交成功',
  2821. type: 'success',
  2822. duration: 2000
  2823. })
  2824. const prescription_resp = response.data.data.prescription
  2825. const solution_resp = response.data.data.solution
  2826. var prescription = this.prescription
  2827. var solution = this.solution
  2828. for (var index in prescription_resp) {
  2829. // prescription[index] = prescription_resp[index];
  2830. this.$set(prescription, index, prescription_resp[index])
  2831. }
  2832. for (var index in solution_resp) {
  2833. // solution[index] = solution_resp[index];
  2834. this.$set(solution, index, solution_resp[index])
  2835. }
  2836. this.hide()
  2837. }
  2838. })
  2839. }
  2840. }
  2841. } else {
  2842. if (this.patient.id <= 0) {
  2843. this.$message.error('没有选择患者')
  2844. this.loading = false
  2845. return
  2846. }
  2847. console.log("预充了1",this.dialysisPrescription.pre_impulse)
  2848. this.dialysisPrescription.impulse = this.dialysisPrescription.pre_impulse
  2849. var arr = this.dialysisPrescription
  2850. console.log('arr12333223', arr)
  2851. const ParamsQuery = arr
  2852. ParamsQuery['patient'] = this.patient.id
  2853. ParamsQuery['record_date'] = this.record_date
  2854. ParamsQuery['mode'] = '1'
  2855. console.log('长期处方10', ParamsQuery)
  2856. postSoulution(ParamsQuery).then(response => {
  2857. if (response.data.state == 0) {
  2858. this.$message.error(response.data.msg)
  2859. return false
  2860. } else {
  2861. this.$notify({
  2862. title: '成功',
  2863. message: '提交成功',
  2864. type: 'success',
  2865. duration: 2000
  2866. })
  2867. const prescription_resp = response.data.data.prescription
  2868. const solution_resp = response.data.data.solution
  2869. var prescription = this.prescription
  2870. var solution = this.solution
  2871. for (var index in prescription_resp) {
  2872. // prescription[index] = prescription_resp[index];
  2873. this.$set(prescription, index, prescription_resp[index])
  2874. }
  2875. for (var index in solution_resp) {
  2876. // solution[index] = solution_resp[index];
  2877. this.$set(solution, index, solution_resp[index])
  2878. }
  2879. this.hide()
  2880. }
  2881. })
  2882. }
  2883. }
  2884. }
  2885. },
  2886. isShows(name) {
  2887. var filedList = store.getters.xt_user.fileds
  2888. for (let i = 0; i < filedList.length; i++) {
  2889. if (filedList[i].module == 1 && filedList[i].filed_name_cn == name && filedList[i].is_show == 1) {
  2890. return true
  2891. }
  2892. }
  2893. return false
  2894. },
  2895. getDoctorName(doctor_id) {
  2896. for (let i = 0; i < this.admin_users.length; i++) {
  2897. if (this.admin_users[i].id == doctor_id) {
  2898. return this.admin_users[i].name
  2899. }
  2900. }
  2901. },
  2902. getContent(val) {
  2903. let prescribing_number = ''
  2904. let single_dose = ''
  2905. let advice_desc = ''
  2906. if (val.prescribing_number > 0) {
  2907. prescribing_number =
  2908. val.prescribing_number + val.prescribing_number_unit
  2909. }
  2910. if (val.single_dose > 0) {
  2911. single_dose = ' 单次用量 ' + val.single_dose + val.single_dose_unit
  2912. }
  2913. if (val.advice_desc > 0 || val.advice_desc.length > 0) {
  2914. advice_desc = val.advice_desc + val.drug_spec_unit
  2915. }
  2916. let name = ''
  2917. if (val.child.length > 0) {
  2918. for (let i = 0; i < val.child.length; i++) {
  2919. if (val.child[i].prescribing_number > 0) {
  2920. val.child[i]['presc'] =
  2921. val.child[i].prescribing_number +
  2922. val.child[i].prescribing_number_unit
  2923. } else {
  2924. val.child[i]['presc'] = ''
  2925. }
  2926. if (val.child[i].single_dose > 0) {
  2927. val.child[i]['single'] =
  2928. ' ' +
  2929. ' 单次用量 ' +
  2930. ' ' +
  2931. val.child[i].single_dose +
  2932. val.child[i].single_dose_unit
  2933. } else {
  2934. val.child[i]['single'] = ''
  2935. }
  2936. name =
  2937. name +
  2938. '▲' +
  2939. val.child[i].advice_name +
  2940. '' +
  2941. val.child[i].advice_desc +
  2942. val.child[i].drug_spec_unit +
  2943. val.child[i].presc +
  2944. val.child[i].single
  2945. }
  2946. return (
  2947. val.advice_name +
  2948. ' ' +
  2949. advice_desc +
  2950. ' ' +
  2951. val.drug_spec_unit +
  2952. prescribing_number +
  2953. ' ' +
  2954. single_dose +
  2955. ' ' +
  2956. ' ' +
  2957. val.delivery_way +
  2958. ' ' +
  2959. val.execution_frequency +
  2960. val.remark +
  2961. name
  2962. )
  2963. } else {
  2964. return (
  2965. val.advice_name +
  2966. ' ' +
  2967. advice_desc +
  2968. prescribing_number +
  2969. ' ' +
  2970. single_dose +
  2971. ' ' +
  2972. ' ' +
  2973. val.delivery_way +
  2974. ' ' +
  2975. val.execution_frequency +
  2976. val.remark
  2977. )
  2978. }
  2979. },
  2980. changePrescription(id) {
  2981. console.log("id233223232323232323",id)
  2982. if(id == 1){
  2983. this.dialysisPrescription.displace_liqui_value = ""
  2984. this.dialysisPrescription.displace_liqui_part = ""
  2985. }
  2986. const ParamsQuery = {}
  2987. ParamsQuery['patient_id'] = this.$route.query.patient_id
  2988. ParamsQuery['mode_id'] = id
  2989. GetSolution(ParamsQuery).then(response => {
  2990. if (response.data.state == 0) {
  2991. this.$message.error(response.data.msg)
  2992. return false
  2993. } else {
  2994. console.log('切换数据', response.data.data.solution)
  2995. this.$message.success('切换成功')
  2996. if (response.data.data.solution != null) {
  2997. for (const key in response.data.data.solution) {
  2998. // 长期处方不为空
  2999. if (key != 'target_ultrafiltration' && key != 'niprocart' && key != 'target_ultrafiltration' && key != 'jms' && key != 'fistula_needle_set' && key != 'fistula_needle_set_16'
  3000. && key != 'hemoperfusion' && key != 'dialyser_sterilised' && key != 'filtryzer' && key != 'target_ktv' && key != 'dialyzers'
  3001. && key != 'injector' && key != 'bloodlines' && key != 'tubing_hemodialysis' && key != 'package' && key != 'a_liquid') {
  3002. this.dialysisPrescription[key] =
  3003. response.data.data.solution[key]
  3004. }
  3005. }
  3006. } else {
  3007. if (response.data.data.prescription != null) {
  3008. // 临时处方不为空
  3009. for (const key in response.data.data.prescription) {
  3010. if (key != 'target_ultrafiltration' && key != 'niprocart' && key != 'target_ultrafiltration' && key != 'jms' && key != 'fistula_needle_set' && key != 'fistula_needle_set_16'
  3011. && key != 'hemoperfusion' && key != 'dialyser_sterilised' && key != 'filtryzer' && key != 'target_ktv' && key != 'dialyzers'
  3012. && key != 'injector' && key != 'bloodlines' && key != 'tubing_hemodialysis' && key != 'package' && key != 'a_liquid') {
  3013. this.dialysisPrescription[key] =
  3014. response.data.data.prescription[key]
  3015. }
  3016. }
  3017. } else if (response.data.data.system_prescription != null) {
  3018. // 系统处方不为空
  3019. for (const key in response.data.data.system_prescription) {
  3020. if (key != 'target_ultrafiltration' && key != 'niprocart' && key != 'target_ultrafiltration' && key != 'jms' && key != 'fistula_needle_set' && key != 'fistula_needle_set_16'
  3021. && key != 'hemoperfusion' && key != 'dialyser_sterilised' && key != 'filtryzer' && key != 'target_ktv' && key != 'dialyzers'
  3022. && key != 'injector' && key != 'bloodlines' && key != 'tubing_hemodialysis' && key != 'package' && key != 'a_liquid') {
  3023. this.dialysisPrescription[key] =
  3024. response.data.data.system_prescription[key]
  3025. }
  3026. }
  3027. } else {
  3028. for (const key in this.dialysisPrescription) {
  3029. // 临时处方为空
  3030. if (key != 'target_ultrafiltration' && key != 'niprocart' && key != 'target_ultrafiltration' && key != 'jms' && key != 'fistula_needle_set' && key != 'fistula_needle_set_16'
  3031. && key != 'hemoperfusion' && key != 'dialyser_sterilised' && key != 'filtryzer' && key != 'target_ktv' && key != 'dialyzers'
  3032. && key != 'injector' && key != 'bloodlines' && key != 'tubing_hemodialysis' && key != 'package' && key != 'a_liquid') {
  3033. this.dialysisPrescription[key] = ''
  3034. }
  3035. }
  3036. this.dialysisPrescription.mode_id = id
  3037. }
  3038. }
  3039. }
  3040. if (
  3041. this.dialysisPrescription.dialysis_duration_hour === '' ||
  3042. this.dialysisPrescription.dialysis_duration_minute === ''
  3043. ) {
  3044. this.timeValue = ''
  3045. this.time = '03:00'
  3046. } else {
  3047. this.timeValue =
  3048. this.dialysisPrescription.dialysis_duration_hour +
  3049. '小时' +
  3050. this.dialysisPrescription.dialysis_duration_minute +
  3051. '分钟'
  3052. this.time =
  3053. (this.dialysisPrescription.dialysis_duration_hour > 10
  3054. ? this.dialysisPrescription.dialysis_duration_hour
  3055. : '0' + this.dialysisPrescription.dialysis_duration_hour) +
  3056. ':' +
  3057. (this.dialysisPrescription.dialysis_duration_minute > 10
  3058. ? this.dialysisPrescription.dialysis_duration_minute
  3059. : '0' + this.dialysisPrescription.dialysis_duration_minute)
  3060. }
  3061. })
  3062. if (
  3063. id === 1 ||
  3064. id === 3 ||
  3065. id === 4 ||
  3066. id === 6 ||
  3067. id === 7 ||
  3068. id === 8 ||
  3069. id === 9 ||
  3070. id === 10 ||
  3071. id === 11 ||
  3072. id === 13 ||
  3073. id === 14 ||
  3074. id === 15 ||
  3075. id === 16 ||
  3076. id === 19
  3077. ) {
  3078. this.zhiShow = false
  3079. this.huShow = false
  3080. this.totalShow = false
  3081. } else {
  3082. this.zhiShow = true
  3083. this.huShow = true
  3084. this.totalShow = true
  3085. }
  3086. },
  3087. handlePatientInfo() {
  3088. this.isVisibility = false
  3089. this.msgtip_visibility = true
  3090. },
  3091. cancleMsg() {
  3092. this.isVisibility = true
  3093. this.msgtip_visibility = false
  3094. },
  3095. getPermission() {
  3096. request
  3097. .get('/api/func_per/get', {
  3098. params: {
  3099. create_url: '/api/dialysis/prescription?mode=1',
  3100. modify_url: '/api/dialysis/prescription?mode=2',
  3101. modify_other_url: '/api/dialysis/prescription?mode=3',
  3102. module: 1
  3103. }
  3104. })
  3105. .then(res => {
  3106. // console.log(res)
  3107. // console.log('predialysis.creater', this.pre.creater)
  3108. // console.log('admin.id', this.$store.getters.xt_user.user.id)
  3109. if (res.data.state == 0) {
  3110. this.hasPermission = false
  3111. } else if (res.data.state == 1) {
  3112. if (this.pre.id != '' && this.pre.creater != 0) {
  3113. // 有数据
  3114. if (this.pre.creater == this.$store.getters.xt_user.user.id) {
  3115. // 创建人是自己
  3116. if (res.data.data.is_has_modify == false) {
  3117. this.hasPermission = false
  3118. this.showTxt = '你没有修改透析处方权限'
  3119. }
  3120. } else {
  3121. // 创建人不是自己
  3122. if (res.data.data.is_has_modify_other == false) {
  3123. this.hasPermission = false
  3124. this.showTxt = '你没有修改他人透析处方权限'
  3125. }
  3126. }
  3127. } else if (this.pre.id == '' || this.pre.creater == 0) {
  3128. if (res.data.data.is_has_create == false) {
  3129. this.hasPermission = false
  3130. this.showTxt = '你没有新增透析处方权限'
  3131. }
  3132. }
  3133. }
  3134. })
  3135. },
  3136. unique(arr) {
  3137. const res = new Map()
  3138. return arr.filter((arr) => !res.has(arr.name) && res.set(arr.name, 1))
  3139. }
  3140. },
  3141. watch: {
  3142. 'dialysisPrescription.dialysis_duration_hour': function() {
  3143. let dialysis_duration_minute = 0
  3144. let dialysis_duration_hour = 0
  3145. let duration = 0
  3146. if (this.dialysisPrescription.dialysis_duration_minute == '') {
  3147. dialysis_duration_minute = 0
  3148. } else {
  3149. dialysis_duration_minute = this.dialysisPrescription
  3150. .dialysis_duration_minute
  3151. }
  3152. if (this.dialysisPrescription.dialysis_duration_hour == '') {
  3153. dialysis_duration_hour = 0
  3154. } else {
  3155. dialysis_duration_hour = this.dialysisPrescription
  3156. .dialysis_duration_hour
  3157. }
  3158. duration = parseFloat(dialysis_duration_hour) + parseFloat(dialysis_duration_minute) / 60
  3159. this.dialysisPrescription.anticoagulant_zongliang = calculateAnticoagulantZL(1, this.dialysisPrescription.anticoagulant_shouji, duration, this.dialysisPrescription.anticoagulant_weichi)
  3160. if (isNaN(this.dialysisPrescription.anticoagulant_zongliang)) {
  3161. this.dialysisPrescription.anticoagulant_zongliang = ''
  3162. }
  3163. },
  3164. 'dialysisPrescription.dialysis_duration_minute': function() {
  3165. let dialysis_duration_minute = 0
  3166. let dialysis_duration_hour = 0
  3167. let duration = 0
  3168. if (this.dialysisPrescription.dialysis_duration_minute == '') {
  3169. dialysis_duration_minute = 0
  3170. } else {
  3171. dialysis_duration_minute = this.dialysisPrescription.dialysis_duration_minute
  3172. }
  3173. if (this.dialysisPrescription.dialysis_duration_hour == '') {
  3174. dialysis_duration_hour = 0
  3175. } else {
  3176. dialysis_duration_hour = this.dialysisPrescription
  3177. .dialysis_duration_hour
  3178. }
  3179. duration =
  3180. parseFloat(dialysis_duration_hour) +
  3181. parseFloat(dialysis_duration_minute) / 60
  3182. this.dialysisPrescription.anticoagulant_zongliang = calculateAnticoagulantZL(1, this.dialysisPrescription.anticoagulant_shouji, duration,
  3183. this.dialysisPrescription.anticoagulant_weichi
  3184. )
  3185. if (isNaN(this.dialysisPrescription.anticoagulant_zongliang)) {
  3186. this.dialysisPrescription.anticoagulant_zongliang = ''
  3187. }
  3188. },
  3189. 'dialysisPrescription.anticoagulant_shouji': function() {
  3190. let dialysis_duration_minute = 0
  3191. let dialysis_duration_hour = 0
  3192. let duration = 0
  3193. if (this.dialysisPrescription.dialysis_duration_minute == '') {
  3194. dialysis_duration_minute = 0
  3195. } else {
  3196. dialysis_duration_minute = this.dialysisPrescription
  3197. .dialysis_duration_minute
  3198. }
  3199. if (this.dialysisPrescription.dialysis_duration_hour == '') {
  3200. dialysis_duration_hour = 0
  3201. } else {
  3202. dialysis_duration_hour = this.dialysisPrescription
  3203. .dialysis_duration_hour
  3204. }
  3205. duration =
  3206. parseFloat(dialysis_duration_hour) +
  3207. parseFloat(dialysis_duration_minute) / 60
  3208. this.dialysisPrescription.anticoagulant_zongliang = calculateAnticoagulantZL(
  3209. 1,
  3210. this.dialysisPrescription.anticoagulant_shouji,
  3211. duration,
  3212. this.dialysisPrescription.anticoagulant_weichi
  3213. )
  3214. if (isNaN(this.dialysisPrescription.anticoagulant_zongliang)) {
  3215. this.dialysisPrescription.anticoagulant_zongliang = ''
  3216. }
  3217. if(this.$store.getters.xt_user.template_info.template_id == 41 && this.dialysisPrescription.anticoagulant == 2){
  3218. this.dialysisPrescription.anticoagulant_zongliang = ""
  3219. this.dialysisPrescription.anticoagulant_zongliang = parseInt(this.dialysisPrescription.anticoagulant_shouji) + parseInt(this.dialysisPrescription.anticoagulant_weichi)
  3220. }
  3221. },
  3222. 'dialysisPrescription.anticoagulant_weichi': function() {
  3223. let dialysis_duration_minute = 0
  3224. let dialysis_duration_hour = 0
  3225. let duration = 0
  3226. if (this.dialysisPrescription.dialysis_duration_minute == '') {
  3227. dialysis_duration_minute = 0
  3228. } else {
  3229. dialysis_duration_minute = this.dialysisPrescription
  3230. .dialysis_duration_minute
  3231. }
  3232. if (this.dialysisPrescription.dialysis_duration_hour == '') {
  3233. dialysis_duration_hour = 0
  3234. } else {
  3235. dialysis_duration_hour = this.dialysisPrescription
  3236. .dialysis_duration_hour
  3237. }
  3238. duration = parseFloat(dialysis_duration_hour) + parseFloat(dialysis_duration_minute) / 60
  3239. this.dialysisPrescription.anticoagulant_zongliang = calculateAnticoagulantZL(1, this.dialysisPrescription.anticoagulant_shouji, duration, this.dialysisPrescription.anticoagulant_weichi)
  3240. if (isNaN(this.dialysisPrescription.anticoagulant_zongliang)) {
  3241. this.dialysisPrescription.anticoagulant_zongliang = ''
  3242. }
  3243. if(this.$store.getters.xt_user.template_info.template_id == 41 && this.dialysisPrescription.anticoagulant == 2){
  3244. this.dialysisPrescription.anticoagulant_zongliang = ""
  3245. this.dialysisPrescription.anticoagulant_zongliang = parseInt(this.dialysisPrescription.anticoagulant_shouji) + parseInt(this.dialysisPrescription.anticoagulant_weichi)
  3246. }
  3247. },
  3248. 'prescription.id': {
  3249. immediate: true,
  3250. deep: true,
  3251. handler(oldVal, newVal) {
  3252. if (oldVal == newVal) {
  3253. for (var index in this.dialysisPrescription) {
  3254. this.dialysisPrescription[index] = this.prescription[index]
  3255. }
  3256. if (this.prescription['dialysate_formulation'] == 0) {
  3257. this.dialysisPrescription['dialysate_formulation'] = ''
  3258. }
  3259. if (this.prescription['anticoagulant'] == 0) {
  3260. this.dialysisPrescription['anticoagulant'] = ''
  3261. }
  3262. if (this.prescription['dialysis_duration_hour'] == 0) {
  3263. this.dialysisPrescription['dialysis_duration_hour'] = ''
  3264. }
  3265. if (this.prescription['dialysis_duration_minute'] == 0) {
  3266. this.dialysisPrescription['dialysis_duration_minute'] = ''
  3267. }
  3268. if (this.prescription['blood_flow_volume'] == 0) {
  3269. this.dialysisPrescription['blood_flow_volume'] = ''
  3270. }
  3271. if (this.prescription['target_ultrafiltration'] == 0) {
  3272. this.dialysisPrescription['target_ultrafiltration'] = ''
  3273. }
  3274. if (this.prescription['dialysate_temperature'] == 0) {
  3275. this.dialysisPrescription['dialysate_temperature'] = ''
  3276. }
  3277. if (this.prescription['anticoagulant_shouji'] == 0) {
  3278. this.dialysisPrescription['anticoagulant_shouji'] = 0
  3279. }
  3280. if (this.prescription['anticoagulant_weichi'] == 0) {
  3281. this.dialysisPrescription['anticoagulant_weichi'] = 0
  3282. }
  3283. if (this.prescription['anticoagulant_zongliang'] == 0) {
  3284. this.dialysisPrescription['anticoagulant_zongliang'] = 0
  3285. }
  3286. if (this.prescription['anticoagulant_gaijiliang'] == 0) {
  3287. this.dialysisPrescription['anticoagulant_gaijiliang'] = ''
  3288. }
  3289. if (this.prescription['kalium'] == 0) {
  3290. this.dialysisPrescription['kalium'] = ''
  3291. }
  3292. if (this.prescription['sodium'] == 0) {
  3293. this.dialysisPrescription['sodium'] = ''
  3294. }
  3295. if (this.prescription['calcium'] == 0) {
  3296. this.dialysisPrescription['calcium'] = ''
  3297. }
  3298. if (this.prescription['bicarbonate'] == 0) {
  3299. this.dialysisPrescription['bicarbonate'] = ''
  3300. }
  3301. if (this.prescription['glucose'] == 0) {
  3302. this.dialysisPrescription['glucose'] = ''
  3303. }
  3304. if (this.prescription['dialysate_flow'] == 0) {
  3305. this.dialysisPrescription['dialysate_flow'] = ''
  3306. }
  3307. if (this.prescription['conductivity'] == 0) {
  3308. this.dialysisPrescription['conductivity'] = ''
  3309. }
  3310. if (this.prescription['replacement_total'] == 0) {
  3311. this.dialysisPrescription['replacement_total'] = ''
  3312. }
  3313. if (this.prescription['target_ktv'] == 0) {
  3314. this.dialysisPrescription['target_ktv'] = ''
  3315. }
  3316. }
  3317. if (this.prescription.id > 0) {
  3318. for (var index in this.dialysisPrescription) {
  3319. this.dialysisPrescription[index] = this.prescription[index]
  3320. }
  3321. if (this.prescription['dialysate_formulation'] == 0) {
  3322. this.dialysisPrescription['dialysate_formulation'] = ''
  3323. }
  3324. if (this.prescription['anticoagulant'] == 0) {
  3325. this.dialysisPrescription['anticoagulant'] = ''
  3326. }
  3327. if (this.prescription['dialysis_duration_hour'] == 0) {
  3328. this.dialysisPrescription['dialysis_duration_hour'] = ''
  3329. }
  3330. if (this.prescription['dialysis_duration_minute'] == 0) {
  3331. this.dialysisPrescription['dialysis_duration_minute'] = ''
  3332. }
  3333. if (this.prescription['blood_flow_volume'] == 0) {
  3334. this.dialysisPrescription['blood_flow_volume'] = ''
  3335. }
  3336. if (this.prescription['target_ultrafiltration'] == 0) {
  3337. this.dialysisPrescription['target_ultrafiltration'] = ''
  3338. }
  3339. if (this.prescription['dialysate_temperature'] == 0) {
  3340. this.dialysisPrescription['dialysate_temperature'] = ''
  3341. }
  3342. if (this.prescription['anticoagulant_shouji'] == 0) {
  3343. this.dialysisPrescription['anticoagulant_shouji'] = 0
  3344. }
  3345. if (this.prescription['anticoagulant_weichi'] == 0) {
  3346. this.dialysisPrescription['anticoagulant_weichi'] = 0
  3347. }
  3348. if (this.prescription['anticoagulant_zongliang'] == 0) {
  3349. this.dialysisPrescription['anticoagulant_zongliang'] = 0
  3350. }
  3351. if (this.prescription['anticoagulant_gaijiliang'] == 0) {
  3352. this.dialysisPrescription['anticoagulant_gaijiliang'] = ''
  3353. }
  3354. if (this.prescription['kalium'] == 0) {
  3355. this.dialysisPrescription['kalium'] = ''
  3356. }
  3357. if (this.prescription['sodium'] == 0) {
  3358. this.dialysisPrescription['sodium'] = ''
  3359. }
  3360. if (this.prescription['calcium'] == 0) {
  3361. this.dialysisPrescription['calcium'] = ''
  3362. }
  3363. if (this.prescription['bicarbonate'] == 0) {
  3364. this.dialysisPrescription['bicarbonate'] = ''
  3365. }
  3366. if (this.prescription['glucose'] == 0) {
  3367. this.dialysisPrescription['glucose'] = ''
  3368. }
  3369. if (this.prescription['dialysate_flow'] == 0) {
  3370. this.dialysisPrescription['dialysate_flow'] = ''
  3371. }
  3372. if (this.prescription['conductivity'] == 0) {
  3373. this.dialysisPrescription['conductivity'] = ''
  3374. }
  3375. if (this.prescription['replacement_total'] == 0) {
  3376. this.dialysisPrescription['replacement_total'] = ''
  3377. }
  3378. if (this.prescription['target_ktv'] == 0) {
  3379. this.dialysisPrescription['target_ktv'] = ''
  3380. }
  3381. } else if (this.prescription.id == 0) {
  3382. for (var index in this.dialysisPrescription) {
  3383. this.dialysisPrescription[index] = this.prescription[index]
  3384. }
  3385. if (this.prescription['dialysate_formulation'] == 0) {
  3386. this.dialysisPrescription['dialysate_formulation'] = ''
  3387. }
  3388. if (this.prescription['anticoagulant'] == 0) {
  3389. this.dialysisPrescription['anticoagulant'] = ''
  3390. }
  3391. if (this.prescription['dialysis_duration_hour'] == 0) {
  3392. this.dialysisPrescription['dialysis_duration_hour'] = ''
  3393. }
  3394. if (this.prescription['dialysis_duration_minute'] == 0) {
  3395. this.dialysisPrescription['dialysis_duration_minute'] = ''
  3396. }
  3397. if (this.prescription['blood_flow_volume'] == 0) {
  3398. this.dialysisPrescription['blood_flow_volume'] = ''
  3399. }
  3400. if (this.prescription['target_ultrafiltration'] == 0) {
  3401. this.dialysisPrescription['target_ultrafiltration'] = ''
  3402. }
  3403. if (this.prescription['dialysate_temperature'] == 0) {
  3404. this.dialysisPrescription['dialysate_temperature'] = ''
  3405. }
  3406. if (this.prescription['anticoagulant_shouji'] == 0) {
  3407. this.dialysisPrescription['anticoagulant_shouji'] = 0
  3408. }
  3409. if (this.prescription['anticoagulant_weichi'] == 0) {
  3410. this.dialysisPrescription['anticoagulant_weichi'] = 0
  3411. }
  3412. if (this.prescription['anticoagulant_zongliang'] == 0) {
  3413. this.dialysisPrescription['anticoagulant_zongliang'] = 0
  3414. }
  3415. if (this.prescription['anticoagulant_gaijiliang'] == 0) {
  3416. this.dialysisPrescription['anticoagulant_gaijiliang'] = ''
  3417. }
  3418. if (this.prescription['kalium'] == 0) {
  3419. this.dialysisPrescription['kalium'] = ''
  3420. }
  3421. if (this.prescription['sodium'] == 0) {
  3422. this.dialysisPrescription['sodium'] = ''
  3423. }
  3424. if (this.prescription['calcium'] == 0) {
  3425. this.dialysisPrescription['calcium'] = ''
  3426. }
  3427. if (this.prescription['bicarbonate'] == 0) {
  3428. this.dialysisPrescription['bicarbonate'] = ''
  3429. }
  3430. if (this.prescription['glucose'] == 0) {
  3431. this.dialysisPrescription['glucose'] = ''
  3432. }
  3433. if (this.prescription['dialysate_flow'] == 0) {
  3434. this.dialysisPrescription['dialysate_flow'] = ''
  3435. }
  3436. if (this.prescription['conductivity'] == 0) {
  3437. this.dialysisPrescription['conductivity'] = ''
  3438. }
  3439. if (this.prescription['replacement_total'] == 0) {
  3440. this.dialysisPrescription['replacement_total'] = ''
  3441. }
  3442. if (this.prescription['target_ktv'] == 0) {
  3443. this.dialysisPrescription['target_ktv'] = ''
  3444. }
  3445. }
  3446. }
  3447. },
  3448. 'solution.id': function() {
  3449. if (this.solution.id > 0) {
  3450. if (
  3451. this.prescription != null &&
  3452. typeof this.prescription.id !== 'undefined' &&
  3453. this.prescription.id > 0
  3454. ) {
  3455. for (const key in this.prescription) {
  3456. this.dialysisPrescription[key] = this.prescription[key]
  3457. }
  3458. if (this.prescription['dialysate_formulation'] == 0) {
  3459. this.dialysisPrescription['dialysate_formulation'] = ''
  3460. }
  3461. if (this.prescription['anticoagulant'] == 0) {
  3462. this.dialysisPrescription['anticoagulant'] = ''
  3463. }
  3464. if (this.prescription['dialysis_duration_hour'] == 0) {
  3465. this.dialysisPrescription['dialysis_duration_hour'] = ''
  3466. }
  3467. if (this.prescription['dialysis_duration_minute'] == 0) {
  3468. this.dialysisPrescription['dialysis_duration_minute'] = ''
  3469. }
  3470. if (this.prescription['blood_flow_volume'] == 0) {
  3471. this.dialysisPrescription['blood_flow_volume'] = ''
  3472. }
  3473. if (this.prescription['target_ultrafiltration'] == 0) {
  3474. this.dialysisPrescription['target_ultrafiltration'] = ''
  3475. }
  3476. if (this.prescription['dialysate_temperature'] == 0) {
  3477. this.dialysisPrescription['dialysate_temperature'] = ''
  3478. }
  3479. if (this.prescription['anticoagulant_shouji'] == 0) {
  3480. this.dialysisPrescription['anticoagulant_shouji'] = 0
  3481. }
  3482. if (this.prescription['anticoagulant_weichi'] == 0) {
  3483. this.dialysisPrescription['anticoagulant_weichi'] = 0
  3484. }
  3485. if (this.prescription['anticoagulant_zongliang'] == 0) {
  3486. this.dialysisPrescription['anticoagulant_zongliang'] = 0
  3487. }
  3488. if (this.prescription['anticoagulant_gaijiliang'] == 0) {
  3489. this.dialysisPrescription['anticoagulant_gaijiliang'] = ''
  3490. }
  3491. if (this.prescription['kalium'] == 0) {
  3492. this.dialysisPrescription['kalium'] = ''
  3493. }
  3494. if (this.prescription['sodium'] == 0) {
  3495. this.dialysisPrescription['sodium'] = ''
  3496. }
  3497. if (this.prescription['calcium'] == 0) {
  3498. this.dialysisPrescription['calcium'] = ''
  3499. }
  3500. if (this.prescription['bicarbonate'] == 0) {
  3501. this.dialysisPrescription['bicarbonate'] = ''
  3502. }
  3503. if (this.prescription['glucose'] == 0) {
  3504. this.dialysisPrescription['glucose'] = ''
  3505. }
  3506. if (this.prescription['dialysate_flow'] == 0) {
  3507. this.dialysisPrescription['dialysate_flow'] = ''
  3508. }
  3509. if (this.prescription['conductivity'] == 0) {
  3510. this.dialysisPrescription['conductivity'] = ''
  3511. }
  3512. if (this.prescription['replacement_total'] == 0) {
  3513. this.dialysisPrescription['replacement_total'] = ''
  3514. }
  3515. if (this.prescription['target_ktv'] == 0) {
  3516. this.dialysisPrescription['target_ktv'] = ''
  3517. }
  3518. } else if (
  3519. this.solution != null &&
  3520. typeof this.solution.id !== 'undefined' &&
  3521. this.solution.id
  3522. ) {
  3523. for (const key in this.solution) {
  3524. this.dialysisPrescription[key] = this.solution[key]
  3525. }
  3526. if (this.solution['dialysate_formulation'] == 0) {
  3527. this.dialysisPrescription['dialysate_formulation'] = ''
  3528. }
  3529. if (this.solution['anticoagulant'] == 0) {
  3530. this.dialysisPrescription['anticoagulant'] = ''
  3531. }
  3532. if (this.solution['dialysis_duration_hour'] == 0) {
  3533. this.dialysisPrescription['dialysis_duration_hour'] = ''
  3534. }
  3535. if (this.solution['dialysis_duration_minute'] == 0) {
  3536. this.dialysisPrescription['dialysis_duration_minute'] = ''
  3537. }
  3538. if (this.solution['blood_flow_volume'] == 0) {
  3539. this.dialysisPrescription['blood_flow_volume'] = ''
  3540. }
  3541. if (this.solution['target_ultrafiltration'] == 0) {
  3542. this.dialysisPrescription['target_ultrafiltration'] = ''
  3543. }
  3544. if (this.solution['dialysate_temperature'] == 0) {
  3545. this.dialysisPrescription['dialysate_temperature'] = ''
  3546. }
  3547. if (this.solution['anticoagulant_shouji'] == 0) {
  3548. this.dialysisPrescription['anticoagulant_shouji'] = 0
  3549. }
  3550. if (this.solution['anticoagulant_weichi'] == 0) {
  3551. this.dialysisPrescription['anticoagulant_weichi'] = 0
  3552. }
  3553. if (this.solution['anticoagulant_zongliang'] == 0) {
  3554. this.dialysisPrescription['anticoagulant_zongliang'] = 0
  3555. }
  3556. if (this.solution['anticoagulant_gaijiliang'] == 0) {
  3557. this.dialysisPrescription['anticoagulant_gaijiliang'] = ''
  3558. }
  3559. if (this.solution['kalium'] == 0) {
  3560. this.dialysisPrescription['kalium'] = ''
  3561. }
  3562. if (this.solution['sodium'] == 0) {
  3563. this.dialysisPrescription['sodium'] = ''
  3564. }
  3565. if (this.solution['calcium'] == 0) {
  3566. this.dialysisPrescription['calcium'] = ''
  3567. }
  3568. if (this.solution['bicarbonate'] == 0) {
  3569. this.dialysisPrescription['bicarbonate'] = ''
  3570. }
  3571. if (this.solution['glucose'] == 0) {
  3572. this.dialysisPrescription['glucose'] = ''
  3573. }
  3574. if (this.solution['dialysate_flow'] == 0) {
  3575. this.dialysisPrescription['dialysate_flow'] = ''
  3576. }
  3577. if (this.solution['conductivity'] == 0) {
  3578. this.dialysisPrescription['conductivity'] = ''
  3579. }
  3580. if (this.solution['replacement_total'] == 0) {
  3581. this.dialysisPrescription['replacement_total'] = ''
  3582. }
  3583. if (this.solution['target_ktv'] == 0) {
  3584. this.dialysisPrescription['target_ktv'] = ''
  3585. }
  3586. }
  3587. }
  3588. },
  3589. stockType: function() {
  3590. console.log('stockType', this.stockType)
  3591. var arr = []
  3592. var arrTwo = []
  3593. for (let i = 0; i < this.stockType.length; i++) {
  3594. if (this.stockType[i].stock_attribute == 2) {
  3595. arr.push(this.stockType[i])
  3596. }
  3597. if (this.stockType[i].stock_attribute == 3) {
  3598. arrTwo.push(this.stockType[i])
  3599. }
  3600. }
  3601. var dialyzator = []
  3602. var irrigation = []
  3603. for (let i = 0; i < arr.length; i++) {
  3604. for (let j = 0; j < arr[i].GoodInfo.length; j++) {
  3605. dialyzator.push(arr[i].GoodInfo[j])
  3606. }
  3607. }
  3608. this.dialyzers = dialyzator
  3609. for (let i = 0; i < arrTwo.length; i++) {
  3610. for (let j = 0; j < arrTwo[i].GoodInfo.length; j++) {
  3611. irrigation.push(arrTwo[i].GoodInfo[j])
  3612. }
  3613. }
  3614. this.irrigations = irrigation
  3615. console.log('透析器', this.dialyzers)
  3616. console.log('灌流器', this.irrigations)
  3617. }
  3618. },
  3619. created() {
  3620. this.illnessList = getDataConfig('hemodialysis', 'illness')
  3621. this.plasmaSeparatorList = getDataConfig('hemodialysis', 'plasma_separator')
  3622. this.bilirubinAdsorptionColumn = getDataConfig('hemodialysis', 'bilirubin_adsorption_column')
  3623. }
  3624. }
  3625. </script>
  3626. <style rel="stylesheet/scss" lang="scss" scoped>
  3627. .el-checkbox,
  3628. .el-checkbox__input {
  3629. vertical-align: middle;
  3630. }
  3631. .newLine {
  3632. display: flex;
  3633. justify-content: space-between;
  3634. height: 40px;
  3635. line-height: 40px;
  3636. border-bottom: 1px solid #ccc;
  3637. color: #303133;
  3638. }
  3639. .warnTxt {
  3640. text-align: center;
  3641. margin: 0 auto;
  3642. background: #faa331;
  3643. max-width: 240px;
  3644. padding: 10px 20px;
  3645. border-radius: 4px;
  3646. margin-bottom: 10px;
  3647. color: #fff;
  3648. }
  3649. </style>
  3650. <style lang="scss">
  3651. .newDialog {
  3652. .el-dialog__body {
  3653. padding: 10px 20px 30px;
  3654. }
  3655. }
  3656. </style>