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

dialysisPrescriptionDialog.vue 165KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386338733883389339033913392339333943395339633973398339934003401340234033404340534063407340834093410341134123413341434153416341734183419342034213422342334243425342634273428342934303431343234333434343534363437343834393440344134423443344434453446344734483449345034513452345334543455345634573458345934603461346234633464346534663467346834693470347134723473347434753476347734783479348034813482348334843485348634873488348934903491349234933494349534963497349834993500350135023503350435053506350735083509351035113512351335143515351635173518351935203521352235233524352535263527352835293530353135323533353435353536353735383539354035413542354335443545354635473548354935503551355235533554355535563557355835593560356135623563356435653566356735683569357035713572357335743575357635773578357935803581358235833584358535863587358835893590359135923593359435953596359735983599360036013602360336043605360636073608360936103611361236133614361536163617361836193620362136223623362436253626362736283629363036313632363336343635363636373638363936403641364236433644364536463647364836493650365136523653365436553656365736583659366036613662366336643665366636673668366936703671367236733674367536763677367836793680368136823683368436853686368736883689369036913692369336943695369636973698369937003701370237033704370537063707370837093710371137123713371437153716371737183719372037213722372337243725372637273728372937303731373237333734373537363737373837393740374137423743374437453746374737483749375037513752375337543755375637573758375937603761376237633764376537663767376837693770377137723773377437753776377737783779378037813782378337843785378637873788378937903791379237933794379537963797379837993800380138023803380438053806380738083809381038113812381338143815381638173818381938203821382238233824382538263827382838293830383138323833383438353836383738383839384038413842384338443845384638473848384938503851385238533854385538563857385838593860386138623863386438653866386738683869387038713872387338743875387638773878387938803881388238833884388538863887388838893890389138923893389438953896389738983899390039013902390339043905390639073908390939103911391239133914391539163917391839193920392139223923392439253926392739283929393039313932393339343935393639373938393939403941394239433944394539463947394839493950395139523953395439553956395739583959396039613962396339643965396639673968396939703971397239733974397539763977397839793980398139823983398439853986398739883989399039913992399339943995399639973998399940004001400240034004400540064007400840094010401140124013401440154016401740184019
  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 == 36 || 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.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 != 36 && 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.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">
  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='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'
  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">
  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">
  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)"
  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"
  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">保 存</el-button>
  734. <el-button type="primary" @click="handleSolution"
  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">保 存</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. },
  1205. anticoagulant: {
  1206. id: 0,
  1207. name: '',
  1208. type: 1,
  1209. shouji: 1,
  1210. weichi: 1,
  1211. zongliang: 1,
  1212. gaimingcheng: -1,
  1213. gaijiliang: -1,
  1214. shouji_unit: 'mg',
  1215. weichi_unit: 'mg/h',
  1216. zongliang_unit: 'mg',
  1217. gaimingcheng_unit: '',
  1218. gaijiliang_unit: ''
  1219. },
  1220. doctorAdvices: [],
  1221. dialyzerPerfusionApparatus: [],
  1222. bloods: [],
  1223. irrigations: [],
  1224. dialyzers: [],
  1225. illnessList: [],
  1226. plasmaSeparatorList: [],
  1227. bilirubinAdsorptionColumn: [],
  1228. oxygenList: [
  1229. { id: 1, name: '需' },
  1230. { id: 2, name: '无' }
  1231. ],
  1232. oxygenShow: false
  1233. }
  1234. },
  1235. methods: {
  1236. changeOxygenList(val) {
  1237. if (val == 1) {
  1238. this.oxygenShow = true
  1239. }
  1240. if (val == 2) {
  1241. this.oxygenShow = false
  1242. this.prescription.oxygen_flow = ''
  1243. this.prescription.oxygen_time = ''
  1244. }
  1245. },
  1246. changeTime: function(val) {
  1247. this.advice_start_time = val
  1248. },
  1249. showInnerDialog: function(val) {
  1250. this.InnerDialogProps.visibility = true
  1251. switch (val) {
  1252. case '5': // 透析器/灌流器
  1253. // var arr = this.dialysisPrescription.dialyzer_perfusion_apparatus
  1254. // console.log("arr333333",arr)
  1255. // var newArr = arr.split(",")
  1256. // console.log("透析器/灌流器",newArr)
  1257. // var Arr = []
  1258. // for(let i=0;i<newArr.length;i++){
  1259. // for(let j=0;j<this.dialyzerPerfusionApparatus.length;j++){
  1260. // var newarr = newArr[i].toUpperCase()
  1261. // var dialy = this.dialyzerPerfusionApparatus[j].name.toUpperCase()
  1262. // if(newarr == dialy){
  1263. // Arr.push(this.dialyzerPerfusionApparatus[j].name)
  1264. // }
  1265. // }
  1266. // }
  1267. // var arrtwo = Arr.join(",")
  1268. // console.log("Arr",arrtwo)
  1269. // var arr = this.dialysisPrescription.dialyzer_perfusion_apparatus
  1270. // var newArr = arr.split(",")
  1271. // console.log("透析器/灌流器",newArr)
  1272. // var Arr = []
  1273. // for(let i=0;i<newArr.length;i++){
  1274. // for(let j=0;j<this.dialyzerPerfusionApparatus.length;j++){
  1275. // var newarr = newArr[i].toUpperCase()
  1276. //
  1277. // var dialy = this.dialyzerPerfusionApparatus[j].name.toUpperCase()
  1278. //
  1279. // if(newarr == dialy){
  1280. // Arr.push(this.dialyzerPerfusionApparatus[j].name)
  1281. // }
  1282. // }
  1283. // }
  1284. // var arrtwo = Arr.join(",")
  1285. // console.log("Arr",arrtwo)
  1286. this.InnerDialogProps.values = this.dialyzerPerfusionApparatus
  1287. this.InnerDialogProps.titles = '透析器/灌流器'
  1288. this.InnerDialogProps.type = 'dialyzer_perfusion_apparatus'
  1289. this.InnerDialogProps.selected = this.dialysisPrescription.dialyzer_perfusion_apparatus
  1290. this.InnerDialogProps.isShowTextArea = false
  1291. break
  1292. case '6': // 透析器/灌流器
  1293. this.InnerDialogProps.values = this.bloods
  1294. this.InnerDialogProps.titles = '抽血'
  1295. this.InnerDialogProps.type = 'blood'
  1296. this.InnerDialogProps.selected = this.dialysisPrescription.blood
  1297. this.InnerDialogProps.isShowTextArea = false
  1298. case '7': // 透析器
  1299. for (let i = 0; i < this.dialyzers.length; i++) {
  1300. this.dialyzers[i].name = this.dialyzers[i].specification_name
  1301. }
  1302. this.InnerDialogProps.values = this.dialyzers
  1303. this.InnerDialogProps.titles = '透析器'
  1304. this.InnerDialogProps.type = 'dialyzers'
  1305. this.InnerDialogProps.selected = this.dialysisPrescription.dialysis_dialyszers
  1306. this.InnerDialogProps.isShowTextArea = false
  1307. break
  1308. case '8':
  1309. for (let i = 0; i < this.irrigations.length; i++) {
  1310. this.irrigations[i].name = this.irrigations[i].specification_name
  1311. }
  1312. this.InnerDialogProps.values = this.irrigations
  1313. this.InnerDialogProps.titles = '透析器'
  1314. this.InnerDialogProps.type = 'irrigations'
  1315. this.InnerDialogProps.selected = this.dialysisPrescription.dialysis_irrigation
  1316. this.InnerDialogProps.isShowTextArea = false
  1317. break
  1318. case '9': // 血浆灌流器
  1319. this.InnerDialogProps.values = this.plasmaSeparatorList
  1320. this.InnerDialogProps.titles = '血浆灌流器'
  1321. this.InnerDialogProps.type = 'plasma_separator'
  1322. this.InnerDialogProps.selected = this.dialysisPrescription.plasma_separator
  1323. this.InnerDialogProps.isShowTextArea = false
  1324. break
  1325. case '10': // 胆红素吸附柱
  1326. this.InnerDialogProps.values = this.bilirubinAdsorptionColumn
  1327. this.InnerDialogProps.titles = '胆红素吸附柱'
  1328. this.InnerDialogProps.type = 'bilirubin_adsorption_column'
  1329. this.InnerDialogProps.selected = this.dialysisPrescription.bilirubin_adsorption_column
  1330. this.InnerDialogProps.isShowTextArea = false
  1331. break
  1332. case '11': //穿刺针
  1333. this.InnerDialogProps.values = this.punctureNeedleOptions
  1334. this.InnerDialogProps.titles = '穿刺针'
  1335. this.InnerDialogProps.type = 'puncture_needle'
  1336. this.InnerDialogProps.selected = this.dialysisPrescription.puncture_needle
  1337. this.InnerDialogProps.isShowTextArea = false
  1338. break
  1339. }
  1340. },
  1341. innerDialogComfirm: function(val) {
  1342. this.InnerDialogProps.visibility = false
  1343. switch (val.type) {
  1344. case 'dialyzer_perfusion_apparatus':
  1345. this.dialysisPrescription.dialyzer_perfusion_apparatus = val.value.join(',')
  1346. break
  1347. case 'blood':
  1348. this.dialysisPrescription.blood = val.value.join(',')
  1349. break
  1350. case 'dialyzers':
  1351. this.dialysisPrescription.dialysis_dialyszers = val.value.join(',')
  1352. break
  1353. case 'irrigations':
  1354. this.dialysisPrescription.dialysis_irrigation = val.value.join(',')
  1355. break
  1356. case 'plasma_separator':
  1357. this.dialysisPrescription.plasma_separator = val.value.join(',')
  1358. break
  1359. case 'bilirubin_adsorption_column':
  1360. this.dialysisPrescription.bilirubin_adsorption_column = val.value.join(',')
  1361. break
  1362. case 'puncture_needle':
  1363. this.dialysisPrescription.puncture_needle = val.value.join(',')
  1364. break
  1365. }
  1366. },
  1367. innerDialogCancle: function() {
  1368. this.InnerDialogProps.visibility = false
  1369. },
  1370. getDryWeight() {
  1371. if (this.dry_weight != null && this.dry_weight.id > 0) {
  1372. return this.dry_weight.dry_weight
  1373. } else {
  1374. if (this.last_predialysis != null && this.last_predialysis.id > 0) {
  1375. return this.last_predialysis.dry_weight
  1376. } else {
  1377. return ''
  1378. }
  1379. }
  1380. },
  1381. getLastAfterWeight(record) {
  1382. if (record != null && record.id > 0) {
  1383. if (record.weight_after > 0) {
  1384. let additional_weight = 0
  1385. if (this.predialysis.additional_weight != undefined) {
  1386. additional_weight = this.predialysis.additional_weight
  1387. }
  1388. return parseFloat(record.weight_after - additional_weight).toFixed(1)
  1389. } else {
  1390. return ''
  1391. }
  1392. }
  1393. },
  1394. getBeforeWeight(predialysis) {
  1395. if (predialysis.id > 0) {
  1396. if (predialysis.weight_before > 0) {
  1397. return parseFloat(predialysis.weight_before - predialysis.additional_weight).toFixed(1)
  1398. } else {
  1399. return ''
  1400. }
  1401. }
  1402. },
  1403. getAfterWeight(record) {
  1404. if (record.id > 0) {
  1405. if (record.weight_after > 0) {
  1406. return parseFloat(record.weight_after - this.predialysis.additional_weight).toFixed(1)
  1407. } else {
  1408. return ''
  1409. }
  1410. }
  1411. },
  1412. setLastRecord: function(schedual, lastAssessmentAfterDislysis, lastPredialysisEvaluation, lastDialysisPrescribe, lastDryWeightDislysis, system_prescribe) {
  1413. this.treatment_mode = this.$store.getters.treatment_mode
  1414. // console.log("99999",this.treatment_mode)
  1415. this.perfusion_apparatus = getDataConfig(
  1416. 'hemodialysis',
  1417. 'perfusion_apparatus'
  1418. )
  1419. this.replacement_ways = getDataConfig('hemodialysis', 'replacement_ways')
  1420. this.dialysate_formulation_options = getDataConfig(
  1421. 'hemodialysis',
  1422. 'dialysate_formulation'
  1423. )
  1424. // this.anticoagulantsConfit = this.$store.getters.anticoagulants_confit
  1425. var anticoagulantsConfitOne = this.$store.getters.anticoagulants_confit
  1426. // for (let i = 0; i < anticoagulantsConfitOne.length; i++) {
  1427. // console.log('anticoagulantsConfitOne', anticoagulantsConfitOne[i].name)
  1428. // }
  1429. // var anticoagulantsConfit = getDataConfig('hemodialysis', 'anticoagulant')
  1430. // const arr = []
  1431. // anticoagulantsConfit.map((item, index) => {
  1432. // const objChild = { ...item }
  1433. // arr.push(objChild)
  1434. // })
  1435. // var arrthree = {}
  1436. // arrthree = { ...arr }
  1437. // console.log('arrthree', arrthree)
  1438. const arrFour = []
  1439. Object.keys(anticoagulantsConfitOne).map((item, index) => {
  1440. if (index != 2) {
  1441. arrFour.push(anticoagulantsConfitOne[item])
  1442. }
  1443. })
  1444. this.anticoagulantsConfit = arrFour
  1445. this.dialysisList = this.devices
  1446. this.body_fluid_option = this.$store.getters.body_fluid
  1447. this.special_medicine_option = this.$store.getters.special_medicine
  1448. this.displace_liqui_part_option = this.$store.getters.displace_liqui
  1449. this.hemodialysisPipelinesOptions = getDataConfig('hemodialysis', 'hemodialysis_pipelines')
  1450. this.punctureNeedleOptions = getDataConfig('hemodialysis', 'puncture_needle')
  1451. this.epoOptions = getDataConfig('hemodialysis', 'epo')
  1452. // this.blood_access_option = this.$store.getters.blood_access_internal_fistula;
  1453. this.blood_access_option = getDataConfig(
  1454. 'hemodialysis',
  1455. 'vascular_access_desc'
  1456. )
  1457. // console.log('血管通路', this.blood_access_option)
  1458. this.dialyzerPerfusionApparatus = getDataConfig(
  1459. 'hemodialysis',
  1460. 'dialyzer_perfusion_apparatus'
  1461. )
  1462. // console.log('3333333', this.dialyzerPerfusionApparatus)
  1463. this.bloods = getDataConfig(
  1464. 'hemodialysis',
  1465. 'blood'
  1466. )
  1467. // dialyzerPerfusionApparatus.map(item => {
  1468. // item.name = item.name.toUpperCase()
  1469. // })
  1470. // //去重
  1471. // var arr = this.unique(dialyzerPerfusionApparatus)
  1472. // this.dialyzerPerfusionApparatus = arr
  1473. // console.log('灌流器', arr)
  1474. if (this.$route.query && this.$route.query.date) {
  1475. var date = this.$route.query && this.$route.query.date
  1476. this.record_date = uParseTime(date, '{y}-{m}-{d}')
  1477. } else {
  1478. var date = schedual.schedule_date
  1479. this.record_date = uParseTime(date, '{y}-{m}-{d}')
  1480. }
  1481. if (this.prescription != null && typeof this.prescription.id !== 'undefined' && this.prescription.id > 0) {
  1482. for (const key in this.prescription) {
  1483. this.dialysisPrescription[key] = this.prescription[key]
  1484. }
  1485. } else if (this.solution != null && typeof this.solution.id !== 'undefined' && this.solution.id > 0) {
  1486. for (const key in this.solution) {
  1487. if (key != 'target_ultrafiltration') {
  1488. this.dialysisPrescription[key] = this.solution[key]
  1489. }
  1490. }
  1491. } else if (lastDialysisPrescribe != null && typeof lastDialysisPrescribe.id !== 'undefined' && lastDialysisPrescribe.id > 0) {
  1492. for (const key in lastDialysisPrescribe) {
  1493. if (key != 'target_ultrafiltration') {
  1494. this.dialysisPrescription[key] = lastDialysisPrescribe[key]
  1495. }
  1496. }
  1497. } else if (system_prescribe != null && typeof system_prescribe.id !== 'undefined' && system_prescribe.id > 0) {
  1498. for (const key in system_prescribe) {
  1499. if (key != 'target_ultrafiltration') {
  1500. this.dialysisPrescription[key] = system_prescribe[key]
  1501. }
  1502. }
  1503. } else {
  1504. if (schedual.mode_id == 2 || schedual.mode_id == 5 || schedual.mode_id == 12) {
  1505. this.zhiShow = true
  1506. this.huShow = true
  1507. this.totalShow = true
  1508. } else {
  1509. this.zhiShow = false
  1510. this.huShow = false
  1511. this.totalShow = false
  1512. }
  1513. // this.dialysisPrescription.mode_id = schedual.mode_id
  1514. }
  1515. var thismode = parseInt(this.dialysisPrescription.anticoagulant)
  1516. if (isNaN(thismode) || thismode <= 0) {
  1517. return false
  1518. }
  1519. if (
  1520. typeof this.anticoagulantsConfit[thismode] === 'undefined' ||
  1521. this.anticoagulantsConfit[thismode] == null
  1522. ) {
  1523. return false
  1524. }
  1525. this.anticoagulant = this.$store.getters.anticoagulants_confit[thismode]
  1526. },
  1527. menuMsgTip: function() {
  1528. this.msgtip_visibility = false
  1529. this.isVisibility = true
  1530. },
  1531. handleAdviceCommit() {
  1532. //
  1533. let results = []
  1534. for (let i = 0; i < this.targetAdvices.length; i++) {
  1535. for (let a = 0; a < this.checkedCities.length; a++) {
  1536. if (this.targetAdvices[i].id == this.checkedCities[a]) {
  1537. results.push(this.targetAdvices[i])
  1538. }
  1539. }
  1540. }
  1541. var obj5 = {}
  1542. results = results.reduce((cur, next) => {
  1543. obj5[next.id] ? '' : (obj5[next.id] = true && cur.push(next))
  1544. return cur
  1545. }, [])
  1546. var date = new Date()
  1547. var hour = date.getHours() < 10 ? '0' + date.getHours() : date.getHours()
  1548. var minute =
  1549. date.getMinutes() < 10 ? '0' + date.getMinutes() : date.getMinutes()
  1550. if (results.length > 0) {
  1551. if (this.is_pre == 1) {
  1552. if (this.patient.id <= 0) {
  1553. this.$message.error('没有选择患者')
  1554. this.loading = false
  1555. return
  1556. }
  1557. var arr = this.dialysisPrescription
  1558. // console.log('arr', arr)
  1559. const ParamsQuery = arr
  1560. // console.log('医嘱推送2', ParamsQuery)
  1561. ParamsQuery['patient'] = this.patient.id
  1562. ParamsQuery['record_date'] = this.record_date
  1563. if (this.prescription.creater <= 0) {
  1564. ParamsQuery['mode'] = '1'
  1565. } else {
  1566. ParamsQuery['mode'] = '2'
  1567. if (
  1568. this.$store.getters.xt_user.user.id !=
  1569. this.dialysisPrescription.creater
  1570. ) {
  1571. ParamsQuery['mode'] = '3'
  1572. }
  1573. }
  1574. postPrescription(ParamsQuery).then(response => {
  1575. if (response.data.state == 0) {
  1576. this.$message.error(response.data.msg)
  1577. return false
  1578. } else {
  1579. this.$notify({
  1580. title: '成功',
  1581. message: '提交成功',
  1582. type: 'success',
  1583. duration: 2000
  1584. })
  1585. var date = new Date()
  1586. // console.log(this.start_time)
  1587. const params = {
  1588. advices: results,
  1589. advice_date: this.start_time.split(' ')[0],
  1590. advice_doctor: results[0].advice_doctor,
  1591. advice_type: results[0].advice_type,
  1592. parent_id: this.patient_id,
  1593. start_time: this.start_time,
  1594. remark: ''
  1595. }
  1596. CreateGroupAdvice(this.$route.query.patient_id, 0, params).then(
  1597. rs => {
  1598. var resp = rs.data
  1599. if (resp.state == 1) {
  1600. this.doctorAdvices = resp.data.advices
  1601. this.$emit('advice')
  1602. } else {
  1603. }
  1604. }
  1605. )
  1606. const prescription_resp = response.data.data.prescription
  1607. var prescription = this.prescription
  1608. for (var index in prescription_resp) {
  1609. // prescription[index] = prescription_resp[index];
  1610. this.$set(prescription, index, prescription_resp[index])
  1611. }
  1612. this.hide()
  1613. }
  1614. })
  1615. } else if (this.is_pre == 2) {
  1616. if (this.patient.id <= 0) {
  1617. this.$message.error('没有选择患者')
  1618. this.loading = false
  1619. return
  1620. }
  1621. var arr = this.dialysisPrescription
  1622. // console.log('arr', arr)
  1623. const ParamsQuery = arr
  1624. // console.log('医嘱推送3', ParamsQuery)
  1625. ParamsQuery['patient'] = this.patient.id
  1626. ParamsQuery['record_date'] = this.record_date
  1627. ParamsQuery['mode'] = 1
  1628. postSoulution(ParamsQuery).then(response => {
  1629. if (response.data.state == 0) {
  1630. this.$message.error(response.data.msg)
  1631. return false
  1632. } else {
  1633. this.$notify({
  1634. title: '成功',
  1635. message: '提交成功',
  1636. type: 'success',
  1637. duration: 2000
  1638. })
  1639. // console.log(hour + ':' + minute)
  1640. var date = new Date()
  1641. var hour =
  1642. date.getHours() < 10 ? '0' + date.getHours() : date.getHours()
  1643. var minute =
  1644. date.getMinutes() < 10
  1645. ? '0' + date.getMinutes()
  1646. : date.getMinutes()
  1647. const params = {
  1648. advices: results,
  1649. advice_date: this.start_time.split(' ')[0],
  1650. advice_doctor: results[0].advice_doctor,
  1651. advice_type: results[0].advice_type,
  1652. parent_id: this.patient_id,
  1653. start_time: this.start_time,
  1654. remark: ''
  1655. }
  1656. CreateGroupAdvice(this.$route.query.patient_id, 0, params).then(
  1657. rs => {
  1658. var resp = rs.data
  1659. if (resp.state == 1) {
  1660. // this.doctorAdvices = resp.data.advices
  1661. this.$emit('advice')
  1662. } else {
  1663. }
  1664. }
  1665. )
  1666. const prescription_resp = response.data.data.prescription
  1667. const solution_resp = response.data.data.solution
  1668. var prescription = this.prescription
  1669. var solution = this.solution
  1670. for (var index in prescription_resp) {
  1671. // prescription[index] = prescription_resp[index];
  1672. this.$set(prescription, index, prescription_resp[index])
  1673. }
  1674. for (var index in solution_resp) {
  1675. // solution[index] = solution_resp[index];
  1676. this.$set(solution, index, solution_resp[index])
  1677. }
  1678. this.hide()
  1679. }
  1680. })
  1681. }
  1682. } else {
  1683. if (this.is_pre == 1) {
  1684. if (this.patient.id <= 0) {
  1685. this.$message.error('没有选择患者')
  1686. this.loading = false
  1687. return
  1688. }
  1689. var arr = this.dialysisPrescription
  1690. const ParamsQuery = arr
  1691. // console.log('医嘱推送4', ParamsQuery)
  1692. ParamsQuery['patient'] = this.patient.id
  1693. ParamsQuery['record_date'] = this.record_date
  1694. // console.log(this.prescription)
  1695. let mode = ''
  1696. if (this.prescription.creater <= 0) {
  1697. mode = 1
  1698. } else {
  1699. mode = 2
  1700. }
  1701. ParamsQuery['mode'] = mode
  1702. // console.log("paramsquery",ParamsQuery)
  1703. postPrescription(ParamsQuery).then(response => {
  1704. if (response.data.state == 0) {
  1705. this.$message.error(response.data.msg)
  1706. return false
  1707. } else {
  1708. this.$notify({
  1709. title: '成功',
  1710. message: '提交成功',
  1711. type: 'success',
  1712. duration: 2000
  1713. })
  1714. const prescription_resp = response.data.data.prescription
  1715. var prescription = this.prescription
  1716. for (var index in prescription_resp) {
  1717. // prescription[index] = prescription_resp[index];
  1718. this.$set(prescription, index, prescription_resp[index])
  1719. }
  1720. this.hide()
  1721. }
  1722. })
  1723. } else if (this.is_pre == 2) {
  1724. if (this.patient.id <= 0) {
  1725. this.$message.error('没有选择患者')
  1726. this.loading = false
  1727. return
  1728. }
  1729. var arr = this.dialysisPrescription
  1730. const ParamsQuery = arr
  1731. ParamsQuery['patient'] = this.patient.id
  1732. ParamsQuery['record_date'] = this.record_date
  1733. ParamsQuery['mode'] = 1
  1734. postSoulution(ParamsQuery).then(response => {
  1735. if (response.data.state == 0) {
  1736. this.$message.error(response.data.msg)
  1737. return false
  1738. } else {
  1739. this.$notify({
  1740. title: '成功',
  1741. message: '提交成功',
  1742. type: 'success',
  1743. duration: 2000
  1744. })
  1745. const prescription_resp = response.data.data.prescription
  1746. const solution_resp = response.data.data.solution
  1747. var prescription = this.prescription
  1748. var solution = this.solution
  1749. for (var index in prescription_resp) {
  1750. // prescription[index] = prescription_resp[index];
  1751. this.$set(prescription, index, prescription_resp[index])
  1752. }
  1753. for (var index in solution_resp) {
  1754. // solution[index] = solution_resp[index];
  1755. this.$set(solution, index, solution_resp[index])
  1756. }
  1757. this.hide()
  1758. }
  1759. })
  1760. }
  1761. }
  1762. this.isShowRemindAdvice = false
  1763. this.isVisibility = true
  1764. },
  1765. handleAdviceCancle() {
  1766. this.isShowRemindAdvice = false
  1767. this.isVisibility = true
  1768. },
  1769. getTime(val) {
  1770. return uParseTime(val, '{y}-{m}-{d} {h}:{i}')
  1771. },
  1772. show(pre, schedual, last, his_is_open) {
  1773. console.log('pre222222', this.predialysis)
  1774. if (pre != undefined) {
  1775. if (pre.oxygen_uptake == 1) {
  1776. this.oxygenShow = true
  1777. }
  1778. if (pre.oxygen_uptake == 2) {
  1779. this.oxygenShow = false
  1780. this.prescription.oxygen_flow = ''
  1781. this.prescription.oxygen_time = ''
  1782. }
  1783. }
  1784. if (his_is_open == 1) {
  1785. this.is_open = 0
  1786. }
  1787. if(this.$store.getters.xt_user.org.id == 10101){
  1788. if (this.predialysis.id > 0 && this.predialysis.created_time > 0) {
  1789. var date = new Date(this.predialysis.created_time * 1000)
  1790. var year = date.getFullYear()
  1791. var month = date.getMonth() + 1
  1792. var day = date.getDate()
  1793. var hours = date.getHours()
  1794. var minites = date.getMinutes()
  1795. if (month < 10) {
  1796. month = '0' + month
  1797. }
  1798. if (day < 10) {
  1799. day = '0' + day
  1800. }
  1801. if (hours < 10) {
  1802. hours = '0' + hours
  1803. }
  1804. if (minites < 10) {
  1805. minites = '0' + minites
  1806. }
  1807. this.start_time = year + '-' + month + '-' + day + ' ' + hours + ':' + minites
  1808. } else {
  1809. var date = new Date()
  1810. var year = date.getFullYear()
  1811. var month = date.getMonth() + 1
  1812. var day = date.getDate()
  1813. var hours = date.getHours()
  1814. var minites = date.getMinutes()
  1815. if (month < 10) {
  1816. month = '0' + month
  1817. }
  1818. if (day < 10) {
  1819. day = '0' + day
  1820. }
  1821. if (hours < 10) {
  1822. hours = '0' + hours
  1823. }
  1824. if (minites < 10) {
  1825. minites = '0' + minites
  1826. }
  1827. this.start_time = year + '-' + month + '-' + day + ' ' + hours + ':' + minites
  1828. }
  1829. }else{
  1830. var date = new Date()
  1831. var year = date.getFullYear()
  1832. var month = date.getMonth() + 1
  1833. var day = date.getDate()
  1834. var hours = date.getHours()
  1835. var minites = date.getMinutes()
  1836. if (month < 10) {
  1837. month = '0' + month
  1838. }
  1839. if (day < 10) {
  1840. day = '0' + day
  1841. }
  1842. if (hours < 10) {
  1843. hours = '0' + hours
  1844. }
  1845. if (minites < 10) {
  1846. minites = '0' + minites
  1847. }
  1848. 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 ) {
  1849. this.start_time = year + '-' + month + '-' + day + ' ' + hours + ':' + minites
  1850. }else if(this.$store.getters.xt_user.org.id == 10234 || this.$store.getters.xt_user.org.id == 9671){
  1851. if (schedual.schedule_type == 1) {
  1852. this.start_time = year + '-' + month + '-' + day + ' ' + '06:00'
  1853. } else if (schedual.schedule_type == 2) {
  1854. this.start_time = year + '-' + month + '-' + day + ' ' + '11:00'
  1855. } else if (schedual.schedule_type == 3) {
  1856. this.start_time = year + '-' + month + '-' + day + ' ' + '18:00'
  1857. }
  1858. } else {
  1859. if (schedual.schedule_type == 1) {
  1860. this.start_time = year + '-' + month + '-' + day + ' ' + '07:00'
  1861. } else if (schedual.schedule_type == 2) {
  1862. this.start_time = year + '-' + month + '-' + day + ' ' + '12:00'
  1863. } else if (schedual.schedule_type == 3) {
  1864. this.start_time = year + '-' + month + '-' + day + ' ' + '18:00'
  1865. }
  1866. }
  1867. }
  1868. if (pre.anticoagulant == 3) {
  1869. this.dialysisPrescription.anticoagulant = '低分子肝素'
  1870. }
  1871. // 入口
  1872. var pre = pre
  1873. this.dialysisPrescription.mode_id = this.$route.query.mode_id ? this.$route.query.mode_id : this.mode_id
  1874. if (pre.id > 0) {
  1875. this.dialysisPrescription.mode_id = pre.mode_id
  1876. }
  1877. console.log('this.dialysisPrescription.mode_id', this.dialysisPrescription.mode_id)
  1878. console.log('this.schedual', schedual.mode_id)
  1879. 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) {
  1880. this.zhiShow = true
  1881. this.huShow = true
  1882. this.totalShow = true
  1883. } else if (
  1884. pre.mode_id == 1 ||
  1885. pre.mode_id == 3 ||
  1886. pre.mode_id == 4 ||
  1887. pre.mode_id == 6 ||
  1888. pre.mode_id == 7 ||
  1889. pre.mode_id == 8 ||
  1890. pre.mode_id == 9 ||
  1891. pre.mode_id == 10 ||
  1892. pre.mode_id == 11 ||
  1893. pre.mode_id == 13 ||
  1894. pre.mode_id == 14 ||
  1895. pre.mode_id == 19
  1896. ) {
  1897. this.zhiShow = false
  1898. this.huShow = false
  1899. this.totalShow = false
  1900. }
  1901. this.pre = pre
  1902. // console.log("pre1", pre);
  1903. this.getPermission()
  1904. let last_weight_after = 0
  1905. let weight_before = 0
  1906. if (this.last_record == null) {
  1907. last_weight_after = 0
  1908. } else {
  1909. last_weight_after = this.last_record.weight_after
  1910. }
  1911. if (this.predialysis == null || this.predialysis.id == 0) {
  1912. if (last != null) {
  1913. this.dialysisPrescription.niprocart = last.niprocart
  1914. this.dialysisPrescription.jms = last.jms
  1915. this.dialysisPrescription.fistula_needle_set = last.fistula_needle_set
  1916. this.dialysisPrescription.fistula_needle_set_16 = last.fistula_needle_set_16
  1917. this.dialysisPrescription.hemoperfusion = last.hemoperfusion
  1918. this.dialysisPrescription.dialyser_sterilised = last.dialyser_sterilised
  1919. this.dialysisPrescription.filtryzer = last.filtryzer
  1920. this.dialysisPrescription.target_ktv = last.target_ktv
  1921. this.dialysisPrescription.dialyzers = last.dialyzers
  1922. this.dialysisPrescription.injector = last.injector
  1923. this.dialysisPrescription.bloodlines = last.bloodlines
  1924. this.dialysisPrescription.tubing_hemodialysis = last.tubing_hemodialysis
  1925. this.dialysisPrescription.package = last.package
  1926. this.dialysisPrescription.a_liquid = last.a_liquid
  1927. weight_before = 0
  1928. }
  1929. } else {
  1930. weight_before = this.predialysis.weight_before
  1931. }
  1932. //获取最后一次血管通路
  1933. // console.log("最后一次血管通路",this.predialysis)
  1934. // if(this.predialysis!=null){
  1935. // if(this.lastAssessment!=null){
  1936. // var blood_id = 0
  1937. // for(let i= 0;i<this.blood_access_option.length;i++){
  1938. // if(this.lastAssessment.blood_access_part_opera_id == this.blood_access_option[i].name){
  1939. // blood_id = this.blood_access_option[i].id
  1940. // }
  1941. // }
  1942. // console.log("中国人名职员",this.lastAssessment)
  1943. // this.dialysisPrescription.blood_access = blood_id
  1944. // }else{
  1945. // if(this.last_prescription!=null){
  1946. // var blood_id = 0
  1947. // for(let i= 0;i<this.blood_access_option.length;i++){
  1948. // if(this.last_prescription.blood_access_part_opera_id == this.blood_access_option[i].name){
  1949. // blood_id = this.blood_access_option[i].id
  1950. // }
  1951. // }
  1952. // this.dialysisPrescription.blood_access = blood_id
  1953. // }
  1954. // }
  1955. // }
  1956. if (weight_before > 0 && last_weight_after > 0) {
  1957. this.add_weight = parseFloat(weight_before - last_weight_after).toFixed(
  1958. 2
  1959. )
  1960. // console.log('体重增加', this.add_weight)
  1961. }
  1962. this.isVisibility = true
  1963. this.checkedCities = []
  1964. for (let i = 0; i < this.targetAdvices.length; i++) {
  1965. if (this.targetAdvices[i].isCheck == 1) {
  1966. this.checkedCities.push(this.targetAdvices[i].id)
  1967. }
  1968. }
  1969. },
  1970. hide() {
  1971. this.isVisibility = false
  1972. },
  1973. changeThisAnticoagulant: function(val) {
  1974. console.log("val",val)
  1975. var thismode = val
  1976. if (isNaN(thismode) || thismode <= 0) {
  1977. return false
  1978. }
  1979. if (val <= 2) {
  1980. this.anticoagulant = this.anticoagulantsConfit[thismode - 1]
  1981. }
  1982. if (val > 2) {
  1983. this.anticoagulant = this.anticoagulantsConfit[thismode - 2]
  1984. }
  1985. if ((this.$store.getters.xt_user.template_info.template_id == 13 || this.$store.getters.xt_user.template_info.template_id == 41) && val == 2) {
  1986. if(val == 2){
  1987. this.anticoagulant.shouji_unit = 'mg'
  1988. }else{
  1989. this.anticoagulant.shouji_unit = 'iu'
  1990. }
  1991. this.anticoagulant.weichi_unit = 'mg/h'
  1992. this.anticoagulant.zongliang_unit = 'mg'
  1993. }
  1994. if (this.$store.getters.xt_user.template_info.template_id == 27 && val == 4) {
  1995. this.anticoagulant.shouji_unit = 'ml'
  1996. this.anticoagulant.weichi_unit = 'ml'
  1997. this.anticoagulant.zongliang_unit = 'ml'
  1998. }
  1999. console.log('首季9999', this.dialysisPrescription.anticoagulant_zongliang)
  2000. console.log("收集",this.dialysisPrescription.anticoagulant_shouji)
  2001. console.log("weichi",this.dialysisPrescription.anticoagulant_weichi)
  2002. if(this.$store.getters.xt_user.template_info.template_id == 41 && this.dialysisPrescription.anticoagulant == 2){
  2003. this.dialysisPrescription.anticoagulant_zongliang = ""
  2004. this.dialysisPrescription.anticoagulant_zongliang = parseInt(this.dialysisPrescription.anticoagulant_shouji) + parseInt(this.dialysisPrescription.anticoagulant_weichi)
  2005. }
  2006. },
  2007. handleCommit: function() {
  2008. if (this.dialysisPrescription.anticoagulant == '低分子肝素') {
  2009. this.dialysisPrescription.anticoagulant = 3
  2010. }
  2011. if (this.dialysisPrescription.anticoagulant == 1) {
  2012. this.dialysisPrescription.anticoagulant_weichi = '0'
  2013. this.dialysisPrescription.anticoagulant_shouji = '0'
  2014. this.dialysisPrescription.anticoagulant_zongliang = '0'
  2015. }
  2016. if (this.$store.getters.xt_user.template_info.template_id == 6) {
  2017. if (this.dialysisPrescription.mode_id == 2) {
  2018. if (
  2019. this.dialysisPrescription.displace_liqui_part == 0 ||
  2020. this.dialysisPrescription.displace_liqui_part == -2 ||
  2021. this.dialysisPrescription.displace_liqui_value == 0 ||
  2022. this.dialysisPrescription.displace_liqui_value == ''
  2023. ) {
  2024. this.$message.error('HDF模式下置换液和置换液总量不能为空!')
  2025. return
  2026. }
  2027. }
  2028. }
  2029. this.is_pre = 1
  2030. if (this.prescription.id == 0) {
  2031. if (this.is_open == 0) {
  2032. if (this.patient.id <= 0) {
  2033. this.$message.error('没有选择患者')
  2034. this.loading = false
  2035. return
  2036. }
  2037. var arr = this.dialysisPrescription
  2038. const ParamsQuery = arr
  2039. // console.log('night', ParamsQuery)
  2040. ParamsQuery['patient'] = this.patient.id
  2041. ParamsQuery['record_date'] = this.record_date
  2042. ParamsQuery['mode'] = '1'
  2043. console.log('第一', ParamsQuery)
  2044. postPrescription(ParamsQuery).then(response => {
  2045. if (response.data.state == 0) {
  2046. this.$message.error(response.data.msg)
  2047. return false
  2048. } else {
  2049. this.$notify({
  2050. title: '成功',
  2051. message: '提交成功',
  2052. type: 'success',
  2053. duration: 2000
  2054. })
  2055. const prescription_resp = response.data.data.prescription
  2056. var prescription = this.prescription
  2057. for (var index in prescription_resp) {
  2058. // prescription[index] = prescription_resp[index];
  2059. this.$set(prescription, index, prescription_resp[index])
  2060. }
  2061. this.hide()
  2062. }
  2063. })
  2064. } else if (this.is_open == 1) {
  2065. if (this.targetAdvices.length > 0) {
  2066. // 弹框推送提醒
  2067. this.isShowRemindAdvice = true
  2068. this.isVisibility = false
  2069. } else {
  2070. if (this.patient.id <= 0) {
  2071. this.$message.error('没有选择患者')
  2072. this.loading = false
  2073. return
  2074. }
  2075. var arr = this.dialysisPrescription
  2076. const ParamsQuery = arr
  2077. // console.log('ParamsQuerytwo', ParamsQuery)
  2078. ParamsQuery['patient'] = this.patient.id
  2079. ParamsQuery['record_date'] = this.record_date
  2080. ParamsQuery['mode'] = '1'
  2081. console.log('第二')
  2082. postPrescription(ParamsQuery).then(response => {
  2083. if (response.data.state == 0) {
  2084. this.$message.error(response.data.msg)
  2085. return false
  2086. } else {
  2087. this.$notify({
  2088. title: '成功',
  2089. message: '提交成功',
  2090. type: 'success',
  2091. duration: 2000
  2092. })
  2093. const prescription_resp = response.data.data.prescription
  2094. var prescription = this.prescription
  2095. for (var index in prescription_resp) {
  2096. // prescription[index] = prescription_resp[index];
  2097. this.$set(prescription, index, prescription_resp[index])
  2098. }
  2099. this.hide()
  2100. }
  2101. })
  2102. }
  2103. } else if (this.is_open == 2) {
  2104. var date = new Date()
  2105. var hour =
  2106. date.getHours() < 10 ? '0' + date.getHours() : date.getHours()
  2107. var minute =
  2108. date.getMinutes() < 10
  2109. ? '0' + date.getMinutes()
  2110. : date.getMinutes()
  2111. if (this.waitUploadAdvices.length > 0) {
  2112. if (this.patient.id <= 0) {
  2113. this.$message.error('没有选择患者')
  2114. this.loading = false
  2115. return
  2116. }
  2117. var arr = this.dialysisPrescription
  2118. const ParamsQuery = arr
  2119. console.log('paramsquerythree', ParamsQuery)
  2120. ParamsQuery['patient'] = this.patient.id
  2121. ParamsQuery['record_date'] = this.record_date
  2122. ParamsQuery['mode'] = '1'
  2123. console.log('第三')
  2124. postPrescription(ParamsQuery).then(response => {
  2125. if (response.data.state == 0) {
  2126. this.$message.error(response.data.msg)
  2127. return false
  2128. } else {
  2129. this.$notify({
  2130. title: '成功',
  2131. message: '提交成功',
  2132. type: 'success',
  2133. duration: 2000
  2134. })
  2135. const params = {
  2136. advices: this.waitUploadAdvices,
  2137. advice_date: uParseTime(
  2138. this.$route.query.date,
  2139. '{y}-{m}-{d}'
  2140. ),
  2141. advice_doctor: this.waitUploadAdvices[0].advice_doctor,
  2142. advice_type: this.waitUploadAdvices[0].advice_type,
  2143. parent_id: this.patient_id,
  2144. // start_time: uParseTime(this.$route.query.date, '{y}-{m}-{d}'),
  2145. start_time:
  2146. uParseTime(this.$route.query.date, '{y}-{m}-{d}') +
  2147. ' ' +
  2148. this.advice_start_time,
  2149. remark: ''
  2150. }
  2151. console.log('params--------', params)
  2152. CreateGroupAdvice(this.$route.query.patient_id, 0, params).then(
  2153. rs => {
  2154. var resp = rs.data
  2155. if (resp.state == 1) {
  2156. // this.doctorAdvices = resp.data.advices
  2157. this.$emit('advice')
  2158. } else {
  2159. }
  2160. }
  2161. )
  2162. const prescription_resp = response.data.data.prescription
  2163. var prescription = this.prescription
  2164. for (var index in prescription_resp) {
  2165. // prescription[index] = prescription_resp[index];
  2166. this.$set(prescription, index, prescription_resp[index])
  2167. }
  2168. this.hide()
  2169. }
  2170. })
  2171. } else {
  2172. if (this.patient.id <= 0) {
  2173. this.$message.error('没有选择患者')
  2174. this.loading = false
  2175. return
  2176. }
  2177. var arr = this.dialysisPrescription
  2178. const ParamsQuery = arr
  2179. // console.log('paramsqueryfour', ParamsQuery)
  2180. // console.log('创建者', this.prescription.creater)
  2181. // if (this.prescription.creater <= 0) {
  2182. // mode = 1;
  2183. // } else {
  2184. // mode = 2;
  2185. // }
  2186. ParamsQuery['patient'] = this.patient.id
  2187. ParamsQuery['record_date'] = this.record_date
  2188. // console.log(this.prescription);
  2189. console.log('第四')
  2190. postPrescription(ParamsQuery).then(response => {
  2191. if (response.data.state == 0) {
  2192. this.$message.error(response.data.msg)
  2193. return false
  2194. } else {
  2195. this.$notify({
  2196. title: '成功',
  2197. message: '提交成功',
  2198. type: 'success',
  2199. duration: 2000
  2200. })
  2201. const prescription_resp = response.data.data.prescription
  2202. // console.log("aaaaaaa", prescription_resp);
  2203. var prescription = this.prescription
  2204. for (var index in prescription_resp) {
  2205. // prescription[index] = prescription_resp[index];
  2206. this.$set(prescription, index, prescription_resp[index])
  2207. }
  2208. this.hide()
  2209. }
  2210. })
  2211. }
  2212. }
  2213. } else {
  2214. if (this.prescription.creater == 0) {
  2215. if (this.is_open == 0) {
  2216. if (this.patient.id <= 0) {
  2217. this.$message.error('没有选择患者')
  2218. this.loading = false
  2219. return
  2220. }
  2221. var arr = this.dialysisPrescription
  2222. // console.log('arr', arr)
  2223. const ParamsQuery = arr
  2224. // console.log('paramsqueryfive', ParamsQuery)
  2225. ParamsQuery['patient'] = this.patient.id
  2226. ParamsQuery['record_date'] = this.record_date
  2227. ParamsQuery['mode'] = '1'
  2228. console.log('第五')
  2229. postPrescription(ParamsQuery).then(response => {
  2230. if (response.data.state == 0) {
  2231. this.$message.error(response.data.msg)
  2232. return false
  2233. } else {
  2234. this.$notify({
  2235. title: '成功',
  2236. message: '提交成功',
  2237. type: 'success',
  2238. duration: 2000
  2239. })
  2240. const prescription_resp = response.data.data.prescription
  2241. var prescription = this.prescription
  2242. for (var index in prescription_resp) {
  2243. // prescription[index] = prescription_resp[index];
  2244. this.$set(prescription, index, prescription_resp[index])
  2245. }
  2246. this.hide()
  2247. }
  2248. })
  2249. } else if (this.is_open == 1) {
  2250. if (this.targetAdvices.length > 0) {
  2251. // 弹框推送提醒
  2252. this.isShowRemindAdvice = true
  2253. this.isVisibility = false
  2254. } else {
  2255. if (this.patient.id <= 0) {
  2256. this.$message.error('没有选择患者')
  2257. this.loading = false
  2258. return
  2259. }
  2260. var arr = this.dialysisPrescription
  2261. // console.log('arr', arr)
  2262. const ParamsQuery = arr
  2263. // console.log('ParamsQuerysix', ParamsQuery)
  2264. ParamsQuery['patient'] = this.patient.id
  2265. ParamsQuery['record_date'] = this.record_date
  2266. ParamsQuery['mode'] = '1'
  2267. console.log('第6')
  2268. postPrescription(ParamsQuery).then(response => {
  2269. if (response.data.state == 0) {
  2270. this.$message.error(response.data.msg)
  2271. return false
  2272. } else {
  2273. this.$notify({
  2274. title: '成功',
  2275. message: '提交成功',
  2276. type: 'success',
  2277. duration: 2000
  2278. })
  2279. const prescription_resp = response.data.data.prescription
  2280. var prescription = this.prescription
  2281. for (var index in prescription_resp) {
  2282. // prescription[index] = prescription_resp[index];
  2283. this.$set(prescription, index, prescription_resp[index])
  2284. }
  2285. this.hide()
  2286. }
  2287. })
  2288. }
  2289. } else if (this.is_open == 2) {
  2290. var date = new Date()
  2291. var hour =
  2292. date.getHours() < 10 ? '0' + date.getHours() : date.getHours()
  2293. var minute =
  2294. date.getMinutes() < 10
  2295. ? '0' + date.getMinutes()
  2296. : date.getMinutes()
  2297. if (this.waitUploadAdvices.length > 0) {
  2298. if (this.patient.id <= 0) {
  2299. this.$message.error('没有选择患者')
  2300. this.loading = false
  2301. return
  2302. }
  2303. var arr = this.dialysisPrescription
  2304. // console.log('arr', arr)
  2305. const ParamsQuery = arr
  2306. // console.log('parasmqueryseven', parasmqueryseven)
  2307. ParamsQuery['patient'] = this.patient.id
  2308. ParamsQuery['record_date'] = this.record_date
  2309. ParamsQuery['mode'] = '1'
  2310. console.log('第七')
  2311. postPrescription(ParamsQuery).then(response => {
  2312. if (response.data.state == 0) {
  2313. this.$message.error(response.data.msg)
  2314. return false
  2315. } else {
  2316. this.$notify({
  2317. title: '成功',
  2318. message: '提交成功',
  2319. type: 'success',
  2320. duration: 2000
  2321. })
  2322. const params = {
  2323. advices: this.waitUploadAdvices,
  2324. advice_date: uParseTime(
  2325. this.$route.query.date,
  2326. '{y}-{m}-{d}'
  2327. ),
  2328. advice_doctor: this.waitUploadAdvices[0].advice_doctor,
  2329. advice_type: this.waitUploadAdvices[0].advice_type,
  2330. parent_id: this.patient_id,
  2331. // start_time: uParseTime(this.$route.query.date, '{y}-{m}-{d}'),
  2332. start_time:
  2333. uParseTime(this.$route.query.date, '{y}-{m}-{d}') +
  2334. ' ' +
  2335. hour +
  2336. ':' +
  2337. minute,
  2338. remark: ''
  2339. }
  2340. CreateGroupAdvice(
  2341. this.$route.query.patient_id,
  2342. 0,
  2343. params
  2344. ).then(rs => {
  2345. var resp = rs.data
  2346. if (resp.state == 1) {
  2347. // this.doctorAdvices = resp.data.advices
  2348. this.$emit('advice')
  2349. } else {
  2350. }
  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. } else {
  2362. if (this.patient.id <= 0) {
  2363. this.$message.error('没有选择患者')
  2364. this.loading = false
  2365. return
  2366. }
  2367. var arr = this.dialysisPrescription
  2368. // console.log('arr', arr)
  2369. const ParamsQuery = arr
  2370. // console.log('eight', ParamsQuery)
  2371. ParamsQuery['patient'] = this.patient.id
  2372. ParamsQuery['record_date'] = this.record_date
  2373. ParamsQuery['mode'] = '1'
  2374. console.log('第八')
  2375. postPrescription(ParamsQuery).then(response => {
  2376. if (response.data.state == 0) {
  2377. this.$message.error(response.data.msg)
  2378. return false
  2379. } else {
  2380. this.$notify({
  2381. title: '成功',
  2382. message: '提交成功',
  2383. type: 'success',
  2384. duration: 2000
  2385. })
  2386. const prescription_resp = response.data.data.prescription
  2387. var prescription = this.prescription
  2388. for (var index in prescription_resp) {
  2389. // prescription[index] = prescription_resp[index];
  2390. this.$set(prescription, index, prescription_resp[index])
  2391. }
  2392. this.hide()
  2393. }
  2394. })
  2395. }
  2396. }
  2397. } else {
  2398. if (this.patient.id <= 0) {
  2399. this.$message.error('没有选择患者')
  2400. this.loading = false
  2401. return
  2402. }
  2403. var arr = this.dialysisPrescription
  2404. // console.log('arr', arr)
  2405. const ParamsQuery = arr
  2406. // console.log('night', ParamsQuery)
  2407. ParamsQuery['patient'] = this.patient.id
  2408. ParamsQuery['record_date'] = this.record_date
  2409. ParamsQuery['mode'] = '2'
  2410. if (
  2411. this.$store.getters.xt_user.user.id !=
  2412. this.dialysisPrescription.creater
  2413. ) {
  2414. ParamsQuery['mode'] = '3'
  2415. }
  2416. console.log('第九')
  2417. postPrescription(ParamsQuery).then(response => {
  2418. if (response.data.state == 0) {
  2419. this.$message.error(response.data.msg)
  2420. return false
  2421. } else {
  2422. this.$notify({
  2423. title: '成功',
  2424. message: '提交成功',
  2425. type: 'success',
  2426. duration: 2000
  2427. })
  2428. const prescription_resp = response.data.data.prescription
  2429. var prescription = this.prescription
  2430. for (var index in prescription_resp) {
  2431. // prescription[index] = prescription_resp[index];
  2432. this.$set(prescription, index, prescription_resp[index])
  2433. }
  2434. this.hide()
  2435. }
  2436. })
  2437. }
  2438. }
  2439. },
  2440. handleCancle: function() {
  2441. this.hide()
  2442. },
  2443. handleSolution: function() {
  2444. if (this.dialysisPrescription.anticoagulant == 1) {
  2445. this.dialysisPrescription.anticoagulant_weichi = '0'
  2446. this.dialysisPrescription.anticoagulant_shouji = '0'
  2447. this.dialysisPrescription.anticoagulant_zongliang = '0'
  2448. }
  2449. if (this.$store.getters.xt_user.template_info.template_id == 6) {
  2450. if (this.dialysisPrescription.mode_id == 2) {
  2451. if (
  2452. this.dialysisPrescription.displace_liqui_part == 0 ||
  2453. this.dialysisPrescription.displace_liqui_part == -2 ||
  2454. this.dialysisPrescription.displace_liqui_value == 0 ||
  2455. this.dialysisPrescription.displace_liqui_value == ''
  2456. ) {
  2457. this.$message.error('HDF模式下置换液和置换液总量不能为空!')
  2458. return
  2459. }
  2460. }
  2461. }
  2462. this.is_pre = 2
  2463. if (this.prescription.id == 0) {
  2464. if (this.is_open == 0) {
  2465. if (this.patient.id <= 0) {
  2466. this.$message.error('没有选择患者')
  2467. this.loading = false
  2468. return
  2469. }
  2470. var arr = this.dialysisPrescription
  2471. // console.log('arr', arr)
  2472. const ParamsQuery = arr
  2473. // console.log('长期处方1', ParamsQuery)
  2474. ParamsQuery['patient'] = this.patient.id
  2475. ParamsQuery['record_date'] = this.record_date
  2476. ParamsQuery['mode'] = '1'
  2477. postSoulution(ParamsQuery).then(response => {
  2478. if (response.data.state == 0) {
  2479. this.$message.error(response.data.msg)
  2480. return false
  2481. } else {
  2482. this.$notify({
  2483. title: '成功',
  2484. message: '提交成功',
  2485. type: 'success',
  2486. duration: 2000
  2487. })
  2488. const prescription_resp = response.data.data.prescription
  2489. const solution_resp = response.data.data.solution
  2490. var prescription = this.prescription
  2491. var solution = this.solution
  2492. for (var index in prescription_resp) {
  2493. // prescription[index] = prescription_resp[index];
  2494. this.$set(prescription, index, prescription_resp[index])
  2495. }
  2496. for (var index in solution_resp) {
  2497. // solution[index] = solution_resp[index];
  2498. this.$set(solution, index, solution_resp[index])
  2499. }
  2500. this.hide()
  2501. }
  2502. })
  2503. } else if (this.is_open == 1) {
  2504. if (this.targetAdvices.length > 0) {
  2505. // 弹框推送提
  2506. this.isShowRemindAdvice = true
  2507. this.isVisibility = false
  2508. } else {
  2509. if (this.patient.id <= 0) {
  2510. this.$message.error('没有选择患者')
  2511. this.loading = false
  2512. return
  2513. }
  2514. var arr = this.dialysisPrescription
  2515. // console.log('arr', arr)
  2516. const ParamsQuery = arr
  2517. // console.log('长期处方2', ParamsQuery)
  2518. ParamsQuery['patient'] = this.patient.id
  2519. ParamsQuery['record_date'] = this.record_date
  2520. ParamsQuery['mode'] = '1'
  2521. postSoulution(ParamsQuery).then(response => {
  2522. if (response.data.state == 0) {
  2523. this.$message.error(response.data.msg)
  2524. return false
  2525. } else {
  2526. this.$notify({
  2527. title: '成功',
  2528. message: '提交成功',
  2529. type: 'success',
  2530. duration: 2000
  2531. })
  2532. const prescription_resp = response.data.data.prescription
  2533. const solution_resp = response.data.data.solution
  2534. var prescription = this.prescription
  2535. var solution = this.solution
  2536. for (var index in prescription_resp) {
  2537. // prescription[index] = prescription_resp[index];
  2538. this.$set(prescription, index, prescription_resp[index])
  2539. }
  2540. for (var index in solution_resp) {
  2541. // solution[index] = solution_resp[index];
  2542. this.$set(solution, index, solution_resp[index])
  2543. }
  2544. this.hide()
  2545. }
  2546. })
  2547. }
  2548. } else if (this.is_open == 2) {
  2549. var date = new Date()
  2550. var hour =
  2551. date.getHours() < 10 ? '0' + date.getHours() : date.getHours()
  2552. var minute =
  2553. date.getMinutes() < 10
  2554. ? '0' + date.getMinutes()
  2555. : date.getMinutes()
  2556. if (this.waitUploadAdvices.length > 0) {
  2557. if (this.patient.id <= 0) {
  2558. this.$message.error('没有选择患者')
  2559. this.loading = false
  2560. return
  2561. }
  2562. var arr = this.dialysisPrescription
  2563. // console.log('arr', arr)
  2564. const ParamsQuery = arr
  2565. // console.log('长期处方3', ParamsQuery)
  2566. ParamsQuery['patient'] = this.patient.id
  2567. ParamsQuery['record_date'] = this.record_date
  2568. // console.log(this.prescription)
  2569. ParamsQuery['mode'] = '1'
  2570. postPrescription(ParamsQuery).then(response => {
  2571. if (response.data.state == 0) {
  2572. this.$message.error(response.data.msg)
  2573. return false
  2574. } else {
  2575. this.$notify({
  2576. title: '成功',
  2577. message: '提交成功',
  2578. type: 'success',
  2579. duration: 2000
  2580. })
  2581. const params = {
  2582. advices: this.waitUploadAdvices,
  2583. advice_date: uParseTime(
  2584. this.$route.query.date,
  2585. '{y}-{m}-{d}'
  2586. ),
  2587. advice_doctor: this.waitUploadAdvices[0].advice_doctor,
  2588. advice_type: this.waitUploadAdvices[0].advice_type,
  2589. parent_id: this.patient_id,
  2590. // start_time: uParseTime(this.$route.query.date, '{y}-{m}-{d}'),
  2591. start_time:
  2592. uParseTime(this.$route.query.date, '{y}-{m}-{d}') +
  2593. ' ' +
  2594. hour +
  2595. ':' +
  2596. minute,
  2597. remark: ''
  2598. }
  2599. CreateGroupAdvice(this.$route.query.patient_id, 0, params).then(
  2600. rs => {
  2601. var resp = rs.data
  2602. if (resp.state == 1) {
  2603. // this.doctorAdvices = resp.data.advices
  2604. this.$emit('advice')
  2605. } else {
  2606. }
  2607. }
  2608. )
  2609. const prescription_resp = response.data.data.prescription
  2610. var prescription = this.prescription
  2611. for (var index in prescription_resp) {
  2612. // prescription[index] = prescription_resp[index];
  2613. this.$set(prescription, index, prescription_resp[index])
  2614. }
  2615. this.hide()
  2616. }
  2617. })
  2618. } else {
  2619. if (this.patient.id <= 0) {
  2620. this.$message.error('没有选择患者')
  2621. this.loading = false
  2622. return
  2623. }
  2624. var arr = this.dialysisPrescription
  2625. // console.log('arr', arr)
  2626. const ParamsQuery = arr
  2627. // console.log('长期处方5', ParamsQuery)
  2628. ParamsQuery['patient'] = this.patient.id
  2629. ParamsQuery['record_date'] = this.record_date
  2630. ParamsQuery['mode'] = '1'
  2631. postSoulution(ParamsQuery).then(response => {
  2632. if (response.data.state == 0) {
  2633. this.$message.error(response.data.msg)
  2634. return false
  2635. } else {
  2636. this.$notify({
  2637. title: '成功',
  2638. message: '提交成功',
  2639. type: 'success',
  2640. duration: 2000
  2641. })
  2642. const prescription_resp = response.data.data.prescription
  2643. const solution_resp = response.data.data.solution
  2644. var prescription = this.prescription
  2645. var solution = this.solution
  2646. for (var index in prescription_resp) {
  2647. // prescription[index] = prescription_resp[index];
  2648. this.$set(prescription, index, prescription_resp[index])
  2649. }
  2650. for (var index in solution_resp) {
  2651. // solution[index] = solution_resp[index];
  2652. this.$set(solution, index, solution_resp[index])
  2653. }
  2654. this.hide()
  2655. }
  2656. })
  2657. }
  2658. }
  2659. } else {
  2660. if (this.prescription.creater == 0) {
  2661. if (this.is_open == 0) {
  2662. if (this.patient.id <= 0) {
  2663. this.$message.error('没有选择患者')
  2664. this.loading = false
  2665. return
  2666. }
  2667. var arr = this.dialysisPrescription
  2668. // console.log('arr', arr)
  2669. const ParamsQuery = arr
  2670. // console.log('长期处方6', ParamsQuery)
  2671. ParamsQuery['patient'] = this.patient.id
  2672. ParamsQuery['record_date'] = this.record_date
  2673. ParamsQuery['mode'] = '1'
  2674. postSoulution(ParamsQuery).then(response => {
  2675. if (response.data.state == 0) {
  2676. this.$message.error(response.data.msg)
  2677. return false
  2678. } else {
  2679. this.$notify({
  2680. title: '成功',
  2681. message: '提交成功',
  2682. type: 'success',
  2683. duration: 2000
  2684. })
  2685. const prescription_resp = response.data.data.prescription
  2686. const solution_resp = response.data.data.solution
  2687. var prescription = this.prescription
  2688. var solution = this.solution
  2689. for (var index in prescription_resp) {
  2690. // prescription[index] = prescription_resp[index];
  2691. this.$set(prescription, index, prescription_resp[index])
  2692. }
  2693. for (var index in solution_resp) {
  2694. // solution[index] = solution_resp[index];
  2695. this.$set(solution, index, solution_resp[index])
  2696. }
  2697. this.hide()
  2698. }
  2699. })
  2700. } else if (this.is_open == 1) {
  2701. if (this.targetAdvices.length > 0) {
  2702. // 弹框推送提醒
  2703. this.isShowRemindAdvice = true
  2704. this.isVisibility = false
  2705. } else {
  2706. if (this.patient.id <= 0) {
  2707. this.$message.error('没有选择患者')
  2708. this.loading = false
  2709. return
  2710. }
  2711. var arr = this.dialysisPrescription
  2712. // console.log('arr', arr)
  2713. const ParamsQuery = arr
  2714. // console.log('长期处方7', ParamsQuery)
  2715. ParamsQuery['patient'] = this.patient.id
  2716. ParamsQuery['record_date'] = this.record_date
  2717. ParamsQuery['mode'] = '1'
  2718. postSoulution(ParamsQuery).then(response => {
  2719. if (response.data.state == 0) {
  2720. this.$message.error(response.data.msg)
  2721. return false
  2722. } else {
  2723. this.$notify({
  2724. title: '成功',
  2725. message: '提交成功',
  2726. type: 'success',
  2727. duration: 2000
  2728. })
  2729. const prescription_resp = response.data.data.prescription
  2730. const solution_resp = response.data.data.solution
  2731. var prescription = this.prescription
  2732. var solution = this.solution
  2733. for (var index in prescription_resp) {
  2734. // prescription[index] = prescription_resp[index];
  2735. this.$set(prescription, index, prescription_resp[index])
  2736. }
  2737. for (var index in solution_resp) {
  2738. // solution[index] = solution_resp[index];
  2739. this.$set(solution, index, solution_resp[index])
  2740. }
  2741. this.hide()
  2742. }
  2743. })
  2744. }
  2745. } else if (this.is_open == 2) {
  2746. var date = new Date()
  2747. var hour =
  2748. date.getHours() < 10 ? '0' + date.getHours() : date.getHours()
  2749. var minute =
  2750. date.getMinutes() < 10
  2751. ? '0' + date.getMinutes()
  2752. : date.getMinutes()
  2753. if (this.waitUploadAdvices.length > 0) {
  2754. if (this.patient.id <= 0) {
  2755. this.$message.error('没有选择患者')
  2756. this.loading = false
  2757. return
  2758. }
  2759. var arr = this.dialysisPrescription
  2760. // console.log('arr', arr)
  2761. const ParamsQuery = arr
  2762. // console.log('长期处方8', ParamsQuery)
  2763. ParamsQuery['patient'] = this.patient.id
  2764. ParamsQuery['record_date'] = this.record_date
  2765. ParamsQuery['mode'] = '1'
  2766. postSoulution(ParamsQuery).then(response => {
  2767. if (response.data.state == 0) {
  2768. this.$message.error(response.data.msg)
  2769. return false
  2770. } else {
  2771. this.$notify({
  2772. title: '成功',
  2773. message: '提交成功',
  2774. type: 'success',
  2775. duration: 2000
  2776. })
  2777. const params = {
  2778. advices: this.waitUploadAdvices,
  2779. advice_date: uParseTime(
  2780. this.$route.query.date,
  2781. '{y}-{m}-{d}'
  2782. ),
  2783. advice_doctor: this.waitUploadAdvices[0].advice_doctor,
  2784. advice_type: this.waitUploadAdvices[0].advice_type,
  2785. parent_id: this.patient_id,
  2786. // start_time: uParseTime(this.$route.query.date, '{y}-{m}-{d} {h}{i}'),
  2787. start_time:
  2788. uParseTime(this.$route.query.date, '{y}-{m}-{d}') +
  2789. ' ' +
  2790. hour +
  2791. ':' +
  2792. minute,
  2793. remark: ''
  2794. }
  2795. CreateGroupAdvice(
  2796. this.$route.query.patient_id,
  2797. 0,
  2798. params
  2799. ).then(rs => {
  2800. var resp = rs.data
  2801. if (resp.state == 1) {
  2802. // this.doctorAdvices = resp.data.advices
  2803. this.$emit('advice')
  2804. } else {
  2805. }
  2806. })
  2807. const prescription_resp = response.data.data.prescription
  2808. const solution_resp = response.data.data.solution
  2809. var prescription = this.prescription
  2810. var solution = this.solution
  2811. for (var index in prescription_resp) {
  2812. // prescription[index] = prescription_resp[index];
  2813. this.$set(prescription, index, prescription_resp[index])
  2814. }
  2815. for (var index in solution_resp) {
  2816. // solution[index] = solution_resp[index];
  2817. this.$set(solution, index, solution_resp[index])
  2818. }
  2819. this.hide()
  2820. }
  2821. })
  2822. } else {
  2823. if (this.patient.id <= 0) {
  2824. this.$message.error('没有选择患者')
  2825. this.loading = false
  2826. return
  2827. }
  2828. var arr = this.dialysisPrescription
  2829. // console.log('arr', arr)
  2830. const ParamsQuery = arr
  2831. // console.log('长期处方9', ParamsQuery)
  2832. ParamsQuery['patient'] = this.patient.id
  2833. ParamsQuery['record_date'] = this.record_date
  2834. ParamsQuery['mode'] = '1'
  2835. postSoulution(ParamsQuery).then(response => {
  2836. if (response.data.state == 0) {
  2837. this.$message.error(response.data.msg)
  2838. return false
  2839. } else {
  2840. this.$notify({
  2841. title: '成功',
  2842. message: '提交成功',
  2843. type: 'success',
  2844. duration: 2000
  2845. })
  2846. const prescription_resp = response.data.data.prescription
  2847. const solution_resp = response.data.data.solution
  2848. var prescription = this.prescription
  2849. var solution = this.solution
  2850. for (var index in prescription_resp) {
  2851. // prescription[index] = prescription_resp[index];
  2852. this.$set(prescription, index, prescription_resp[index])
  2853. }
  2854. for (var index in solution_resp) {
  2855. // solution[index] = solution_resp[index];
  2856. this.$set(solution, index, solution_resp[index])
  2857. }
  2858. this.hide()
  2859. }
  2860. })
  2861. }
  2862. }
  2863. } else {
  2864. if (this.patient.id <= 0) {
  2865. this.$message.error('没有选择患者')
  2866. this.loading = false
  2867. return
  2868. }
  2869. var arr = this.dialysisPrescription
  2870. // console.log('arr', arr)
  2871. const ParamsQuery = arr
  2872. // console.log('长期处方10', ParamsQuery)
  2873. ParamsQuery['patient'] = this.patient.id
  2874. ParamsQuery['record_date'] = this.record_date
  2875. ParamsQuery['mode'] = '1'
  2876. postSoulution(ParamsQuery).then(response => {
  2877. if (response.data.state == 0) {
  2878. this.$message.error(response.data.msg)
  2879. return false
  2880. } else {
  2881. this.$notify({
  2882. title: '成功',
  2883. message: '提交成功',
  2884. type: 'success',
  2885. duration: 2000
  2886. })
  2887. const prescription_resp = response.data.data.prescription
  2888. const solution_resp = response.data.data.solution
  2889. var prescription = this.prescription
  2890. var solution = this.solution
  2891. for (var index in prescription_resp) {
  2892. // prescription[index] = prescription_resp[index];
  2893. this.$set(prescription, index, prescription_resp[index])
  2894. }
  2895. for (var index in solution_resp) {
  2896. // solution[index] = solution_resp[index];
  2897. this.$set(solution, index, solution_resp[index])
  2898. }
  2899. this.hide()
  2900. }
  2901. })
  2902. }
  2903. }
  2904. },
  2905. isShows(name) {
  2906. var filedList = store.getters.xt_user.fileds
  2907. for (let i = 0; i < filedList.length; i++) {
  2908. if (
  2909. filedList[i].module == 1 &&
  2910. filedList[i].filed_name_cn == name &&
  2911. filedList[i].is_show == 1
  2912. ) {
  2913. return true
  2914. }
  2915. }
  2916. return false
  2917. },
  2918. getDoctorName(doctor_id) {
  2919. for (let i = 0; i < this.admin_users.length; i++) {
  2920. if (this.admin_users[i].id == doctor_id) {
  2921. return this.admin_users[i].name
  2922. }
  2923. }
  2924. },
  2925. getContent(val) {
  2926. let prescribing_number = ''
  2927. let single_dose = ''
  2928. let advice_desc = ''
  2929. if (val.prescribing_number > 0) {
  2930. prescribing_number =
  2931. val.prescribing_number + val.prescribing_number_unit
  2932. }
  2933. if (val.single_dose > 0) {
  2934. single_dose = ' 单次用量 ' + val.single_dose + val.single_dose_unit
  2935. }
  2936. if (val.advice_desc > 0 || val.advice_desc.length > 0) {
  2937. advice_desc = val.advice_desc + val.drug_spec_unit
  2938. }
  2939. let name = ''
  2940. if (val.child.length > 0) {
  2941. for (let i = 0; i < val.child.length; i++) {
  2942. if (val.child[i].prescribing_number > 0) {
  2943. val.child[i]['presc'] =
  2944. val.child[i].prescribing_number +
  2945. val.child[i].prescribing_number_unit
  2946. } else {
  2947. val.child[i]['presc'] = ''
  2948. }
  2949. if (val.child[i].single_dose > 0) {
  2950. val.child[i]['single'] =
  2951. ' ' +
  2952. ' 单次用量 ' +
  2953. ' ' +
  2954. val.child[i].single_dose +
  2955. val.child[i].single_dose_unit
  2956. } else {
  2957. val.child[i]['single'] = ''
  2958. }
  2959. name =
  2960. name +
  2961. '▲' +
  2962. val.child[i].advice_name +
  2963. '' +
  2964. val.child[i].advice_desc +
  2965. val.child[i].drug_spec_unit +
  2966. val.child[i].presc +
  2967. val.child[i].single
  2968. }
  2969. return (
  2970. val.advice_name +
  2971. ' ' +
  2972. advice_desc +
  2973. ' ' +
  2974. val.drug_spec_unit +
  2975. prescribing_number +
  2976. ' ' +
  2977. single_dose +
  2978. ' ' +
  2979. ' ' +
  2980. val.delivery_way +
  2981. ' ' +
  2982. val.execution_frequency +
  2983. val.remark +
  2984. name
  2985. )
  2986. } else {
  2987. return (
  2988. val.advice_name +
  2989. ' ' +
  2990. advice_desc +
  2991. prescribing_number +
  2992. ' ' +
  2993. single_dose +
  2994. ' ' +
  2995. ' ' +
  2996. val.delivery_way +
  2997. ' ' +
  2998. val.execution_frequency +
  2999. val.remark
  3000. )
  3001. }
  3002. },
  3003. changePrescription(id) {
  3004. const ParamsQuery = {}
  3005. ParamsQuery['patient_id'] = this.$route.query.patient_id
  3006. ParamsQuery['mode_id'] = id
  3007. GetSolution(ParamsQuery).then(response => {
  3008. if (response.data.state == 0) {
  3009. this.$message.error(response.data.msg)
  3010. return false
  3011. } else {
  3012. console.log('切换数据', response.data.data.solution)
  3013. this.$message.success('切换成功')
  3014. if (response.data.data.solution != null) {
  3015. for (const key in response.data.data.solution) {
  3016. // 长期处方不为空
  3017. if (key != 'target_ultrafiltration' && key != 'niprocart' && key != 'target_ultrafiltration' && key != 'jms' && key != 'fistula_needle_set' && key != 'fistula_needle_set_16'
  3018. && key != 'hemoperfusion' && key != 'dialyser_sterilised' && key != 'filtryzer' && key != 'target_ktv' && key != 'dialyzers'
  3019. && key != 'injector' && key != 'bloodlines' && key != 'tubing_hemodialysis' && key != 'package' && key != 'a_liquid') {
  3020. this.dialysisPrescription[key] =
  3021. response.data.data.solution[key]
  3022. }
  3023. }
  3024. } else {
  3025. if (response.data.data.prescription != null) {
  3026. // 临时处方不为空
  3027. for (const key in response.data.data.prescription) {
  3028. if (key != 'target_ultrafiltration' && key != 'niprocart' && key != 'target_ultrafiltration' && key != 'jms' && key != 'fistula_needle_set' && key != 'fistula_needle_set_16'
  3029. && key != 'hemoperfusion' && key != 'dialyser_sterilised' && key != 'filtryzer' && key != 'target_ktv' && key != 'dialyzers'
  3030. && key != 'injector' && key != 'bloodlines' && key != 'tubing_hemodialysis' && key != 'package' && key != 'a_liquid') {
  3031. this.dialysisPrescription[key] =
  3032. response.data.data.prescription[key]
  3033. }
  3034. }
  3035. } else if (response.data.data.system_prescription != null) {
  3036. // 系统处方不为空
  3037. for (const key in response.data.data.system_prescription) {
  3038. if (key != 'target_ultrafiltration' && key != 'niprocart' && key != 'target_ultrafiltration' && key != 'jms' && key != 'fistula_needle_set' && key != 'fistula_needle_set_16'
  3039. && key != 'hemoperfusion' && key != 'dialyser_sterilised' && key != 'filtryzer' && key != 'target_ktv' && key != 'dialyzers'
  3040. && key != 'injector' && key != 'bloodlines' && key != 'tubing_hemodialysis' && key != 'package' && key != 'a_liquid') {
  3041. this.dialysisPrescription[key] =
  3042. response.data.data.system_prescription[key]
  3043. }
  3044. }
  3045. } else {
  3046. for (const key in this.dialysisPrescription) {
  3047. // 临时处方为空
  3048. if (key != 'target_ultrafiltration' && key != 'niprocart' && key != 'target_ultrafiltration' && key != 'jms' && key != 'fistula_needle_set' && key != 'fistula_needle_set_16'
  3049. && key != 'hemoperfusion' && key != 'dialyser_sterilised' && key != 'filtryzer' && key != 'target_ktv' && key != 'dialyzers'
  3050. && key != 'injector' && key != 'bloodlines' && key != 'tubing_hemodialysis' && key != 'package' && key != 'a_liquid') {
  3051. this.dialysisPrescription[key] = ''
  3052. }
  3053. }
  3054. this.dialysisPrescription.mode_id = id
  3055. }
  3056. }
  3057. }
  3058. if (
  3059. this.dialysisPrescription.dialysis_duration_hour === '' ||
  3060. this.dialysisPrescription.dialysis_duration_minute === ''
  3061. ) {
  3062. this.timeValue = ''
  3063. this.time = '03:00'
  3064. } else {
  3065. this.timeValue =
  3066. this.dialysisPrescription.dialysis_duration_hour +
  3067. '小时' +
  3068. this.dialysisPrescription.dialysis_duration_minute +
  3069. '分钟'
  3070. this.time =
  3071. (this.dialysisPrescription.dialysis_duration_hour > 10
  3072. ? this.dialysisPrescription.dialysis_duration_hour
  3073. : '0' + this.dialysisPrescription.dialysis_duration_hour) +
  3074. ':' +
  3075. (this.dialysisPrescription.dialysis_duration_minute > 10
  3076. ? this.dialysisPrescription.dialysis_duration_minute
  3077. : '0' + this.dialysisPrescription.dialysis_duration_minute)
  3078. }
  3079. })
  3080. if (
  3081. id === 1 ||
  3082. id === 3 ||
  3083. id === 4 ||
  3084. id === 6 ||
  3085. id === 7 ||
  3086. id === 8 ||
  3087. id === 9 ||
  3088. id === 10 ||
  3089. id === 11 ||
  3090. id === 13 ||
  3091. id === 14 ||
  3092. id === 15 ||
  3093. id === 16 ||
  3094. id === 19
  3095. ) {
  3096. this.zhiShow = false
  3097. this.huShow = false
  3098. this.totalShow = false
  3099. } else {
  3100. this.zhiShow = true
  3101. this.huShow = true
  3102. this.totalShow = true
  3103. }
  3104. },
  3105. handlePatientInfo() {
  3106. this.isVisibility = false
  3107. this.msgtip_visibility = true
  3108. },
  3109. cancleMsg() {
  3110. this.isVisibility = true
  3111. this.msgtip_visibility = false
  3112. },
  3113. getPermission() {
  3114. request
  3115. .get('/api/func_per/get', {
  3116. params: {
  3117. create_url: '/api/dialysis/prescription?mode=1',
  3118. modify_url: '/api/dialysis/prescription?mode=2',
  3119. modify_other_url: '/api/dialysis/prescription?mode=3',
  3120. module: 1
  3121. }
  3122. })
  3123. .then(res => {
  3124. // console.log(res)
  3125. // console.log('predialysis.creater', this.pre.creater)
  3126. // console.log('admin.id', this.$store.getters.xt_user.user.id)
  3127. if (res.data.state == 0) {
  3128. this.hasPermission = false
  3129. } else if (res.data.state == 1) {
  3130. if (this.pre.id != '' && this.pre.creater != 0) {
  3131. // 有数据
  3132. if (this.pre.creater == this.$store.getters.xt_user.user.id) {
  3133. // 创建人是自己
  3134. if (res.data.data.is_has_modify == false) {
  3135. this.hasPermission = false
  3136. this.showTxt = '你没有修改透析处方权限'
  3137. }
  3138. } else {
  3139. // 创建人不是自己
  3140. if (res.data.data.is_has_modify_other == false) {
  3141. this.hasPermission = false
  3142. this.showTxt = '你没有修改他人透析处方权限'
  3143. }
  3144. }
  3145. } else if (this.pre.id == '' || this.pre.creater == 0) {
  3146. if (res.data.data.is_has_create == false) {
  3147. this.hasPermission = false
  3148. this.showTxt = '你没有新增透析处方权限'
  3149. }
  3150. }
  3151. }
  3152. })
  3153. },
  3154. unique(arr) {
  3155. const res = new Map()
  3156. return arr.filter((arr) => !res.has(arr.name) && res.set(arr.name, 1))
  3157. }
  3158. },
  3159. watch: {
  3160. 'dialysisPrescription.dialysis_duration_hour': function() {
  3161. let dialysis_duration_minute = 0
  3162. let dialysis_duration_hour = 0
  3163. let duration = 0
  3164. if (this.dialysisPrescription.dialysis_duration_minute == '') {
  3165. dialysis_duration_minute = 0
  3166. } else {
  3167. dialysis_duration_minute = this.dialysisPrescription
  3168. .dialysis_duration_minute
  3169. }
  3170. if (this.dialysisPrescription.dialysis_duration_hour == '') {
  3171. dialysis_duration_hour = 0
  3172. } else {
  3173. dialysis_duration_hour = this.dialysisPrescription
  3174. .dialysis_duration_hour
  3175. }
  3176. duration = parseFloat(dialysis_duration_hour) + parseFloat(dialysis_duration_minute) / 60
  3177. this.dialysisPrescription.anticoagulant_zongliang = calculateAnticoagulantZL(1, this.dialysisPrescription.anticoagulant_shouji, duration, this.dialysisPrescription.anticoagulant_weichi)
  3178. if (isNaN(this.dialysisPrescription.anticoagulant_zongliang)) {
  3179. this.dialysisPrescription.anticoagulant_zongliang = ''
  3180. }
  3181. },
  3182. 'dialysisPrescription.dialysis_duration_minute': function() {
  3183. let dialysis_duration_minute = 0
  3184. let dialysis_duration_hour = 0
  3185. let duration = 0
  3186. if (this.dialysisPrescription.dialysis_duration_minute == '') {
  3187. dialysis_duration_minute = 0
  3188. } else {
  3189. dialysis_duration_minute = this.dialysisPrescription.dialysis_duration_minute
  3190. }
  3191. if (this.dialysisPrescription.dialysis_duration_hour == '') {
  3192. dialysis_duration_hour = 0
  3193. } else {
  3194. dialysis_duration_hour = this.dialysisPrescription
  3195. .dialysis_duration_hour
  3196. }
  3197. duration =
  3198. parseFloat(dialysis_duration_hour) +
  3199. parseFloat(dialysis_duration_minute) / 60
  3200. this.dialysisPrescription.anticoagulant_zongliang = calculateAnticoagulantZL(1, this.dialysisPrescription.anticoagulant_shouji, duration,
  3201. this.dialysisPrescription.anticoagulant_weichi
  3202. )
  3203. if (isNaN(this.dialysisPrescription.anticoagulant_zongliang)) {
  3204. this.dialysisPrescription.anticoagulant_zongliang = ''
  3205. }
  3206. },
  3207. 'dialysisPrescription.anticoagulant_shouji': function() {
  3208. let dialysis_duration_minute = 0
  3209. let dialysis_duration_hour = 0
  3210. let duration = 0
  3211. if (this.dialysisPrescription.dialysis_duration_minute == '') {
  3212. dialysis_duration_minute = 0
  3213. } else {
  3214. dialysis_duration_minute = this.dialysisPrescription
  3215. .dialysis_duration_minute
  3216. }
  3217. if (this.dialysisPrescription.dialysis_duration_hour == '') {
  3218. dialysis_duration_hour = 0
  3219. } else {
  3220. dialysis_duration_hour = this.dialysisPrescription
  3221. .dialysis_duration_hour
  3222. }
  3223. duration =
  3224. parseFloat(dialysis_duration_hour) +
  3225. parseFloat(dialysis_duration_minute) / 60
  3226. this.dialysisPrescription.anticoagulant_zongliang = calculateAnticoagulantZL(
  3227. 1,
  3228. this.dialysisPrescription.anticoagulant_shouji,
  3229. duration,
  3230. this.dialysisPrescription.anticoagulant_weichi
  3231. )
  3232. if (isNaN(this.dialysisPrescription.anticoagulant_zongliang)) {
  3233. this.dialysisPrescription.anticoagulant_zongliang = ''
  3234. }
  3235. if(this.$store.getters.xt_user.template_info.template_id == 41 && this.dialysisPrescription.anticoagulant == 2){
  3236. this.dialysisPrescription.anticoagulant_zongliang = ""
  3237. this.dialysisPrescription.anticoagulant_zongliang = parseInt(this.dialysisPrescription.anticoagulant_shouji) + parseInt(this.dialysisPrescription.anticoagulant_weichi)
  3238. }
  3239. },
  3240. 'dialysisPrescription.anticoagulant_weichi': function() {
  3241. let dialysis_duration_minute = 0
  3242. let dialysis_duration_hour = 0
  3243. let duration = 0
  3244. if (this.dialysisPrescription.dialysis_duration_minute == '') {
  3245. dialysis_duration_minute = 0
  3246. } else {
  3247. dialysis_duration_minute = this.dialysisPrescription
  3248. .dialysis_duration_minute
  3249. }
  3250. if (this.dialysisPrescription.dialysis_duration_hour == '') {
  3251. dialysis_duration_hour = 0
  3252. } else {
  3253. dialysis_duration_hour = this.dialysisPrescription
  3254. .dialysis_duration_hour
  3255. }
  3256. duration = parseFloat(dialysis_duration_hour) + parseFloat(dialysis_duration_minute) / 60
  3257. this.dialysisPrescription.anticoagulant_zongliang = calculateAnticoagulantZL(1, this.dialysisPrescription.anticoagulant_shouji, duration, this.dialysisPrescription.anticoagulant_weichi)
  3258. if (isNaN(this.dialysisPrescription.anticoagulant_zongliang)) {
  3259. this.dialysisPrescription.anticoagulant_zongliang = ''
  3260. }
  3261. console.log('首季9999', this.dialysisPrescription.anticoagulant_zongliang)
  3262. console.log("收集",this.dialysisPrescription.anticoagulant_shouji)
  3263. console.log("weichi",this.dialysisPrescription.anticoagulant_weichi)
  3264. if(this.$store.getters.xt_user.template_info.template_id == 41 && this.dialysisPrescription.anticoagulant == 2){
  3265. this.dialysisPrescription.anticoagulant_zongliang = ""
  3266. this.dialysisPrescription.anticoagulant_zongliang = parseInt(this.dialysisPrescription.anticoagulant_shouji) + parseInt(this.dialysisPrescription.anticoagulant_weichi)
  3267. }
  3268. },
  3269. 'prescription.id': {
  3270. immediate: true,
  3271. deep: true,
  3272. handler(oldVal, newVal) {
  3273. if (oldVal == newVal) {
  3274. for (var index in this.dialysisPrescription) {
  3275. this.dialysisPrescription[index] = this.prescription[index]
  3276. }
  3277. if (this.prescription['dialysate_formulation'] == 0) {
  3278. this.dialysisPrescription['dialysate_formulation'] = ''
  3279. }
  3280. if (this.prescription['anticoagulant'] == 0) {
  3281. this.dialysisPrescription['anticoagulant'] = ''
  3282. }
  3283. if (this.prescription['dialysis_duration_hour'] == 0) {
  3284. this.dialysisPrescription['dialysis_duration_hour'] = ''
  3285. }
  3286. if (this.prescription['dialysis_duration_minute'] == 0) {
  3287. this.dialysisPrescription['dialysis_duration_minute'] = ''
  3288. }
  3289. if (this.prescription['blood_flow_volume'] == 0) {
  3290. this.dialysisPrescription['blood_flow_volume'] = ''
  3291. }
  3292. if (this.prescription['target_ultrafiltration'] == 0) {
  3293. this.dialysisPrescription['target_ultrafiltration'] = ''
  3294. }
  3295. if (this.prescription['dialysate_temperature'] == 0) {
  3296. this.dialysisPrescription['dialysate_temperature'] = ''
  3297. }
  3298. if (this.prescription['anticoagulant_shouji'] == 0) {
  3299. this.dialysisPrescription['anticoagulant_shouji'] = 0
  3300. }
  3301. if (this.prescription['anticoagulant_weichi'] == 0) {
  3302. this.dialysisPrescription['anticoagulant_weichi'] = 0
  3303. }
  3304. if (this.prescription['anticoagulant_zongliang'] == 0) {
  3305. this.dialysisPrescription['anticoagulant_zongliang'] = 0
  3306. }
  3307. if (this.prescription['anticoagulant_gaijiliang'] == 0) {
  3308. this.dialysisPrescription['anticoagulant_gaijiliang'] = ''
  3309. }
  3310. if (this.prescription['kalium'] == 0) {
  3311. this.dialysisPrescription['kalium'] = ''
  3312. }
  3313. if (this.prescription['sodium'] == 0) {
  3314. this.dialysisPrescription['sodium'] = ''
  3315. }
  3316. if (this.prescription['calcium'] == 0) {
  3317. this.dialysisPrescription['calcium'] = ''
  3318. }
  3319. if (this.prescription['bicarbonate'] == 0) {
  3320. this.dialysisPrescription['bicarbonate'] = ''
  3321. }
  3322. if (this.prescription['glucose'] == 0) {
  3323. this.dialysisPrescription['glucose'] = ''
  3324. }
  3325. if (this.prescription['dialysate_flow'] == 0) {
  3326. this.dialysisPrescription['dialysate_flow'] = ''
  3327. }
  3328. if (this.prescription['conductivity'] == 0) {
  3329. this.dialysisPrescription['conductivity'] = ''
  3330. }
  3331. if (this.prescription['replacement_total'] == 0) {
  3332. this.dialysisPrescription['replacement_total'] = ''
  3333. }
  3334. if (this.prescription['target_ktv'] == 0) {
  3335. this.dialysisPrescription['target_ktv'] = ''
  3336. }
  3337. }
  3338. if (this.prescription.id > 0) {
  3339. for (var index in this.dialysisPrescription) {
  3340. this.dialysisPrescription[index] = this.prescription[index]
  3341. }
  3342. if (this.prescription['dialysate_formulation'] == 0) {
  3343. this.dialysisPrescription['dialysate_formulation'] = ''
  3344. }
  3345. if (this.prescription['anticoagulant'] == 0) {
  3346. this.dialysisPrescription['anticoagulant'] = ''
  3347. }
  3348. if (this.prescription['dialysis_duration_hour'] == 0) {
  3349. this.dialysisPrescription['dialysis_duration_hour'] = ''
  3350. }
  3351. if (this.prescription['dialysis_duration_minute'] == 0) {
  3352. this.dialysisPrescription['dialysis_duration_minute'] = ''
  3353. }
  3354. if (this.prescription['blood_flow_volume'] == 0) {
  3355. this.dialysisPrescription['blood_flow_volume'] = ''
  3356. }
  3357. if (this.prescription['target_ultrafiltration'] == 0) {
  3358. this.dialysisPrescription['target_ultrafiltration'] = ''
  3359. }
  3360. if (this.prescription['dialysate_temperature'] == 0) {
  3361. this.dialysisPrescription['dialysate_temperature'] = ''
  3362. }
  3363. if (this.prescription['anticoagulant_shouji'] == 0) {
  3364. this.dialysisPrescription['anticoagulant_shouji'] = 0
  3365. }
  3366. if (this.prescription['anticoagulant_weichi'] == 0) {
  3367. this.dialysisPrescription['anticoagulant_weichi'] = 0
  3368. }
  3369. if (this.prescription['anticoagulant_zongliang'] == 0) {
  3370. this.dialysisPrescription['anticoagulant_zongliang'] = 0
  3371. }
  3372. if (this.prescription['anticoagulant_gaijiliang'] == 0) {
  3373. this.dialysisPrescription['anticoagulant_gaijiliang'] = ''
  3374. }
  3375. if (this.prescription['kalium'] == 0) {
  3376. this.dialysisPrescription['kalium'] = ''
  3377. }
  3378. if (this.prescription['sodium'] == 0) {
  3379. this.dialysisPrescription['sodium'] = ''
  3380. }
  3381. if (this.prescription['calcium'] == 0) {
  3382. this.dialysisPrescription['calcium'] = ''
  3383. }
  3384. if (this.prescription['bicarbonate'] == 0) {
  3385. this.dialysisPrescription['bicarbonate'] = ''
  3386. }
  3387. if (this.prescription['glucose'] == 0) {
  3388. this.dialysisPrescription['glucose'] = ''
  3389. }
  3390. if (this.prescription['dialysate_flow'] == 0) {
  3391. this.dialysisPrescription['dialysate_flow'] = ''
  3392. }
  3393. if (this.prescription['conductivity'] == 0) {
  3394. this.dialysisPrescription['conductivity'] = ''
  3395. }
  3396. if (this.prescription['replacement_total'] == 0) {
  3397. this.dialysisPrescription['replacement_total'] = ''
  3398. }
  3399. if (this.prescription['target_ktv'] == 0) {
  3400. this.dialysisPrescription['target_ktv'] = ''
  3401. }
  3402. } else if (this.prescription.id == 0) {
  3403. for (var index in this.dialysisPrescription) {
  3404. this.dialysisPrescription[index] = this.prescription[index]
  3405. }
  3406. if (this.prescription['dialysate_formulation'] == 0) {
  3407. this.dialysisPrescription['dialysate_formulation'] = ''
  3408. }
  3409. if (this.prescription['anticoagulant'] == 0) {
  3410. this.dialysisPrescription['anticoagulant'] = ''
  3411. }
  3412. if (this.prescription['dialysis_duration_hour'] == 0) {
  3413. this.dialysisPrescription['dialysis_duration_hour'] = ''
  3414. }
  3415. if (this.prescription['dialysis_duration_minute'] == 0) {
  3416. this.dialysisPrescription['dialysis_duration_minute'] = ''
  3417. }
  3418. if (this.prescription['blood_flow_volume'] == 0) {
  3419. this.dialysisPrescription['blood_flow_volume'] = ''
  3420. }
  3421. if (this.prescription['target_ultrafiltration'] == 0) {
  3422. this.dialysisPrescription['target_ultrafiltration'] = ''
  3423. }
  3424. if (this.prescription['dialysate_temperature'] == 0) {
  3425. this.dialysisPrescription['dialysate_temperature'] = ''
  3426. }
  3427. if (this.prescription['anticoagulant_shouji'] == 0) {
  3428. this.dialysisPrescription['anticoagulant_shouji'] = 0
  3429. }
  3430. if (this.prescription['anticoagulant_weichi'] == 0) {
  3431. this.dialysisPrescription['anticoagulant_weichi'] = 0
  3432. }
  3433. if (this.prescription['anticoagulant_zongliang'] == 0) {
  3434. this.dialysisPrescription['anticoagulant_zongliang'] = 0
  3435. }
  3436. if (this.prescription['anticoagulant_gaijiliang'] == 0) {
  3437. this.dialysisPrescription['anticoagulant_gaijiliang'] = ''
  3438. }
  3439. if (this.prescription['kalium'] == 0) {
  3440. this.dialysisPrescription['kalium'] = ''
  3441. }
  3442. if (this.prescription['sodium'] == 0) {
  3443. this.dialysisPrescription['sodium'] = ''
  3444. }
  3445. if (this.prescription['calcium'] == 0) {
  3446. this.dialysisPrescription['calcium'] = ''
  3447. }
  3448. if (this.prescription['bicarbonate'] == 0) {
  3449. this.dialysisPrescription['bicarbonate'] = ''
  3450. }
  3451. if (this.prescription['glucose'] == 0) {
  3452. this.dialysisPrescription['glucose'] = ''
  3453. }
  3454. if (this.prescription['dialysate_flow'] == 0) {
  3455. this.dialysisPrescription['dialysate_flow'] = ''
  3456. }
  3457. if (this.prescription['conductivity'] == 0) {
  3458. this.dialysisPrescription['conductivity'] = ''
  3459. }
  3460. if (this.prescription['replacement_total'] == 0) {
  3461. this.dialysisPrescription['replacement_total'] = ''
  3462. }
  3463. if (this.prescription['target_ktv'] == 0) {
  3464. this.dialysisPrescription['target_ktv'] = ''
  3465. }
  3466. }
  3467. }
  3468. },
  3469. 'solution.id': function() {
  3470. if (this.solution.id > 0) {
  3471. if (
  3472. this.prescription != null &&
  3473. typeof this.prescription.id !== 'undefined' &&
  3474. this.prescription.id > 0
  3475. ) {
  3476. for (const key in this.prescription) {
  3477. this.dialysisPrescription[key] = this.prescription[key]
  3478. }
  3479. if (this.prescription['dialysate_formulation'] == 0) {
  3480. this.dialysisPrescription['dialysate_formulation'] = ''
  3481. }
  3482. if (this.prescription['anticoagulant'] == 0) {
  3483. this.dialysisPrescription['anticoagulant'] = ''
  3484. }
  3485. if (this.prescription['dialysis_duration_hour'] == 0) {
  3486. this.dialysisPrescription['dialysis_duration_hour'] = ''
  3487. }
  3488. if (this.prescription['dialysis_duration_minute'] == 0) {
  3489. this.dialysisPrescription['dialysis_duration_minute'] = ''
  3490. }
  3491. if (this.prescription['blood_flow_volume'] == 0) {
  3492. this.dialysisPrescription['blood_flow_volume'] = ''
  3493. }
  3494. if (this.prescription['target_ultrafiltration'] == 0) {
  3495. this.dialysisPrescription['target_ultrafiltration'] = ''
  3496. }
  3497. if (this.prescription['dialysate_temperature'] == 0) {
  3498. this.dialysisPrescription['dialysate_temperature'] = ''
  3499. }
  3500. if (this.prescription['anticoagulant_shouji'] == 0) {
  3501. this.dialysisPrescription['anticoagulant_shouji'] = 0
  3502. }
  3503. if (this.prescription['anticoagulant_weichi'] == 0) {
  3504. this.dialysisPrescription['anticoagulant_weichi'] = 0
  3505. }
  3506. if (this.prescription['anticoagulant_zongliang'] == 0) {
  3507. this.dialysisPrescription['anticoagulant_zongliang'] = 0
  3508. }
  3509. if (this.prescription['anticoagulant_gaijiliang'] == 0) {
  3510. this.dialysisPrescription['anticoagulant_gaijiliang'] = ''
  3511. }
  3512. if (this.prescription['kalium'] == 0) {
  3513. this.dialysisPrescription['kalium'] = ''
  3514. }
  3515. if (this.prescription['sodium'] == 0) {
  3516. this.dialysisPrescription['sodium'] = ''
  3517. }
  3518. if (this.prescription['calcium'] == 0) {
  3519. this.dialysisPrescription['calcium'] = ''
  3520. }
  3521. if (this.prescription['bicarbonate'] == 0) {
  3522. this.dialysisPrescription['bicarbonate'] = ''
  3523. }
  3524. if (this.prescription['glucose'] == 0) {
  3525. this.dialysisPrescription['glucose'] = ''
  3526. }
  3527. if (this.prescription['dialysate_flow'] == 0) {
  3528. this.dialysisPrescription['dialysate_flow'] = ''
  3529. }
  3530. if (this.prescription['conductivity'] == 0) {
  3531. this.dialysisPrescription['conductivity'] = ''
  3532. }
  3533. if (this.prescription['replacement_total'] == 0) {
  3534. this.dialysisPrescription['replacement_total'] = ''
  3535. }
  3536. if (this.prescription['target_ktv'] == 0) {
  3537. this.dialysisPrescription['target_ktv'] = ''
  3538. }
  3539. } else if (
  3540. this.solution != null &&
  3541. typeof this.solution.id !== 'undefined' &&
  3542. this.solution.id
  3543. ) {
  3544. for (const key in this.solution) {
  3545. this.dialysisPrescription[key] = this.solution[key]
  3546. }
  3547. if (this.solution['dialysate_formulation'] == 0) {
  3548. this.dialysisPrescription['dialysate_formulation'] = ''
  3549. }
  3550. if (this.solution['anticoagulant'] == 0) {
  3551. this.dialysisPrescription['anticoagulant'] = ''
  3552. }
  3553. if (this.solution['dialysis_duration_hour'] == 0) {
  3554. this.dialysisPrescription['dialysis_duration_hour'] = ''
  3555. }
  3556. if (this.solution['dialysis_duration_minute'] == 0) {
  3557. this.dialysisPrescription['dialysis_duration_minute'] = ''
  3558. }
  3559. if (this.solution['blood_flow_volume'] == 0) {
  3560. this.dialysisPrescription['blood_flow_volume'] = ''
  3561. }
  3562. if (this.solution['target_ultrafiltration'] == 0) {
  3563. this.dialysisPrescription['target_ultrafiltration'] = ''
  3564. }
  3565. if (this.solution['dialysate_temperature'] == 0) {
  3566. this.dialysisPrescription['dialysate_temperature'] = ''
  3567. }
  3568. if (this.solution['anticoagulant_shouji'] == 0) {
  3569. this.dialysisPrescription['anticoagulant_shouji'] = 0
  3570. }
  3571. if (this.solution['anticoagulant_weichi'] == 0) {
  3572. this.dialysisPrescription['anticoagulant_weichi'] = 0
  3573. }
  3574. if (this.solution['anticoagulant_zongliang'] == 0) {
  3575. this.dialysisPrescription['anticoagulant_zongliang'] = 0
  3576. }
  3577. if (this.solution['anticoagulant_gaijiliang'] == 0) {
  3578. this.dialysisPrescription['anticoagulant_gaijiliang'] = ''
  3579. }
  3580. if (this.solution['kalium'] == 0) {
  3581. this.dialysisPrescription['kalium'] = ''
  3582. }
  3583. if (this.solution['sodium'] == 0) {
  3584. this.dialysisPrescription['sodium'] = ''
  3585. }
  3586. if (this.solution['calcium'] == 0) {
  3587. this.dialysisPrescription['calcium'] = ''
  3588. }
  3589. if (this.solution['bicarbonate'] == 0) {
  3590. this.dialysisPrescription['bicarbonate'] = ''
  3591. }
  3592. if (this.solution['glucose'] == 0) {
  3593. this.dialysisPrescription['glucose'] = ''
  3594. }
  3595. if (this.solution['dialysate_flow'] == 0) {
  3596. this.dialysisPrescription['dialysate_flow'] = ''
  3597. }
  3598. if (this.solution['conductivity'] == 0) {
  3599. this.dialysisPrescription['conductivity'] = ''
  3600. }
  3601. if (this.solution['replacement_total'] == 0) {
  3602. this.dialysisPrescription['replacement_total'] = ''
  3603. }
  3604. if (this.solution['target_ktv'] == 0) {
  3605. this.dialysisPrescription['target_ktv'] = ''
  3606. }
  3607. }
  3608. }
  3609. },
  3610. stockType: function() {
  3611. console.log('stockType', this.stockType)
  3612. var arr = []
  3613. var arrTwo = []
  3614. for (let i = 0; i < this.stockType.length; i++) {
  3615. if (this.stockType[i].stock_attribute == 2) {
  3616. arr.push(this.stockType[i])
  3617. }
  3618. if (this.stockType[i].stock_attribute == 3) {
  3619. arrTwo.push(this.stockType[i])
  3620. }
  3621. }
  3622. var dialyzator = []
  3623. var irrigation = []
  3624. for (let i = 0; i < arr.length; i++) {
  3625. for (let j = 0; j < arr[i].GoodInfo.length; j++) {
  3626. dialyzator.push(arr[i].GoodInfo[j])
  3627. }
  3628. }
  3629. this.dialyzers = dialyzator
  3630. for (let i = 0; i < arrTwo.length; i++) {
  3631. for (let j = 0; j < arrTwo[i].GoodInfo.length; j++) {
  3632. irrigation.push(arrTwo[i].GoodInfo[j])
  3633. }
  3634. }
  3635. this.irrigations = irrigation
  3636. console.log('透析器', this.dialyzers)
  3637. console.log('灌流器', this.irrigations)
  3638. }
  3639. },
  3640. created() {
  3641. this.illnessList = getDataConfig('hemodialysis', 'illness')
  3642. this.plasmaSeparatorList = getDataConfig('hemodialysis', 'plasma_separator')
  3643. this.bilirubinAdsorptionColumn = getDataConfig('hemodialysis', 'bilirubin_adsorption_column')
  3644. }
  3645. }
  3646. </script>
  3647. <style rel="stylesheet/scss" lang="scss" scoped>
  3648. .el-checkbox,
  3649. .el-checkbox__input {
  3650. vertical-align: middle;
  3651. }
  3652. .newLine {
  3653. display: flex;
  3654. justify-content: space-between;
  3655. height: 40px;
  3656. line-height: 40px;
  3657. border-bottom: 1px solid #ccc;
  3658. color: #303133;
  3659. }
  3660. .warnTxt {
  3661. text-align: center;
  3662. margin: 0 auto;
  3663. background: #faa331;
  3664. max-width: 240px;
  3665. padding: 10px 20px;
  3666. border-radius: 4px;
  3667. margin-bottom: 10px;
  3668. color: #fff;
  3669. }
  3670. </style>
  3671. <style lang="scss">
  3672. .newDialog {
  3673. .el-dialog__body {
  3674. padding: 10px 20px 30px;
  3675. }
  3676. }
  3677. </style>