dialysisPrescriptionDialog.vue 240KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386338733883389339033913392339333943395339633973398339934003401340234033404340534063407340834093410341134123413341434153416341734183419342034213422342334243425342634273428342934303431343234333434343534363437343834393440344134423443344434453446344734483449345034513452345334543455345634573458345934603461346234633464346534663467346834693470347134723473347434753476347734783479348034813482348334843485348634873488348934903491349234933494349534963497349834993500350135023503350435053506350735083509351035113512351335143515351635173518351935203521352235233524352535263527352835293530353135323533353435353536353735383539354035413542354335443545354635473548354935503551355235533554355535563557355835593560356135623563356435653566356735683569357035713572357335743575357635773578357935803581358235833584358535863587358835893590359135923593359435953596359735983599360036013602360336043605360636073608360936103611361236133614361536163617361836193620362136223623362436253626362736283629363036313632363336343635363636373638363936403641364236433644364536463647364836493650365136523653365436553656365736583659366036613662366336643665366636673668366936703671367236733674367536763677367836793680368136823683368436853686368736883689369036913692369336943695369636973698369937003701370237033704370537063707370837093710371137123713371437153716371737183719372037213722372337243725372637273728372937303731373237333734373537363737373837393740374137423743374437453746374737483749375037513752375337543755375637573758375937603761376237633764376537663767376837693770377137723773377437753776377737783779378037813782378337843785378637873788378937903791379237933794379537963797379837993800380138023803380438053806380738083809381038113812381338143815381638173818381938203821382238233824382538263827382838293830383138323833383438353836383738383839384038413842384338443845384638473848384938503851385238533854385538563857385838593860386138623863386438653866386738683869387038713872387338743875387638773878387938803881388238833884388538863887388838893890389138923893389438953896389738983899390039013902390339043905390639073908390939103911391239133914391539163917391839193920392139223923392439253926392739283929393039313932393339343935393639373938393939403941394239433944394539463947394839493950395139523953395439553956395739583959396039613962396339643965396639673968396939703971397239733974397539763977397839793980398139823983398439853986398739883989399039913992399339943995399639973998399940004001400240034004400540064007400840094010401140124013401440154016401740184019402040214022402340244025402640274028402940304031403240334034403540364037403840394040404140424043404440454046404740484049405040514052405340544055405640574058405940604061406240634064406540664067406840694070407140724073407440754076407740784079408040814082408340844085408640874088408940904091409240934094409540964097409840994100410141024103410441054106410741084109411041114112411341144115411641174118411941204121412241234124412541264127412841294130413141324133413441354136413741384139414041414142414341444145414641474148414941504151415241534154415541564157415841594160416141624163416441654166416741684169417041714172417341744175417641774178417941804181418241834184418541864187418841894190419141924193419441954196419741984199420042014202420342044205420642074208420942104211421242134214421542164217421842194220422142224223422442254226422742284229423042314232423342344235423642374238423942404241424242434244424542464247424842494250425142524253425442554256425742584259426042614262426342644265426642674268426942704271427242734274427542764277427842794280428142824283428442854286428742884289429042914292429342944295429642974298429943004301430243034304430543064307430843094310431143124313431443154316431743184319432043214322432343244325432643274328432943304331433243334334433543364337433843394340434143424343434443454346434743484349435043514352435343544355435643574358435943604361436243634364436543664367436843694370437143724373437443754376437743784379438043814382438343844385438643874388438943904391439243934394439543964397439843994400440144024403440444054406440744084409441044114412441344144415441644174418441944204421442244234424442544264427442844294430443144324433443444354436443744384439444044414442444344444445444644474448444944504451445244534454445544564457445844594460446144624463446444654466446744684469447044714472447344744475447644774478447944804481448244834484448544864487448844894490449144924493449444954496449744984499450045014502450345044505450645074508450945104511451245134514451545164517451845194520452145224523452445254526452745284529453045314532453345344535453645374538453945404541454245434544454545464547454845494550455145524553455445554556455745584559456045614562456345644565456645674568456945704571457245734574457545764577457845794580458145824583458445854586458745884589459045914592459345944595459645974598459946004601460246034604460546064607460846094610461146124613461446154616461746184619462046214622462346244625462646274628462946304631463246334634463546364637463846394640464146424643464446454646464746484649465046514652465346544655465646574658465946604661466246634664466546664667466846694670467146724673467446754676467746784679468046814682468346844685468646874688468946904691469246934694469546964697469846994700470147024703470447054706470747084709471047114712471347144715471647174718471947204721472247234724472547264727472847294730473147324733473447354736473747384739474047414742474347444745474647474748474947504751475247534754475547564757475847594760476147624763476447654766476747684769477047714772477347744775477647774778477947804781478247834784478547864787478847894790479147924793479447954796479747984799480048014802480348044805480648074808480948104811481248134814481548164817481848194820482148224823482448254826482748284829483048314832483348344835483648374838483948404841484248434844484548464847484848494850485148524853485448554856485748584859486048614862486348644865486648674868486948704871487248734874487548764877487848794880488148824883488448854886488748884889489048914892489348944895489648974898489949004901490249034904490549064907490849094910491149124913491449154916491749184919492049214922492349244925492649274928492949304931493249334934493549364937493849394940494149424943494449454946494749484949495049514952495349544955495649574958495949604961496249634964496549664967496849694970497149724973497449754976497749784979498049814982498349844985498649874988498949904991499249934994499549964997499849995000500150025003500450055006500750085009501050115012501350145015501650175018501950205021502250235024502550265027502850295030503150325033503450355036503750385039504050415042504350445045504650475048504950505051505250535054505550565057505850595060506150625063506450655066506750685069507050715072507350745075507650775078507950805081508250835084508550865087508850895090509150925093509450955096509750985099510051015102510351045105510651075108510951105111511251135114511551165117511851195120512151225123512451255126512751285129513051315132513351345135513651375138513951405141514251435144514551465147514851495150515151525153515451555156515751585159516051615162516351645165516651675168516951705171517251735174517551765177517851795180518151825183518451855186518751885189519051915192519351945195519651975198519952005201520252035204520552065207520852095210521152125213521452155216
  1. <template>
  2. <div>
  3. <el-dialog
  4. title="透析处方"
  5. :visible.sync="isVisibility"
  6. width="1010px"
  7. :modal = 'false'
  8. :modal-append-to-body="false"
  9. :close-on-click-modal="false"
  10. class="newDialog"
  11. >
  12. <el-button style="position: absolute;left: 12%;top: 2%" @click="handlePatientInfo">{{ patient.name }}</el-button>
  13. <span style="position: absolute;left: 22%;top: 3%">
  14. 透前体重:{{predialysis&&predialysis.weight_before?predialysis.weight_before:"" }} kg
  15. </span>
  16. <span style="position: absolute;left: 35%;top: 3%">
  17. 干体重:{{predialysis&&predialysis.dry_weight?predialysis.dry_weight:""}}kg
  18. </span>
  19. <!-- <span style="position: absolute;left: 48%;top: 3%" :modal = 'false'>
  20. 衣物重:{{predialysis&&predialysis.additional_weight?predialysis.additional_weight:""}}kg
  21. </span> -->
  22. <span style="position: absolute;left: 48%;top: 3%">
  23. 上次透后体重:{{last_record&&last_record.weight_after?last_record.weight_after:""}}kg
  24. </span>
  25. <span style="position: absolute;left: 65%;top: 3%">
  26. 4小时超滤量上限(5%):
  27. <span v-if="predialysis!=null && ((predialysis.dry_weight)*0.05) >0 "></span> {{(predialysis.dry_weight*0.05).toFixed(2)}}
  28. kg
  29. </span>
  30. <div class="warnTxt" v-if="showTxt != ''">{{ showTxt }}</div>
  31. <el-form
  32. ref="dialysisPrescription"
  33. :model="dialysisPrescription"
  34. label-width="148px"
  35. >
  36. <el-row :gutter="24">
  37. <el-col :span="8" v-if="isShows('透析模式')">
  38. <el-form-item label="透析模式" :prop="isName('透析模式')" :rules="isCheckmust('透析模式')">
  39. <el-select
  40. filterable
  41. v-model="dialysisPrescription.mode_id"
  42. @change="changePrescription(dialysisPrescription.mode_id)" placeholder="请选择">
  43. <!-- <el-option :key="0" label="请选择" :value="0"></el-option> -->
  44. <el-option
  45. v-for="(item, index) in treatment_mode"
  46. :label="item.name"
  47. :value="item.id"
  48. :key="index + 'q'"
  49. ></el-option>
  50. </el-select>
  51. </el-form-item>
  52. </el-col>
  53. <el-col :span="8" v-if="isShows('透析时长')">
  54. <el-form-item label="透析时长(h):" prop="dialysis_duration_hour" :rules="isCheckmust('透析时长')">
  55. <el-input
  56. type="number"
  57. v-model="dialysisPrescription.dialysis_duration_hour"
  58. ></el-input>
  59. </el-form-item>
  60. </el-col>
  61. <el-col :span="8" v-if="isShows('透析时长')">
  62. <el-form-item label="透析时长(min): " prop="dialysis_duration_minute" :rules="isCheckmust('透析时长')">
  63. <el-input
  64. type="number"
  65. v-model="dialysisPrescription.dialysis_duration_minute"
  66. ></el-input>
  67. </el-form-item>
  68. </el-col>
  69. <!-- </el-row>
  70. <el-row :gutter="20"> -->
  71. <el-col :span="8" v-if="isShows('血流量')">
  72. <el-form-item label="血流量(ml/min):" prop="blood_flow_volume" :rules="isCheckmust('血流量')">
  73. <el-input
  74. type="number"
  75. v-model="dialysisPrescription.blood_flow_volume"
  76. ></el-input>
  77. </el-form-item>
  78. </el-col>
  79. <el-col :span="8" v-if="isShows('置换流量') && this.$store.getters.xt_user.template_info.org_id != 10340">
  80. <el-form-item label="置换流量(L/h):" prop="replacement_flow" :rules="isCheckmust('置换流量')">
  81. <el-input v-model="dialysisPrescription.replacement_flow"></el-input>
  82. </el-form-item>
  83. </el-col>
  84. <el-col :span="8" v-if="isShows('置换流量') && this.$store.getters.xt_user.template_info.org_id == 10340">
  85. <el-form-item label="置换流量(ml/min):" prop="replacement_flow" :rules="isCheckmust('置换流量')">
  86. <el-input v-model="dialysisPrescription.replacement_flow"></el-input>
  87. </el-form-item>
  88. </el-col>
  89. <el-col :span="8"
  90. 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 || this.$store.getters.xt_user.template_info.org_id == 10345)">
  91. <el-form-item label="预冲量(ml):" prop="pre_impulse" :rules="isCheckmust('预冲量')">
  92. <el-input
  93. type="number"
  94. v-model="dialysisPrescription.pre_impulse"
  95. ></el-input>
  96. </el-form-item>
  97. </el-col>
  98. <el-col :span="8"
  99. 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 && this.$store.getters.xt_user.template_info.org_id!=10345">
  100. <el-form-item label="预冲量(L):" prop="pre_impulse" :rules="isCheckmust('预冲量')">
  101. <el-input
  102. type="number"
  103. v-model="dialysisPrescription.pre_impulse"
  104. ></el-input>
  105. </el-form-item>
  106. </el-col>
  107. <el-col :span="8"
  108. v-if="isShows('目标超滤量') && (this.$store.getters.xt_user.template_info.template_id == 17 || this.$store.getters.xt_user.template_info.template_id == 9 || this.$store.getters.xt_user.template_info.template_id == 20 || this.$store.getters.xt_user.template_info.template_id == 21 || this.$store.getters.xt_user.template_info.template_id == 22 || this.$store.getters.xt_user.template_info.template_id == 23 || this.$store.getters.xt_user.template_info.template_id == 24 || this.$store.getters.xt_user.template_info.template_id == 26 || this.$store.getters.xt_user.template_info.template_id == 28 || this.$store.getters.xt_user.template_info.template_id == 27 || this.$store.getters.xt_user.template_info.template_id == 29 || this.$store.getters.xt_user.template_info.template_id == 30 || this.$store.getters.xt_user.template_info.template_id == 31 || this.$store.getters.xt_user.template_info.template_id == 32 || this.$store.getters.xt_user.template_info.template_id == 34 || this.$store.getters.xt_user.template_info.template_id == 38 || this.$store.getters.xt_user.template_info.template_id == 40 || this.$store.getters.xt_user.template_info.template_id == 43 || this.$store.getters.xt_user.template_info.template_id == 45 || this.$store.getters.xt_user.template_info.template_id == 46 || this.$store.getters.xt_user.template_info.template_id == 48 || this.$store.getters.xt_user.template_info.template_id == 56 || this.$store.getters.xt_user.template_info.org_id == 9555 || this.$store.getters.xt_user.template_info.org_id == 10345 || this.$store.getters.xt_user.template_info.org_id == 10346 || this.$store.getters.xt_user.template_info.org_id == 10249 || this.$store.getters.xt_user.template_info.org_id == 10395 ||this.$store.getters.xt_user.template_info.template_id == 60 || this.$store.getters.xt_user.template_info.org_id == 10340 || this.$store.getters.xt_user.template_info.org_id == 10430 || this.$store.getters.xt_user.template_info.org_id == 10432 || this.$store.getters.xt_user.template_info.org_id == 10441 || this.$store.getters.xt_user.template_info.org_id == 10445 || this.$store.getters.xt_user.template_info.org_id == 9829|| this.$store.getters.xt_user.template_info.org_id == 10440 || this.$store.getters.xt_user.template_info.org_id == 10469|| this.$store.getters.xt_user.template_info.org_id == 10471 || this.$store.getters.xt_user.template_info.org_id == 10460)">
  109. <el-form-item label="目标超滤量(ml):"
  110. prop="target_ultrafiltration" :rules="isCheckmust('目标超滤量')">
  111. <el-input
  112. type="number"
  113. v-model="dialysisPrescription.target_ultrafiltration"
  114. ></el-input>
  115. </el-form-item>
  116. </el-col>
  117. <el-col :span="8"
  118. v-if="isShows('目标超滤量') && this.$store.getters.xt_user.template_info.template_id != 17 && this.$store.getters.xt_user.template_info.template_id != 9 && this.$store.getters.xt_user.template_info.template_id != 20 && this.$store.getters.xt_user.template_info.template_id != 21 && this.$store.getters.xt_user.template_info.template_id != 22 && this.$store.getters.xt_user.template_info.template_id != 23 && this.$store.getters.xt_user.template_info.template_id != 24 && this.$store.getters.xt_user.template_info.template_id != 26 && this.$store.getters.xt_user.template_info.template_id != 28 && this.$store.getters.xt_user.template_info.template_id != 27 && this.$store.getters.xt_user.template_info.template_id != 29 && this.$store.getters.xt_user.template_info.template_id != 30 && this.$store.getters.xt_user.template_info.template_id != 31 && this.$store.getters.xt_user.template_info.template_id != 32 && this.$store.getters.xt_user.template_info.template_id != 34 && this.$store.getters.xt_user.template_info.template_id != 38 && this.$store.getters.xt_user.template_info.template_id != 40 && this.$store.getters.xt_user.template_info.template_id != 43 && this.$store.getters.xt_user.template_info.template_id != 45 && this.$store.getters.xt_user.template_info.template_id != 46 && this.$store.getters.xt_user.template_info.template_id != 48 && this.$store.getters.xt_user.template_info.template_id != 56 && this.$store.getters.xt_user.template_info.org_id != 9555 && this.$store.getters.xt_user.template_info.org_id != 10345 && this.$store.getters.xt_user.template_info.org_id != 10346 && this.$store.getters.xt_user.template_info.org_id != 10249 && this.$store.getters.xt_user.template_info.org_id != 10395 && this.$store.getters.xt_user.template_info.template_id != 60 && this.$store.getters.xt_user.template_info.org_id != 10340 && this.$store.getters.xt_user.template_info.org_id != 10430 && this.$store.getters.xt_user.template_info.org_id != 10432 && this.$store.getters.xt_user.template_info.org_id!=10441 && this.$store.getters.xt_user.template_info.org_id!=10445 && this.$store.getters.xt_user.template_info.org_id!=9829 && this.$store.getters.xt_user.template_info.org_id != 10440 && this.$store.getters.xt_user.template_info.org_id != 10469&& this.$store.getters.xt_user.template_info.org_id != 10471 && this.$store.getters.xt_user.template_info.org_id != 10460">
  119. <el-form-item
  120. label="目标超滤量(L):" prop="target_ultrafiltration" :rules="isCheckmust('目标超滤量')">
  121. <el-input
  122. type="number"
  123. v-model="dialysisPrescription.target_ultrafiltration"
  124. ></el-input>
  125. </el-form-item>
  126. </el-col>
  127. <el-col :span="8"
  128. v-if="isShows('处方脱水量') && this.$store.getters.xt_user.template_info.org_id != 10597">
  129. <el-form-item label="处方脱水量(ml):" prop="prescription_water" :rules="isCheckmust('处方脱水量')">
  130. <el-input
  131. type="number"
  132. v-model="dialysisPrescription.prescription_water"
  133. ></el-input>
  134. </el-form-item>
  135. </el-col>
  136. <el-col :span="8"
  137. v-if="isShows('处方脱水量') && this.$store.getters.xt_user.template_info.org_id == 10597">
  138. <el-form-item label="处方脱水量(L):" prop="prescription_water" :rules="isCheckmust('处方脱水量')">
  139. <el-input
  140. type="number"
  141. v-model="dialysisPrescription.prescription_water"
  142. ></el-input>
  143. </el-form-item>
  144. </el-col>
  145. <el-col :span="8"
  146. v-if="isShows('加糖')">
  147. <el-form-item label="加糖:" prop="prescription_water" :rules="isCheckmust('加糖')">
  148. <el-input v-model="dialysisPrescription.chaptalization"
  149. ></el-input>
  150. </el-form-item>
  151. </el-col>
  152. <el-col :span="8" v-if="isShows('带水上机')">
  153. <el-form-item label="带水上机:" prop="water_machine" :rules="isCheckmust('带水上机')">
  154. <el-select v-model="dialysisPrescription.water_machine">
  155. <el-option
  156. v-for="(item, index) in machineList"
  157. :label="item.name"
  158. :value="item.name"
  159. :key="index + 'q'"
  160. ></el-option>
  161. </el-select>
  162. </el-form-item>
  163. </el-col>
  164. <el-col :span="8" v-if="isShows('是否单超脱水')">
  165. <el-form-item label="是否单超脱水:" prop="is_water" :rules="isCheckmust('是否单超脱水')">
  166. <el-select v-model="dialysisPrescription.is_water">
  167. <el-option
  168. v-for="(item, index) in waterList"
  169. :label="item.name"
  170. :value="item.id"
  171. :key="index + 'q'"
  172. ></el-option>
  173. </el-select>
  174. </el-form-item>
  175. </el-col>
  176. <el-col :span="8" v-if="isShows('单超时长') && dialysisPrescription.is_water == 1">
  177. <el-form-item label="单超时长(h):" prop="single_time" :rules="isCheckmust('单超时长')">
  178. <el-input v-model="dialysisPrescription.single_time"></el-input>
  179. </el-form-item>
  180. </el-col>
  181. <el-col :span="8" v-if="isShows('单超脱水') && dialysisPrescription.is_water == 1">
  182. <el-form-item label="单超脱水(ml):" prop="single_water" :rules="isCheckmust('单超脱水')">
  183. <el-input v-model="dialysisPrescription.single_water"></el-input>
  184. </el-form-item>
  185. </el-col>
  186. <el-col :span="8" v-if="isShows('曲线脱水')">
  187. <el-form-item label="曲线脱水(ml):" prop="drhy_water" :rules="isCheckmust('曲线脱水')">
  188. <el-input v-model="dialysisPrescription.drhy_water"></el-input>
  189. </el-form-item>
  190. </el-col>
  191. <el-col :span="8" v-if="isShows('曲线脱水时长')">
  192. <el-form-item label="曲线脱水时长(h):" prop="dry_water_hour" :rules="isCheckmust('曲线脱水时长')">
  193. <el-input v-model="dialysisPrescription.dry_water_hour"></el-input>
  194. </el-form-item>
  195. </el-col>
  196. <el-col :span="8" v-if="isShows('透析液配方')">
  197. <el-form-item label="透析液配方:" prop="dialysate_formulation" :rules="isCheckmust('透析液配方')">
  198. <!-- <el-input type="number" v-model="dialysisPrescription.dialysate_formulation"></el-input> -->
  199. <el-select
  200. v-model="dialysisPrescription.dialysate_formulation"
  201. placeholder="请选择"
  202. >
  203. <el-option :key="0" label="请选择" :value="0"></el-option>
  204. <el-option
  205. v-for="(option, index) in dialysate_formulation_options"
  206. :key="index + 'w'"
  207. :label="option.name"
  208. :value="option.id"
  209. ></el-option>
  210. </el-select>
  211. </el-form-item>
  212. </el-col>
  213. <!-- </el-row>
  214. <el-row :gutter="20"> -->
  215. <el-col :span="8" v-if="isShows('抗凝剂')">
  216. <el-form-item label="抗凝剂:" prop="anticoagulant" :rules="isCheckmust('抗凝剂')">
  217. <el-select v-model="dialysisPrescription.anticoagulant" placeholder="请选择"
  218. style="width:100%;"
  219. @change="changeThisAnticoagulant">
  220. <el-option :key="0" label="请选择" :value="0"></el-option>
  221. <!-- <el-option v-if="dialysisPrescription.anticoagulant ==3" :key="3" label="低分子肝素"
  222. :value="3"></el-option> -->
  223. <el-option v-for="(item, index) in anticoagulantsConfit" :label="item.name"
  224. :key="index + 'e'"
  225. :value="item.id"></el-option>
  226. </el-select>
  227. </el-form-item>
  228. </el-col>
  229. <el-col :span="8" v-if="isShows('抗凝剂商品名称')">
  230. <el-form-item label="抗凝剂商品名称:" prop="antioxidant_commodity_name" :rules="isCheckmust('抗凝剂商品名称')">
  231. <el-input
  232. v-model="dialysisPrescription.antioxidant_commodity_name"
  233. ></el-input>
  234. </el-form-item>
  235. </el-col>
  236. <el-col :span="8" v-if="isShows('肝素钠') && dialysisPrescription.anticoagulant ==10">
  237. <el-form-item label="肝素钠(mg/h):" prop="heparin_sodium" :rules="isCheckmust('肝素钠')">
  238. <el-input
  239. v-model="dialysisPrescription.heparin_sodium"
  240. ></el-input>
  241. </el-form-item>
  242. </el-col>
  243. <el-col :span="8" v-if="isShows('鱼精蛋白') && dialysisPrescription.anticoagulant ==10">
  244. <el-form-item label="鱼精蛋白(mg/h):" prop="nucleoprotamine" :rules="isCheckmust('鱼精蛋白')">
  245. <el-input肝素
  246. v-model="dialysisPrescription.nucleoprotamine"
  247. ></el-input肝素>
  248. </el-form-item>
  249. </el-col>
  250. <el-col :span="8" v-if="isShows('下机前推注鱼精蛋白') && dialysisPrescription.anticoagulant ==10">
  251. <el-form-item label="下机前推注鱼精蛋白(mg):" prop="push_the_protamine" :rules="isCheckmust('下机前推注鱼精蛋白')">
  252. <el-input
  253. v-model="dialysisPrescription.push_the_protamine"
  254. ></el-input>
  255. </el-form-item>
  256. </el-col>
  257. <el-col :span="8" v-if="isShows('追加肝素量')" >
  258. <el-form-item v-if="dialysisPrescription.anticoagulant == 2"
  259. :label="'追加肝素量(mg) : '" prop="add_amount" :rules="isCheckmust('追加肝素量')">
  260. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  261. v-model="dialysisPrescription.add_amount"></el-input>
  262. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  263. v-model="dialysisPrescription.add_amount"></el-input>
  264. </el-form-item>
  265. <el-form-item v-if="dialysisPrescription.anticoagulant != 2 && dialysisPrescription.anticoagulant != 1"
  266. :label="'追加肝素量(' + anticoagulant.shouji_unit + ') : '" prop="add_amount" :rules="isCheckmust('追加肝素量')">
  267. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  268. v-model="dialysisPrescription.add_amount"></el-input>
  269. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  270. v-model="dialysisPrescription.add_amount"></el-input>
  271. </el-form-item>
  272. </el-col>
  273. <el-col :span="8" v-if="isShows('减肝素量')">
  274. <el-form-item v-if="dialysisPrescription.anticoagulant == 2" :label="'减肝素量(mg) : '" prop="calculateAnticoagulantZL" :rules="isCheckmust('减肝素量')">
  275. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  276. v-model="dialysisPrescription.calculateAnticoagulantZL"></el-input>
  277. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  278. v-model="dialysisPrescription.reduce_amount"></el-input>
  279. </el-form-item>
  280. <el-form-item v-if="dialysisPrescription.anticoagulant != 2 && dialysisPrescription.anticoagulant != 1"
  281. :label="'减肝素量(' + anticoagulant.shouji_unit + ') : '" prop="reduce_amount" :rules="isCheckmust('减肝素量')">
  282. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  283. v-model="dialysisPrescription.reduce_amount"></el-input>
  284. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  285. v-model="dialysisPrescription.reduce_amount"></el-input>
  286. </el-form-item>
  287. </el-col>
  288. <el-col :span="8" v-if="anticoagulant!=undefined && anticoagulant.shouji != -1 && isShows('首剂') && dialysisPrescription.anticoagulant!=1 && dialysisPrescription.anticoagulant!=12">
  289. <div v-if="this.$store.getters.xt_user.template_info.org_id != 10157 &&
  290. this.$store.getters.xt_user.template_info.template_id != 54 &&
  291. this.$store.getters.xt_user.template_info.org_id != 10340 &&
  292. this.$store.getters.xt_user.template_info.org_id != 10432 &&
  293. this.$store.getters.xt_user.template_info.org_id != 9829 &&
  294. this.$store.getters.xt_user.template_info.org_id != 10440 &&
  295. this.$store.getters.xt_user.template_info.org_id != 10469 &&
  296. this.$store.getters.xt_user.template_info.org_id != 10471 &&
  297. this.$store.getters.xt_user.template_info.org_id != 10495 &&
  298. this.$store.getters.xt_user.template_info.org_id != 10375 &&
  299. this.$store.getters.xt_user.template_info.org_id != 10600">
  300. <div v-if="this.$store.getters.xt_user.template_info.org_id != 10101 &&
  301. this.$store.getters.xt_user.template_info.template_id != 45 &&
  302. this.$store.getters.xt_user.template_info.org_id != 10346 &&
  303. this.$store.getters.xt_user.template_info.org_id != 10387 &&
  304. this.$store.getters.xt_user.template_info.org_id != 10495 &&
  305. this.$store.getters.xt_user.template_info.org_id != 10375 &&
  306. this.$store.getters.xt_user.template_info.org_id != 10551 &&
  307. this.$store.getters.xt_user.template_info.org_id != 10600
  308. ">
  309. <el-form-item
  310. v-if='dialysisPrescription.anticoagulant != 1 &&
  311. this.$store.getters.xt_user.template_info.template_id != 21 &&
  312. this.$store.getters.xt_user.template_info.template_id != 23 &&
  313. this.$store.getters.xt_user.template_info.template_id != 38 &&
  314. this.$store.getters.xt_user.template_info.org_id != 9987 &&
  315. this.$store.getters.xt_user.template_info.org_id!=9990'
  316. :label="'首剂(' + anticoagulant.shouji_unit + ') : '" prop="anticoagulant_shouji"
  317. :rules="isCheckmust('首剂')">
  318. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  319. v-model="dialysisPrescription.anticoagulant_shouji"></el-input>
  320. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  321. v-model="dialysisPrescription.no_anticoagulant_shouji"></el-input>
  322. </el-form-item>
  323. <el-form-item v-if="this.$store.getters.xt_user.template_info.org_id == 9990 && dialysisPrescription.anticoagulant==7 &&
  324. this.$store.getters.xt_user.template_info.template_id!=6" :label="'首剂(mg):'"
  325. prop="anticoagulant_shouji" :rules="isCheckmust('首剂')">
  326. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  327. v-model="dialysisPrescription.anticoagulant_shouji"></el-input>
  328. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  329. v-model="dialysisPrescription.no_anticoagulant_shouji"></el-input>
  330. </el-form-item>
  331. <el-form-item v-if="this.$store.getters.xt_user.template_info.org_id == 9990 &&
  332. dialysisPrescription.anticoagulant!=7 && this.$store.getters.xt_user.template_info.template_id!=6"
  333. :label="'首剂(iu):'" prop="anticoagulant_shouji" :rules="isCheckmust('首剂')">
  334. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  335. v-model="dialysisPrescription.anticoagulant_shouji"></el-input>
  336. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  337. v-model="dialysisPrescription.no_anticoagulant_shouji"></el-input>
  338. </el-form-item>
  339. <el-form-item
  340. v-if='dialysisPrescription.anticoagulant == 2 &&
  341. this.$store.getters.xt_user.template_info.template_id == 21 ||
  342. this.$store.getters.xt_user.template_info.template_id == 23 ||
  343. this.$store.getters.xt_user.template_info.template_id == 38 ||
  344. this.$store.getters.xt_user.template_info.org_id == 9987 ||
  345. this.$store.getters.xt_user.template_info.org_id == 10346 ||
  346. this.$store.getters.xt_user.template_info.org_id == 10387 ||
  347. this.$store.getters.xt_user.template_info.org_id ==10495 ||
  348. this.$store.getters.xt_user.template_info.org_id ==10375 ||
  349. this.$store.getters.xt_user.template_info.org_id ==10551 ||
  350. this.$store.getters.xt_user.template_info.org_id ==10600
  351. '
  352. :label="'首剂(mg) : '" prop="anticoagulant_shouji" :rules="isCheckmust('首剂')">
  353. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  354. v-model="dialysisPrescription.anticoagulant_shouji"></el-input>
  355. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  356. v-model="dialysisPrescription.no_anticoagulant_shouji"></el-input>
  357. </el-form-item>
  358. </div>
  359. <div v-else>
  360. <el-form-item v-if="dialysisPrescription.anticoagulant == 2" :label="'首剂(mg) : '" prop="anticoagulant_shouji" :rules="isCheckmust('首剂')">
  361. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  362. v-model="dialysisPrescription.anticoagulant_shouji"></el-input>
  363. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  364. v-model="dialysisPrescription.no_anticoagulant_shouji"></el-input>
  365. </el-form-item>
  366. <el-form-item v-else :label="'首剂(iu) : '" prop="anticoagulant_shouji" :rules="isCheckmust('首剂')">
  367. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  368. v-model="dialysisPrescription.anticoagulant_shouji"></el-input>
  369. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  370. v-model="dialysisPrescription.no_anticoagulant_shouji"></el-input>
  371. </el-form-item>
  372. </div>
  373. </div>
  374. <div v-else>
  375. <el-form-item v-if="dialysisPrescription.anticoagulant == 2" :label="'首剂(mg) : '" prop="anticoagulant_shouji" :rules="isCheckmust('首剂')">
  376. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  377. v-model="dialysisPrescription.anticoagulant_shouji"></el-input>
  378. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  379. v-model="dialysisPrescription.no_anticoagulant_shouji"></el-input>
  380. </el-form-item>
  381. <el-form-item v-else :label="'首剂(' + anticoagulant.shouji_unit + ') : '" prop="anticoagulant_shouji" :rules="isCheckmust('首剂')">
  382. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  383. v-model="dialysisPrescription.anticoagulant_shouji"></el-input>
  384. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  385. v-model="dialysisPrescription.no_anticoagulant_shouji"></el-input>
  386. </el-form-item>
  387. </div>
  388. </el-col>
  389. <el-col :span="8" v-if="anticoagulant!=undefined &&anticoagulant.weichi != -1 && isShows('维持') && dialysisPrescription.anticoagulant!=1&& dialysisPrescription.anticoagulant!=12">
  390. <div v-if="this.$store.getters.xt_user.template_info.org_id != 10157 && this.$store.getters.xt_user.template_info.org_id != 9990 && this.$store.getters.xt_user.template_info.org_id != 9671 && this.$store.getters.xt_user.template_info.org_id != 10340 && this.$store.getters.xt_user.template_info.org_id != 10432 && this.$store.getters.xt_user.template_info.org_id != 9829 && this.$store.getters.xt_user.template_info.org_id != 10440 && this.$store.getters.xt_user.template_info.org_id != 10469 && this.$store.getters.xt_user.template_info.org_id != 10471 && this.$store.getters.xt_user.template_info.org_id != 10495 && this.$store.getters.xt_user.template_info.org_id != 10375 && this.$store.getters.xt_user.template_info.org_id != 10600">
  391. <div v-if="this.$store.getters.xt_user.template_info.org_id != 10101 && this.$store.getters.xt_user.template_info.template_id != 45 && this.$store.getters.xt_user.template_info.template_id != 54 && this.$store.getters.xt_user.template_info.org_id != 10346 && this.$store.getters.xt_user.template_info.org_id != 10387 && this.$store.getters.xt_user.template_info.org_id != 10495 && this.$store.getters.xt_user.template_info.org_id != 10375 ">
  392. <el-form-item :label="'维持(' + anticoagulant.weichi_unit + ') : '"
  393. v-if="anticoagulant.weichi != -1 &&
  394. this.$store.getters.xt_user.template_info.template_id != 21 &&
  395. this.$store.getters.xt_user.template_info.template_id != 23 &&
  396. this.$store.getters.xt_user.template_info.template_id != 38 &&
  397. this.$store.getters.xt_user.template_info.org_id != 9987 &&
  398. this.$store.getters.xt_user.template_info.org_id != 54 &&
  399. this.$store.getters.xt_user.template_info.org_id != 9990 &&
  400. this.$store.getters.xt_user.template_info.org_id != 10495 &&
  401. this.$store.getters.xt_user.template_info.org_id != 10375 &&
  402. this.$store.getters.xt_user.template_info.org_id != 10551 &&
  403. this.$store.getters.xt_user.template_info.org_id != 10600" prop="anticoagulant_weichi" :rules="isCheckmust('维持')">
  404. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  405. v-model="dialysisPrescription.anticoagulant_weichi"></el-input>
  406. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  407. v-model="dialysisPrescription.no_anticoagulant_weichi"></el-input>
  408. </el-form-item>
  409. <el-form-item :label="'维持(mg/h) : '"
  410. v-if="anticoagulant.weichi != -1 &&
  411. this.$store.getters.xt_user.template_info.template_id == 21 ||
  412. this.$store.getters.xt_user.template_info.template_id == 23 ||
  413. this.$store.getters.xt_user.template_info.template_id == 38 ||
  414. this.$store.getters.xt_user.template_info.org_id == 9987 ||
  415. this.$store.getters.xt_user.template_info.org_id == 54 ||
  416. this.$store.getters.xt_user.template_info.org_id == 10346 ||
  417. this.$store.getters.xt_user.template_info.org_id == 10387 ||
  418. this.$store.getters.xt_user.template_info.org_id == 9990 ||
  419. this.$store.getters.xt_user.template_info.org_id == 10495 ||
  420. this.$store.getters.xt_user.template_info.org_id == 10375 ||
  421. this.$store.getters.xt_user.template_info.org_id == 10551 ||
  422. this.$store.getters.xt_user.template_info.org_id == 10600
  423. " prop="anticoagulant_weichi" :rules="isCheckmust('维持')">
  424. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  425. v-model="dialysisPrescription.anticoagulant_weichi"></el-input>
  426. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  427. v-model="dialysisPrescription.no_anticoagulant_weichi"></el-input>
  428. </el-form-item>
  429. </div>
  430. <div v-else>
  431. <el-form-item :label="'维持(iu/h) : '" prop="anticoagulant_weichi" :rules="isCheckmust('维持')"
  432. v-if="anticoagulant.weichi != -1 && dialysisPrescription.anticoagulant != 2" >
  433. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  434. v-model="dialysisPrescription.anticoagulant_weichi"></el-input>
  435. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  436. v-model="dialysisPrescription.no_anticoagulant_weichi"></el-input>
  437. </el-form-item>
  438. <el-form-item :label="'维持(mg/h) : '" prop="anticoagulant_weichi" :rules="isCheckmust('维持')"
  439. v-if="anticoagulant.weichi != -1 && dialysisPrescription.anticoagulant == 2" >
  440. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  441. v-model="dialysisPrescription.anticoagulant_weichi"></el-input>
  442. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  443. v-model="dialysisPrescription.no_anticoagulant_weichi"></el-input>
  444. </el-form-item>
  445. </div>
  446. </div>
  447. <div v-else>
  448. <el-form-item v-if="dialysisPrescription.anticoagulant == 2" :label="'维持(mg/h) : '"
  449. prop="anticoagulant_weichi" :rules="isCheckmust('维持')">
  450. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  451. v-model="dialysisPrescription.anticoagulant_weichi"></el-input>
  452. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  453. v-model="dialysisPrescription.no_anticoagulant_weichi"></el-input>
  454. </el-form-item>
  455. <el-form-item :label="'维持(' + anticoagulant.weichi_unit + ') : '" v-else
  456. prop="anticoagulant_weichi" :rules="isCheckmust('维持')">
  457. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  458. v-model="dialysisPrescription.anticoagulant_weichi"></el-input>
  459. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  460. v-model="dialysisPrescription.no_anticoagulant_weichi"></el-input>
  461. </el-form-item>
  462. </div>
  463. </el-col>
  464. <el-col :span="8"
  465. v-if="isShows('维持时长')">
  466. <el-form-item label="维持时长(h):" prop="prescribing_number" :rules="isCheckmust('维持时长')">
  467. <el-input v-model="dialysisPrescription.anticoagulant_weichi_hour"></el-input>
  468. </el-form-item>
  469. </el-col>
  470. <el-col :span="8" v-if="anticoagulant!=undefined &&anticoagulant.zongliang != -1 && isShows('总量') && dialysisPrescription.anticoagulant!=1&& dialysisPrescription.anticoagulant!=12">
  471. <div v-if="this.$store.getters.xt_user.template_info.org_id != 10157 && this.$store.getters.xt_user.template_info.org_id != 9671 && this.$store.getters.xt_user.template_info.org_id != 9675 && this.$store.getters.xt_user.template_info.org_id != 10340 && this.$store.getters.xt_user.template_info.org_id != 10432 && this.$store.getters.xt_user.template_info.org_id != 9829 && this.$store.getters.xt_user.template_info.org_id != 10440 && this.$store.getters.xt_user.template_info.org_id != 10469 && this.$store.getters.xt_user.template_info.org_id != 10471 && this.$store.getters.xt_user.template_info.org_id != 10495 && this.$store.getters.xt_user.template_info.org_id != 10375 && this.$store.getters.xt_user.template_info.org_id != 10551 && this.$store.getters.xt_user.template_info.org_id != 10600">
  472. <div v-if="this.$store.getters.xt_user.template_info.org_id != 10101 && this.$store.getters.xt_user.template_info.template_id != 45 && this.$store.getters.xt_user.template_info.template_id != 54 && this.$store.getters.xt_user.template_info.org_id != 10346 && this.$store.getters.xt_user.template_info.org_id != 10387 && this.$store.getters.xt_user.template_info.org_id != 10495">
  473. <el-form-item
  474. 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 && this.$store.getters.xt_user.template_info.template_id != 54 && this.$store.getters.xt_user.template_info.org_id != 10346 && this.$store.getters.xt_user.template_info.org_id != 10387 && this.$store.getters.xt_user.template_info.org_id != 9990 && this.$store.getters.xt_user.template_info.org_id != 10495 && this.$store.getters.xt_user.template_info.org_id != 10375 && this.$store.getters.xt_user.template_info.org_id != 10551 && this.$store.getters.xt_user.template_info.org_id != 10600'
  475. :label="'总量(' + anticoagulant.zongliang_unit + ') : '" prop="anticoagulant_zongliang" :rules="isCheckmust('总量')">
  476. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  477. v-model="dialysisPrescription.anticoagulant_zongliang"></el-input>
  478. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  479. v-model="dialysisPrescription.no_anticoagulant_zongliang"></el-input>
  480. </el-form-item>
  481. <el-form-item
  482. 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 || this.$store.getters.xt_user.template_info.template_id == 54 || this.$store.getters.xt_user.template_info.org_id == 10346 || this.$store.getters.xt_user.template_info.org_id == 10387 || this.$store.getters.xt_user.template_info.org_id == 10495 || this.$store.getters.xt_user.template_info.org_id == 10375 || this.$store.getters.xt_user.template_info.org_id == 10551 || this.$store.getters.xt_user.template_info.org_id == 10600 '
  483. :label="'总量(mg) : '" prop="anticoagulant_zongliang" :rules="isCheckmust('总量')">
  484. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  485. v-model="dialysisPrescription.anticoagulant_zongliang"></el-input>
  486. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  487. v-model="dialysisPrescription.no_anticoagulant_zongliang"></el-input>
  488. </el-form-item>
  489. <el-form-item
  490. v-if='this.$store.getters.xt_user.template_info.org_id == 9990 && dialysisPrescription.anticoagulant == 7 && this.$store.getters.xt_user.template_info.template_id!=6'
  491. :label="'总量(mg)'" prop="anticoagulant_zongliang" :rules="isCheckmust('总量')">
  492. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  493. v-model="dialysisPrescription.anticoagulant_zongliang"></el-input>
  494. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  495. v-model="dialysisPrescription.no_anticoagulant_zongliang"></el-input>
  496. </el-form-item>
  497. <el-form-item
  498. v-if="this.$store.getters.xt_user.template_info.org_id == 9990 && dialysisPrescription.anticoagulant!=7"
  499. :label="'总量(iu)'" prop="anticoagulant_zongliang" :rules="isCheckmust('总量')">
  500. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  501. v-model="dialysisPrescription.anticoagulant_zongliang"></el-input>
  502. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  503. v-model="dialysisPrescription.no_anticoagulant_zongliang"></el-input>
  504. </el-form-item>
  505. </div>
  506. <div v-else>
  507. <el-form-item
  508. v-if='dialysisPrescription.anticoagulant != 2'
  509. :label="'总量(iu) : '" prop="anticoagulant_zongliang" :rules="isCheckmust('总量')">
  510. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  511. v-model="dialysisPrescription.anticoagulant_zongliang"></el-input>
  512. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  513. v-model="dialysisPrescription.no_anticoagulant_zongliang"></el-input>
  514. </el-form-item>
  515. <el-form-item
  516. v-if='dialysisPrescription.anticoagulant == 2'
  517. :label="'总量(mg) : '" prop="anticoagulant_zongliang" :rules="isCheckmust('总量')">
  518. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  519. v-model="dialysisPrescription.anticoagulant_zongliang"></el-input>
  520. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  521. v-model="dialysisPrescription.no_anticoagulant_zongliang"></el-input>
  522. </el-form-item>
  523. </div>
  524. </div>
  525. <div v-else>
  526. <el-form-item v-if="dialysisPrescription.anticoagulant == 2" :label="'总量(mg) : '" prop="anticoagulant_zongliang" :rules="isCheckmust('总量')">
  527. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  528. v-model="dialysisPrescription.anticoagulant_zongliang"></el-input>
  529. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  530. v-model="dialysisPrescription.no_anticoagulant_zongliang"></el-input>
  531. </el-form-item>
  532. <el-form-item v-else :label="'总量(' + anticoagulant.zongliang_unit + ') : '" prop="anticoagulant_zongliang" :rules="isCheckmust('总量')">
  533. <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
  534. v-model="dialysisPrescription.anticoagulant_zongliang"></el-input>
  535. <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
  536. v-model="dialysisPrescription.no_anticoagulant_zongliang"></el-input>
  537. </el-form-item>
  538. </div>
  539. </el-col>
  540. <el-col :span="8"
  541. v-if="isShows('开药数量')">
  542. <el-form-item label="开药数量(支):" prop="prescribing_number" :rules="isCheckmust('开药数量')">
  543. <el-input type="number" v-model="dialysisPrescription.prescribing_number"></el-input>
  544. </el-form-item>
  545. </el-col>
  546. <el-col :span="8"
  547. v-if="isShows('置换量') && ((this.$store.getters.xt_user.template_info.template_id == 20 || this.$store.getters.xt_user.template_info.template_id == 28 || this.$store.getters.xt_user.template_info.template_id == 29 || this.$store.getters.xt_user.template_info.template_id == 46 || this.$store.getters.xt_user.template_info.template_id == 53)&& this.$store.getters.xt_user.template_info.org_id!=10441)"
  548. v-show="zhiShow">
  549. <el-form-item label="置换量(ml):" prop="replacement_total" :rules="isCheckmust('置换量')">
  550. <el-input
  551. type="number"
  552. v-model="dialysisPrescription.replacement_total"
  553. ></el-input>
  554. </el-form-item>
  555. </el-col>
  556. <el-col :span="8"
  557. v-if="isShows('置换量') && (this.$store.getters.xt_user.template_info.template_id != 20 && this.$store.getters.xt_user.template_info.template_id != 28 && this.$store.getters.xt_user.template_info.template_id != 29 && this.$store.getters.xt_user.template_info.template_id != 40 && this.$store.getters.xt_user.template_info.template_id != 46 && this.$store.getters.xt_user.template_info.template_id != 53) || this.$store.getters.xt_user.template_info.org_id == 10441"
  558. v-show="zhiShow">
  559. <el-form-item label="置换量(L):" prop="replacement_total" :rules="isCheckmust('置换量')">
  560. <el-input
  561. type="number"
  562. v-model="dialysisPrescription.replacement_total"
  563. ></el-input>
  564. </el-form-item>
  565. </el-col>
  566. <el-col :span="8" v-if="isShows('置换速度') && this.$store.getters.xt_user.template_info.org_id != 10375" v-show="totalShow">
  567. <el-form-item label="置换速度(ml/min)" prop="displace_speed" :rules="isCheckmust('置换速度')">
  568. <el-input
  569. v-model="dialysisPrescription.displace_speed"
  570. ></el-input>
  571. </el-form-item>
  572. </el-col>
  573. <el-col :span="8" v-if="isShows('置换速度') && this.$store.getters.xt_user.template_info.org_id == 10375" v-show="totalShow">
  574. <el-form-item label="置换速度(L/h)" prop="displace_speed" :rules="isCheckmust('置换速度')">
  575. <el-input
  576. v-model="dialysisPrescription.displace_speed"
  577. ></el-input>
  578. </el-form-item>
  579. </el-col>
  580. <el-col
  581. :span="8"
  582. v-if="isShows('钙名称')"
  583. >
  584. <el-form-item label="钙名称 : " prop="anticoagulant_gaimingcheng" :rules="isCheckmust('钙名称')">
  585. <el-input
  586. v-model="dialysisPrescription.anticoagulant_gaimingcheng"
  587. placeholder="钙名称"
  588. ></el-input>
  589. </el-form-item>
  590. </el-col>
  591. <el-col
  592. :span="8"
  593. v-if="isShows('钙剂量')"
  594. ></el-col>
  595. <el-col :span="8" v-if="isShows('钙剂量')" >
  596. <el-form-item label="钙剂量(ml) : " prop="anticoagulant_gaijiliang" :rules="isCheckmust('钙剂量')">
  597. <el-input
  598. type="number"
  599. v-model="dialysisPrescription.anticoagulant_gaijiliang"
  600. placeholder="钙剂量"
  601. ></el-input>
  602. </el-form-item>
  603. </el-col>
  604. <el-col :span="8" v-if="isShows('钾')">
  605. <el-form-item label="钾(mmol/L): " prop="kalium" :rules="isCheckmust('钾')">
  606. <el-input
  607. type="number"
  608. v-model="dialysisPrescription.kalium"
  609. ></el-input>
  610. </el-form-item>
  611. </el-col>
  612. <el-col :span="8" v-if="isShows('钠')"><!-- :prop="isName('钠')" prop="sodium" isCheckmust [{required: true, message: '请输入钠', trigger: 'blur'}]-->
  613. <el-form-item label="钠(mmol/L):" prop="sodium" :rules="isNas('钠')">
  614. <el-input
  615. type="number"
  616. v-model="dialysisPrescription.sodium"
  617. ></el-input>
  618. </el-form-item>
  619. </el-col>
  620. <el-col :span="8" v-if="isShows('钙')">
  621. <el-form-item label="钙(mmol/L):" prop="calcium" :rules="isCheckmust('钙')">
  622. <el-input
  623. type="number"
  624. v-model="dialysisPrescription.calcium"
  625. ></el-input>
  626. </el-form-item>
  627. </el-col>
  628. <el-col :span="8" v-if="isShows('碳酸氢盐')">
  629. <el-form-item label="碳酸氢盐(mmol/L):" prop="bicarbonate" :rules="isCheckmust('碳酸氢盐')">
  630. <el-input
  631. type="number"
  632. v-model="dialysisPrescription.bicarbonate"
  633. ></el-input>
  634. </el-form-item>
  635. </el-col>
  636. <!-- <el-col :span="8" v-if="isShows('葡萄糖')">
  637. <el-form-item label="葡萄糖(mmol/L):">
  638. <el-input
  639. type="number"
  640. v-model="dialysisPrescription.glucose"
  641. ></el-input>
  642. </el-form-item>28
  643. </el-col> -->
  644. <el-col :span="8" v-if="isShows('透析液流量')">
  645. <el-form-item label="透析液流量(ml/min):" prop="dialysate_flow" :rules="isCheckmust('透析液流量')">
  646. <el-input
  647. type="number"
  648. v-model="dialysisPrescription.dialysate_flow"
  649. ></el-input>
  650. </el-form-item>
  651. </el-col>
  652. <el-col :span="8" v-if="isShows('透析液温度')">
  653. <el-form-item label="透析液温度(°C):" prop="dialysate_temperature" :rules="isCheckmust('透析液温度')">
  654. <el-input
  655. type="number"
  656. v-model="dialysisPrescription.dialysate_temperature"
  657. ></el-input>
  658. </el-form-item>
  659. </el-col>
  660. <el-col :span="8" v-if="isShows('电导率')">
  661. <el-form-item label="电导率(mS/cm): " prop="conductivity" :rules="isCheckmust('电导率')">
  662. <el-input
  663. type="number"
  664. v-model="dialysisPrescription.conductivity"
  665. ></el-input>
  666. </el-form-item>
  667. </el-col>
  668. <el-col :span="8" v-if="isShows('透析器/灌流器')" >
  669. <el-form-item label="透析器/灌流器" prop="dialyzer_perfusion_apparatus" :rules="isCheckmust('透析器/灌流器')">
  670. <el-input v-model="dialysisPrescription.dialyzer_perfusion_apparatus"
  671. @focus="showInnerDialog('5')"></el-input>
  672. </el-form-item>
  673. </el-col>
  674. <el-col :span="8" v-if="isShows('透析器')">
  675. <el-form-item label="透析器:" prop="dialysis_dialyszers" :rules="isCheckmust('透析器')">
  676. <el-input v-model="dialysisPrescription.dialysis_dialyszers"
  677. @focus="showInnerDialog('7')"></el-input>
  678. </el-form-item>
  679. </el-col>
  680. <el-col :span="8" v-if="isShows('灌流器')">
  681. <el-form-item label="灌流器:" prop="dialysis_irrigation" :rules="isCheckmust('灌流器')">
  682. <el-input v-model="dialysisPrescription.dialysis_irrigation"
  683. @focus="showInnerDialog('8')"></el-input>
  684. </el-form-item>
  685. </el-col>
  686. <el-col :span="8" v-if="isShows('滤过器')">
  687. <el-form-item label="滤过器:" prop="dialysis_strainer" :rules="isCheckmust('滤过器')">
  688. <el-input v-model="dialysisPrescription.dialysis_strainer"
  689. @focus="showInnerDialog('12')"></el-input>
  690. </el-form-item>
  691. </el-col>
  692. <el-col :span="8" v-if="isShows('血浆分离器')">
  693. <el-form-item label="血浆分离器:" prop="plasma_separator" :rules="isCheckmust('血浆分离器')">
  694. <el-input v-model="dialysisPrescription.plasma_separator"
  695. @focus="showInnerDialog('9')"></el-input>
  696. </el-form-item>
  697. </el-col>
  698. <el-col :span="8" v-if="isShows('胆红素吸附柱')">
  699. <el-form-item label="胆红素吸附柱:" prop="bilirubin_adsorption_column" :rules="isCheckmust('胆红素吸附柱')">
  700. <el-input v-model="dialysisPrescription.bilirubin_adsorption_column"
  701. @focus="showInnerDialog('10')"></el-input>
  702. </el-form-item>
  703. </el-col>
  704. <el-col :span="8" v-if="isShows('体液过多症状')">
  705. <el-form-item label="体液过多症状:" prop="body_fluid" :rules="isCheckmust('体液过多症状')">
  706. <el-select
  707. v-model="dialysisPrescription.body_fluid"
  708. placeholder="请选择"
  709. style="width:100%;"
  710. >
  711. <el-option :key="0" label="请选择" :value="0"></el-option>
  712. <el-option
  713. v-for="(item, index) in body_fluid_option"
  714. :label="item.name"
  715. :key="index + 't'"
  716. :value="item.id"
  717. ></el-option>
  718. </el-select>
  719. </el-form-item>
  720. </el-col>
  721. <el-col :span="8" v-if="isShows('体液过多其他症状')">
  722. <el-form-item label="体液过多其他症状" prop="body_fluid_other" :rules="isCheckmust('体液过多其他症状')">
  723. <el-input
  724. v-model="dialysisPrescription.body_fluid_other"
  725. ></el-input>
  726. </el-form-item>
  727. </el-col>
  728. <el-col :span="8" v-if="isShows('透析前使用特殊药物')" >
  729. <el-form-item label="透析前使用特殊药物" prop="special_medicine" :rules="isCheckmust('透析前使用特殊药物')">
  730. <el-select
  731. v-model="dialysisPrescription.special_medicine"
  732. placeholder="请选择"
  733. style="width:100%;"
  734. >
  735. <el-option :key="0" label="请选择" :value="0"></el-option>
  736. <el-option
  737. v-for="(item, index) in special_medicine_option"
  738. :label="item.name"
  739. :key="index + 'y'"
  740. :value="item.id"
  741. ></el-option>
  742. </el-select>
  743. </el-form-item>
  744. </el-col>
  745. <el-col :span="8" v-if="isShows('透析前使用其他特殊药物')" >
  746. <el-form-item label="透析前使用其他特殊药物" prop="special_medicine_other" :rules="isCheckmust('透析前使用其他特殊药物')">
  747. <el-input
  748. v-model="dialysisPrescription.special_medicine_other"
  749. ></el-input>
  750. </el-form-item>
  751. </el-col>
  752. <el-col :span="8">
  753. <el-form-item
  754. label="置换方式:"
  755. v-if="isShows('置换液')&&this.$store.getters.xt_user.org.id != 10206"
  756. v-show="huShow"
  757. prop="displace_liqui_part"
  758. :rules="isCheckmust('置换液')"
  759. >
  760. <el-select
  761. v-model="dialysisPrescription.displace_liqui_part"
  762. placeholder="请选择"
  763. >
  764. <el-option :key="0" label="请选择" :value="0"></el-option>
  765. <el-option
  766. v-for="(option, index) in displace_liqui_part_option"
  767. :key="index + 'u'"
  768. :label="option.name"
  769. :value="option.id"
  770. ></el-option>
  771. </el-select>
  772. </el-form-item>
  773. <el-form-item
  774. label="置换方式:"
  775. v-if="isShows('置换方式')&&this.$store.getters.xt_user.org.id == 10206"
  776. v-show="huShow"
  777. prop="displace_liqui_part"
  778. :rules="isCheckmust('置换方式')"
  779. >
  780. <el-select
  781. v-model="dialysisPrescription.displace_liqui_part"
  782. placeholder="请选择"
  783. >
  784. <el-option :key="0" label="请选择" :value="0"></el-option>
  785. <el-option
  786. v-for="(option, index) in displace_liqui_part_option"
  787. :key="index + 'u'"
  788. :label="option.name"
  789. :value="option.id"
  790. ></el-option>
  791. </el-select>
  792. </el-form-item>
  793. </el-col>
  794. <el-col :span="8"
  795. 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 || this.$store.getters.xt_user.template_info.template_id ==53) && this.$store.getters.xt_user.template_info.org_id != 10249) && this.$store.getters.xt_user.template_info.org_id != 10441)"
  796. v-show="totalShow">
  797. <el-form-item label="置换液总量(ml)" prop="displace_liqui_value" :rules="isCheckmust('置换液总量')">
  798. <el-input
  799. v-model="dialysisPrescription.displace_liqui_value"
  800. ></el-input>
  801. </el-form-item>
  802. </el-col>
  803. <el-col :span="8"
  804. 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 && this.$store.getters.xt_user.template_info.template_id !=53) || this.$store.getters.xt_user.template_info.org_id == 10249 || this.$store.getters.xt_user.template_info.org_id == 10441 "
  805. v-show="totalShow">
  806. <!-- v-show="totalShow" -->
  807. <el-form-item label="置换液总量(L)" prop="displace_liqui_value" :rules="isCheckmust('置换液总量')">
  808. <el-input
  809. v-model="dialysisPrescription.displace_liqui_value"
  810. ></el-input>
  811. </el-form-item>
  812. </el-col>
  813. <el-col :span="8" v-if="isShows('目标KT/V')">
  814. <el-form-item label="目标KT/V" prop="target_ktv" :rules="isCheckmust('目标KT/V')">
  815. <el-input v-model="dialysisPrescription.target_ktv"></el-input>
  816. </el-form-item>
  817. </el-col>
  818. <el-col :span="8">
  819. <el-form-item label="血管通路部位: " :prop="isName('血管通路部位')"
  820. :rules="isCheckmust('血管通路部位')" v-if="isShows('血管通路部位')">
  821. <el-input v-model="dialysisPrescription.blood_access_part_id" readonly @focus="showInnerDialog('17')"></el-input>
  822. </el-form-item>
  823. </el-col>
  824. <el-col :span="8" v-if="isShows('血管通路')">
  825. <el-form-item label="血管通路:" prop="blood_access" :rules="isCheckmust('血管通路')">
  826. <el-select
  827. v-model="dialysisPrescription.blood_access"
  828. placeholder="请选择"
  829. >
  830. <el-option :key="0" label="请选择" :value="0"></el-option>
  831. <el-option
  832. v-for="(option, index) in blood_access_option"
  833. :key="index + 'i'"
  834. :label="option.name"
  835. :value="option.id"
  836. ></el-option>
  837. </el-select>
  838. </el-form-item>
  839. </el-col>
  840. <el-col :span="8" v-if="isShows('抗凝提前停止')">
  841. <el-form-item label="抗凝提前停止(h): " prop="anticoagulant_stop_time_hour" :rules="isCheckmust('抗凝提前停止')">
  842. <el-input
  843. type="number"
  844. v-model="dialysisPrescription.anticoagulant_stop_time_hour"
  845. ></el-input>
  846. </el-form-item>
  847. </el-col>
  848. <el-col :span="8" v-if="isShows('抗凝提前停止')">
  849. <el-form-item label="抗凝提前停止(min): " prop="anticoagulant_stop_time_min" :rules="isCheckmust('抗凝提前停止')">
  850. <el-input
  851. type="number"
  852. v-model="dialysisPrescription.anticoagulant_stop_time_min"
  853. ></el-input>
  854. </el-form-item>
  855. </el-col>
  856. <el-col :span="8" v-if="isShows('抽血')">
  857. <el-form-item label="抽血:" prop="blood" :rules="isCheckmust('抽血')">
  858. <el-input v-model="dialysisPrescription.blood" @focus="showInnerDialog('6')" ></el-input>
  859. </el-form-item>
  860. </el-col>
  861. <el-col :span="8" v-if="isShows('病情')">
  862. <el-form-item label="病情:" prop="illness" :rules="isCheckmust('病情')">
  863. <el-select v-model="dialysisPrescription.illness" placeholder="请选择">
  864. <el-option :key="0" label="请选择" :value="0"></el-option>
  865. <el-option
  866. v-for="(item, index) in illnessList "
  867. :key="index"
  868. :label="item.name"
  869. :value="item.id"
  870. ></el-option>
  871. </el-select>
  872. </el-form-item>
  873. </el-col>
  874. <el-col :span="8" v-if="isShows('葡萄糖')">
  875. <el-form-item label="葡萄糖:" prop="amylaceum" :rules="isCheckmust('葡萄糖')">
  876. <el-input v-model="dialysisPrescription.amylaceum"></el-input>
  877. </el-form-item>
  878. </el-col>
  879. <el-col :span="8" v-if="isShows('吸氧')">
  880. <el-form-item label="吸氧:" prop="oxygen_uptake" :rules="isCheckmust('吸氧')">
  881. <el-select v-model="dialysisPrescription.oxygen_uptake" placeholder="请选择"
  882. @change="changeOxygenList">
  883. <el-option :key="0" label="请选择" :value="0"></el-option>
  884. <el-option
  885. v-for="(item, index) in oxygenList "
  886. :key="index"
  887. :label="item.name"
  888. :value="item.id"
  889. ></el-option>
  890. </el-select>
  891. </el-form-item>
  892. </el-col>
  893. <el-col :span="8" v-if="isShows('吸氧') && oxygenShow == true">
  894. <el-form-item label="吸氧流量(L/分):" prop="oxygen_flow" :rules="isCheckmust('吸氧流量')">
  895. <el-input v-model="dialysisPrescription.oxygen_flow"></el-input>
  896. </el-form-item>
  897. </el-col>
  898. <el-col :span="8" v-if="isShows('吸氧') && oxygenShow == true">
  899. <el-form-item label="吸氧时长(h):" prop="oxygen_time" :rules="isCheckmust('吸氧时长')">
  900. <el-input v-model="dialysisPrescription.oxygen_time"></el-input>
  901. </el-form-item>
  902. </el-col>
  903. <el-col :span="8" v-if="isShows('透析管路')">
  904. <el-form-item label="透析管路:" prop="hemodialysis_pipelines" :rules="isCheckmust('透析管路')">
  905. <el-select
  906. v-model="dialysisPrescription.hemodialysis_pipelines"
  907. placeholder="请选择"
  908. style="width:100%;"
  909. >
  910. <el-option :key="0" label="请选择" :value="0"></el-option>
  911. <el-option
  912. v-for="(item, index) in hemodialysisPipelinesOptions"
  913. :label="item.name"
  914. :key="index + 't'"
  915. :value="item.name"
  916. ></el-option>
  917. </el-select>
  918. </el-form-item>
  919. </el-col>
  920. <el-col :span="8" v-if="isShows('透析管路支数')">
  921. <el-form-item label="透析管路支数" prop="hemodialysis_pipelines_count" :rules="isCheckmust('透析管路支数')">
  922. <el-input oninput="value=value.replace(/\D|^0/g,'')" v-model="dialysisPrescription.hemodialysis_pipelines_count"
  923. ></el-input>
  924. </el-form-item>
  925. </el-col>
  926. <el-col :span="8" v-if="isShows('穿刺针')">
  927. <el-form-item label="穿刺针" prop="puncture_needle" :rules="isCheckmust('穿刺针')">
  928. <el-input v-model="dialysisPrescription.puncture_needle"
  929. @focus="showInnerDialog('11')"></el-input>
  930. </el-form-item>
  931. </el-col>
  932. <el-col :span="8" v-if="isShows('穿刺针支数')" >
  933. <el-form-item label="穿刺针支数" prop="puncture_needle_count" :rules="isCheckmust('穿刺针支数')">
  934. <el-input oninput="value=value.replace(/\D|^0/g,'')" v-model="dialysisPrescription.puncture_needle_count"
  935. ></el-input>
  936. </el-form-item>
  937. </el-col>
  938. <el-col :span="8" v-if="isShows('促红素')">
  939. <el-form-item label="促红素:" prop="epo" :rules="isCheckmust('促红素')">
  940. <el-select
  941. v-model="dialysisPrescription.epo"
  942. placeholder="请选择"
  943. style="width:100%;"
  944. >
  945. <el-option :key="0" label="请选择" :value="0"></el-option>
  946. <el-option
  947. v-for="(item, index) in epoOptions"
  948. :label="item.name"
  949. :key="index + 't'"
  950. :value="item.name"
  951. ></el-option>
  952. </el-select>
  953. </el-form-item>
  954. </el-col>
  955. <el-col :span="8" v-if="isShows('促红素支数')">
  956. <el-form-item label="促红素支数" prop="epo_count" :rules="isCheckmust('促红素支数')">
  957. <el-input oninput="value=value.replace(/\D|^0/g,'')" v-model="dialysisPrescription.epo_count"></el-input>
  958. </el-form-item>
  959. </el-col>
  960. <el-col :span="8" v-if="isShows('最大超滤率')">
  961. <el-form-item label="最大超滤率(ml/h)" prop="max_ultrafiltration_rate" :rules="isCheckmust('最大超滤率')">
  962. <el-input oninput="value=value.replace(/\D|^0/g,'')" v-model="dialysisPrescription.max_ultrafiltration_rate"></el-input>
  963. </el-form-item>
  964. </el-col>
  965. <el-col :span="8" v-if="isShows('处方医生')" >
  966. <el-form-item label="处方医生" prop="admin_user_id" :rules="isCheckmust('处方医生')">
  967. <el-select v-model="dialysisPrescription.admin_user_id" placeholder="请选择" style="width:100%;">
  968. <el-option v-for="(admin, index) in adminRoles" :key="index" :value="admin.id" :label="admin.name"></el-option>
  969. </el-select>
  970. </el-form-item>
  971. </el-col>
  972. </el-row>
  973. <el-row :gutter="20">
  974. <el-col :span="24" v-if="isShows('透析备注') && (dialysisPrescription.mode_id == 2 || dialysisPrescription.mode_id == 3 || dialysisPrescription.mode_id == 4)">
  975. <el-form-item label="透析备注:" prop="value" :rules="isCheckmust('透析备注')">
  976. <el-select @change="dialysisAfterTeachSelectChange" v-model="value">
  977. <el-option
  978. v-for="(item, index) in educationList"
  979. :label="item.text"
  980. :value="item.value"
  981. :key="index"
  982. ></el-option>
  983. </el-select>
  984. </el-form-item>
  985. </el-col>
  986. </el-row>
  987. <el-row :gutter="20">
  988. <el-col v-if="isShows('透析备注') && (dialysisPrescription.mode_id == 2 || dialysisPrescription.mode_id == 3 || dialysisPrescription.mode_id == 4)">
  989. <el-form-item prop="dialysis_remark" :rules="isCheckmust('透析备注')">
  990. <el-input
  991. type="textarea"
  992. v-model="dialysisPrescription.dialysis_remark"
  993. :rows="4"
  994. ></el-input>
  995. </el-form-item>
  996. </el-col>
  997. </el-row>
  998. <el-row :gutter="20">
  999. <el-col :span="8" v-if="isShows('处方钠')">
  1000. <el-form-item label="处方钠: " prop="prescription_sodium" :rules="isCheckmust('处方钠')">
  1001. <el-input
  1002. v-model="dialysisPrescription.prescription_sodium"
  1003. :rows="5"
  1004. ></el-input>
  1005. </el-form-item>
  1006. </el-col>
  1007. <el-col :span="8" v-if="isShows('开始钠')">
  1008. <el-form-item label="开始钠: " prop="start_sodium" :rules="isCheckmust('开始钠')">
  1009. <el-input
  1010. v-model="dialysisPrescription.start_sodium"
  1011. :rows="5"
  1012. ></el-input>
  1013. </el-form-item>
  1014. </el-col>
  1015. <el-col :span="8" v-if="isShows('钠曲线')">
  1016. <el-form-item label="钠曲线: " prop="sodium_curve" :rules="isCheckmust('钠曲线')">
  1017. <el-input
  1018. v-model="dialysisPrescription.sodium_curve"
  1019. :rows="5"
  1020. ></el-input>
  1021. </el-form-item>
  1022. </el-col>
  1023. </el-row>
  1024. <el-row>
  1025. <el-col :span="8" v-if="isShows('透析液流速')">
  1026. <el-form-item label="透析液流速(ml/h):" prop="dialysis_fluid_flow" :rules="isCheckmust('透析液流速')">
  1027. <el-input
  1028. v-model="dialysisPrescription.dialysis_fluid_flow"
  1029. :rows="5"
  1030. ></el-input>
  1031. </el-form-item>
  1032. </el-col>
  1033. <el-col :span="8" v-if="isShows('碳酸氢钠流速')">
  1034. <el-form-item label="碳酸氢钠流速(ml/h):" prop="sodium_bicarbonate_flow" :rules="isCheckmust('碳酸氢钠流速')">
  1035. <el-input
  1036. v-model="dialysisPrescription.sodium_bicarbonate_flow"
  1037. :rows="5"
  1038. ></el-input>
  1039. </el-form-item>
  1040. </el-col>
  1041. </el-row>
  1042. <el-row>
  1043. <el-col :span="8">
  1044. <el-form-item label="Ns冲洗量(ml):" :prop="isName('冲洗量')" v-if="isShows('冲洗量') && dialysisPrescription.anticoagulant == 1">
  1045. <el-input v-model="dialysisPrescription.warsh_count"></el-input>
  1046. </el-form-item>
  1047. </el-col>
  1048. <el-col :span="8">
  1049. <el-form-item label="q(h):" :prop="isName('冲洗时间')" v-if="isShows('冲洗时间') && dialysisPrescription.anticoagulant == 1">
  1050. <el-input v-model="dialysisPrescription.washing_time"></el-input>
  1051. </el-form-item>
  1052. </el-col>
  1053. </el-row>
  1054. <el-row :gutter="20">
  1055. <el-col :span="24" v-if="isShows('病情处理')">
  1056. <el-form-item label="病情处理: " prop="treatment_remark" :rules="isCheckmust('病情处理')">
  1057. <el-input
  1058. type="textarea"
  1059. v-model="dialysisPrescription.treatment_remark"
  1060. :rows="5"
  1061. ></el-input>
  1062. </el-form-item>
  1063. </el-col>
  1064. </el-row>
  1065. <el-row :gutter="20">
  1066. <el-col :span="24">
  1067. <el-form-item label="备注: " prop="remark" :rules="isCheckmust('备注')">
  1068. <el-input
  1069. type="textarea"
  1070. v-model="dialysisPrescription.remark"
  1071. :rows="5"
  1072. ></el-input>
  1073. </el-form-item>
  1074. </el-col>
  1075. </el-row>
  1076. </el-form>
  1077. <span slot="footer" class="dialog-footer">
  1078. <el-button @click="handleCancle">取 消</el-button>
  1079. <!-- <el-button type="primary" @click="handleCommit" v-if="isPermission()">保 存</el-button> -->
  1080. <el-button type="primary" @click="handleCommit('dialysisPrescription')" :loading="isLoading">保 存</el-button>
  1081. <el-button type="primary" @click="handleSolution('dialysisPrescription')" :loading="isLoading"
  1082. >保存为长期处方</el-button
  1083. >
  1084. </span>
  1085. </el-dialog>
  1086. <!-- 点击保存长期 -->
  1087. <el-dialog
  1088. title="长期医嘱推送"
  1089. :visible.sync="isShowRemindAdvice"
  1090. width="1010px"
  1091. :modal-append-to-body="false"
  1092. :append-to-body="true"
  1093. >
  1094. <div style="display:flex;align-items:center;">
  1095. <span style="font-weight: bold;color: #409eff;width:80px;">开始时间:</span>
  1096. <el-date-picker
  1097. type="datetime"
  1098. format="yyyy-MM-dd HH:mm"
  1099. value-format="yyyy-MM-dd HH:mm"
  1100. placeholder="选择时间"
  1101. v-model="start_time"
  1102. ></el-date-picker>
  1103. <!--<span style="display: inline-block;border: 1px solid #ccc;padding: 10px 20px;border-radius: 5px;" @click="changeStartTime">{{ advice_start_time }}</span>-->
  1104. </div>
  1105. <el-checkbox-group v-model="checkedCities">
  1106. <el-checkbox
  1107. style="display: flex;align-items: center"
  1108. v-for="(advice, index) in targetAdvices"
  1109. :label="advice.id"
  1110. :key="index+'q'"
  1111. :value="advice.id"
  1112. :name="advice.id"
  1113. >
  1114. <div style="padding-top: 10px;padding-left: 10px">
  1115. 开嘱医生&nbsp;{{ getDoctorName(advice.advice_doctor) }}
  1116. </div>
  1117. <br/>
  1118. <div style="padding-left: 10px">
  1119. 开嘱时间&nbsp;{{ getTime(advice.created_time) }}
  1120. </div>
  1121. <br/>
  1122. <div style="padding-bottom: 10px;padding-left: 10px">
  1123. 医嘱内容&nbsp;{{ getContent(advice) }}
  1124. </div>
  1125. <div
  1126. style="padding-bottom: 10px;padding-left: 10px"
  1127. v-if="advice.frequency_type == 1"
  1128. >
  1129. 推送频率 每次必推
  1130. </div>
  1131. <div
  1132. style="padding-bottom: 10px;padding-left: 10px"
  1133. v-if="advice.frequency_type == 2"
  1134. >
  1135. 推送频率&nbsp;{{ advice.day_count }}天/次
  1136. </div>
  1137. <div
  1138. style="padding-bottom: 10px;padding-left: 10px"
  1139. v-if="advice.frequency_type == 3"
  1140. >
  1141. 推送频率&nbsp;每周{{ advice.week_day }}
  1142. </div>
  1143. </el-checkbox>
  1144. </el-checkbox-group>
  1145. <span slot="footer" class="dialog-footer">
  1146. <el-button @click="handleAdviceCancle">取 消</el-button>
  1147. <el-button type="primary" @click="handleAdviceCommit" :loading="isLoading">保 存</el-button>
  1148. </span>
  1149. </el-dialog>
  1150. <el-dialog
  1151. :title="patient.name"
  1152. :visible.sync="msgtip_visibility"
  1153. :close-on-click-modal="false"
  1154. :close-on-press-escape="false"
  1155. :show-close="false"
  1156. width="30%"
  1157. >
  1158. <div class="newLine">
  1159. <span>本次透析日期</span>
  1160. <span>{{ dialysis_date }}</span>
  1161. </div>
  1162. <div class="newLine">
  1163. <span>透前称重(kg)</span>
  1164. <span>{{ getBeforeWeight(predialysis) }}</span>
  1165. </div>
  1166. <div class="newLine">
  1167. <span>干体重(kg)</span>
  1168. <span>{{ getDryWeight() }}</span>
  1169. </div>
  1170. <div class="newLine">
  1171. <span>衣物重(kg)</span>
  1172. <span>{{ predialysis.additional_weight }}</span>
  1173. </div>
  1174. <div class="newLine">
  1175. <span>体重增加(kg)</span>
  1176. <span>{{ add_weight }}</span>
  1177. </div>
  1178. <div class="newLine">
  1179. <span>透后称重(kg)</span>
  1180. <span>{{ getAfterWeight(record) }}</span>
  1181. </div>
  1182. <div class="newLine">
  1183. <span>体重减少(kg)</span>
  1184. <span>{{ record.weight_loss }}</span>
  1185. </div>
  1186. <div class="newLine">
  1187. <span>上次透后称重(kg)</span>
  1188. <span>{{ getLastAfterWeight(last_record) }}</span>
  1189. </div>
  1190. <span slot="footer" class="dialog-footer">
  1191. <el-button @click="cancleMsg()">取 消</el-button>
  1192. <el-button type="primary" @click="cancleMsg()">确 定</el-button>
  1193. </span>
  1194. </el-dialog>
  1195. <multi-select-box
  1196. :propsForm="InnerDialogProps"
  1197. v-on:dialog-comfirm="innerDialogComfirm"
  1198. v-on:dialog-cancle="innerDialogCancle"
  1199. ></multi-select-box>
  1200. <el-dialog
  1201. title="提示"
  1202. :visible.sync="infoDialogVisible"
  1203. width="30%">
  1204. <span>
  1205. <el-form>
  1206. <el-row>
  1207. <span>申请日期:</span>
  1208. <span>
  1209. <el-date-picker
  1210. type="datetime"
  1211. format="yyyy-MM-dd HH:mm"
  1212. value-format="yyyy-MM-dd HH:mm"
  1213. placeholder="选择时间"
  1214. v-model="selected_date"
  1215. ></el-date-picker>
  1216. </span>
  1217. </el-row>
  1218. <el-row>
  1219. <span>备注:</span>
  1220. <span>
  1221. <el-input v-model="remark" style="width:200px"></el-input>
  1222. </span>
  1223. </el-row>
  1224. </el-form>
  1225. </span>
  1226. <span slot="footer" class="dialog-footer">
  1227. <el-button @click="infoDialogVisible = false">取 消</el-button>
  1228. <el-button type="primary" @click="saveInformation">确 定</el-button>
  1229. </span>
  1230. </el-dialog>
  1231. </div>
  1232. </template>
  1233. <script>
  1234. import { CreateGroupAdvice, GetSolution, postPrescription, postSoulution,saveInformation } from '@/api/dialysis'
  1235. import { getDataConfig } from '@/utils/data'
  1236. import { calculateAnticoagulantZL, uParseTime,replacementFlow } from '@/utils/tools'
  1237. import store from '@/store'
  1238. import MsgTip from './MsgTip'
  1239. import request from '@/utils/request'
  1240. import multiSelectBox from './MultiSelectBox'
  1241. const moment = require('moment')
  1242. export default {
  1243. name: 'dialysisPrescriptionDialog',
  1244. components: { MsgTip, multiSelectBox },
  1245. props: {
  1246. mode_id: {
  1247. type: Number
  1248. },
  1249. schedual: {
  1250. type: Object
  1251. },
  1252. is_open: {
  1253. type: Number,
  1254. default: () => {
  1255. return 0
  1256. }
  1257. },
  1258. waitUploadAdvices: {
  1259. type: Array,
  1260. default: () => {
  1261. return []
  1262. }
  1263. },
  1264. targetAdvices: {
  1265. type: Array,
  1266. default: () => {
  1267. return []
  1268. }
  1269. },
  1270. admin_users: {
  1271. type: Array,
  1272. default: () => {
  1273. return []
  1274. }
  1275. },
  1276. niprocart_info: {
  1277. type: Array,
  1278. default: () => {
  1279. return []
  1280. }
  1281. },
  1282. jms_info: {
  1283. type: Array,
  1284. default: () => {
  1285. return []
  1286. }
  1287. },
  1288. fistula_needle_set_info: {
  1289. type: Array,
  1290. default: () => {
  1291. return []
  1292. }
  1293. },
  1294. fistula_needle_set_16_info: {
  1295. type: Array,
  1296. default: () => {
  1297. return []
  1298. }
  1299. },
  1300. hemoperfusion_info: {
  1301. type: Array,
  1302. default: () => {
  1303. return []
  1304. }
  1305. },
  1306. dialyser_sterilised_info: {
  1307. type: Array,
  1308. default: () => {
  1309. return []
  1310. }
  1311. },
  1312. filtryzer_info: {
  1313. type: Array,
  1314. default: () => {
  1315. return []
  1316. }
  1317. },
  1318. dialyzers_info: {
  1319. type: Array,
  1320. default: () => {
  1321. return []
  1322. }
  1323. },
  1324. injector_info: {
  1325. type: Array,
  1326. default: () => {
  1327. return []
  1328. }
  1329. },
  1330. bloodlines_info: {
  1331. type: Array,
  1332. default: () => {
  1333. return []
  1334. }
  1335. },
  1336. tubingHemodialysis_info: {
  1337. type: Array,
  1338. default: () => {
  1339. return []
  1340. }
  1341. },
  1342. safe_package_info: {
  1343. type: Array,
  1344. default: () => {
  1345. return []
  1346. }
  1347. },
  1348. aliquid_info: {
  1349. type: Array,
  1350. default: () => {
  1351. return []
  1352. }
  1353. },
  1354. config: {
  1355. type: Object,
  1356. default: () => {
  1357. return { id: 0 }
  1358. }
  1359. },
  1360. prescription: {
  1361. // 透析处方
  1362. type: Object,
  1363. default: () => {
  1364. return { id: 0 }
  1365. }
  1366. },
  1367. solution: {
  1368. // 长期处方
  1369. type: Object,
  1370. default: () => {
  1371. return { id: 0 }
  1372. }
  1373. },
  1374. dialysis_order: {
  1375. // 透析记录
  1376. type: Object,
  1377. default: () => {
  1378. return { id: 0 }
  1379. }
  1380. },
  1381. patient: {
  1382. // 患者信息
  1383. type: Object,
  1384. default: () => {
  1385. return { id: 0 }
  1386. }
  1387. },
  1388. devices: {
  1389. type: Array,
  1390. default: function() {
  1391. return new Array()
  1392. }
  1393. },
  1394. predialysis: {
  1395. type: Object,
  1396. default: () => {
  1397. return { id: 0 }
  1398. }
  1399. },
  1400. last_predialysis: {
  1401. type: Object,
  1402. default: () => {
  1403. return { id: 0 }
  1404. }
  1405. },
  1406. record: {
  1407. type: Object,
  1408. default: () => {
  1409. return { id: 0 }
  1410. }
  1411. },
  1412. last_record: {
  1413. type: Object,
  1414. default: () => {
  1415. return { id: 0 }
  1416. }
  1417. },
  1418. dry_weight: {
  1419. type: Object,
  1420. default: () => {
  1421. return { id: 0 }
  1422. }
  1423. },
  1424. last_prescription: {
  1425. type: Object,
  1426. default: () => {
  1427. return { id: 0 }
  1428. }
  1429. },
  1430. scheudle_mode: Number,
  1431. stockType: {
  1432. type: Array,
  1433. default: () => {
  1434. return []
  1435. }
  1436. },
  1437. lastAssessment: {
  1438. type: Object,
  1439. default: () => {
  1440. return { id: 0 }
  1441. }
  1442. },
  1443. admins: {
  1444. type: Array
  1445. },
  1446. },
  1447. computed: {
  1448. dialysis_date: function() {
  1449. if (this.$route.query.date) {
  1450. return uParseTime(this.$route.query.date, '{y}/{m}/{d}')
  1451. } else {
  1452. return this.record_date
  1453. }
  1454. }
  1455. },
  1456. data() {
  1457. return {
  1458. InnerDialogProps: {
  1459. values: [],
  1460. visibility: false,
  1461. isShowTextArea: true,
  1462. customContent: '',
  1463. titles: '',
  1464. type: '' // 不同弹框类型,用来匹配数据
  1465. },
  1466. advice_start_time: '',
  1467. showTxt: '',
  1468. start_time: '',
  1469. hasPermission: true,
  1470. zhiShow: false,
  1471. totalShow: false,
  1472. huShow: false,
  1473. showName: '',
  1474. isShowRemindAdvice: false,
  1475. checkedCities: [],
  1476. isVisibility: false,
  1477. isShowTime: false,
  1478. isClose: false,
  1479. isShow: false,
  1480. record_date: '',
  1481. time: '',
  1482. treatment_mode: [],
  1483. timeValue: '',
  1484. deviceList: [],
  1485. replacement_ways: [],
  1486. anticoagulantsConfit: {},
  1487. dialysate_formulation_options: [],
  1488. add_weight: 0,
  1489. body_fluid_option: [],
  1490. special_medicine_option: [],
  1491. displace_liqui_part_option: [],
  1492. blood_access_option: [],
  1493. is_pre: 0,
  1494. msgtip_visibility: false,
  1495. startVisibility:false,
  1496. dialysisPrescription: {
  1497. replacement_total: '',
  1498. mode_id: '',
  1499. dialysis_duration: '',
  1500. dialysis_duration_hour: '',
  1501. dialysis_duration_minute: '0',
  1502. mode_name: '',
  1503. dialyzer: '',
  1504. perfusion_apparatus: '',
  1505. blood_flow_volume: '',
  1506. dewater_amount: '',
  1507. displace_liqui: '',
  1508. replacement_way: '',
  1509. anticoagulant: '',
  1510. anticoagulant_shouji: '',
  1511. anticoagulant_weichi: '',
  1512. anticoagulant_zongliang: '',
  1513. anticoagulant_gaimingcheng: '',
  1514. anticoagulant_gaijiliang: '',
  1515. kalium: '',
  1516. sodium: '',
  1517. calcium: '',
  1518. bicarbonate: '',
  1519. glucose: '',
  1520. dry_weight: '',
  1521. dialysate_flow: '',
  1522. dialysate_temperature: '',
  1523. target_ultrafiltration: '',
  1524. dialysate_formulation: '',
  1525. conductivity: '',
  1526. doctor: '',
  1527. remark: '',
  1528. dialyzer_perfusion_apparatus: '',
  1529. body_fluid: '',
  1530. body_fluid_other: '',
  1531. special_medicine: '',
  1532. special_medicine_other: '',
  1533. displace_liqui_part: '',
  1534. displace_liqui_value: '',
  1535. ultrafiltration: '',
  1536. blood_access: '',
  1537. niprocart: '',
  1538. jms: '',
  1539. fistula_needle_set: '',
  1540. fistula_needle_set_16: '',
  1541. hemoperfusion: '',
  1542. dialyser_sterilised: '',
  1543. filtryzer: '',
  1544. target_ktv: '',
  1545. dialyzers: '',
  1546. injector: '',
  1547. bloodlines: '',
  1548. tubing_hemodialysis: '',
  1549. package: '',
  1550. a_liquid: '',
  1551. no_anticoagulant_shouji: '0',
  1552. no_anticoagulant_weichi: '0',
  1553. no_anticoagulant_zongliang: '0',
  1554. creater: 0,
  1555. pre_impulse: 0, //预冲量
  1556. anticoagulant_stop_time_hour: '',
  1557. anticoagulant_stop_time_min: '',
  1558. push_the_protamine: '',//下机前推注鱼精蛋白
  1559. heparin_sodium: '', //肝素钠
  1560. nucleoprotamine: '',//鱼精蛋白
  1561. no_heparin_remarks: '',
  1562. blood: '',
  1563. dialysis_dialyszers: '',
  1564. dialysis_irrigation: '',
  1565. irrigation: '',
  1566. antioxidant_commodity_name: '',
  1567. displace_speed: '',
  1568. illness: '',
  1569. amylaceum: '',
  1570. single_time: '',
  1571. single_water: '',
  1572. replacement_flow: '',
  1573. plasma_separator: '',
  1574. bilirubin_adsorption_column: '',
  1575. oxygen_uptake: '',
  1576. oxygen_flow: '',
  1577. oxygen_time: '',
  1578. hemodialysis_pipelines: '',
  1579. hemodialysis_pipelines_count: '',
  1580. puncture_needle: '',
  1581. puncture_needle_count: '',
  1582. epo: '',
  1583. epo_count: '',
  1584. max_ultrafiltration_rate:'',
  1585. hemodialysisPipelinesOptions: [],
  1586. punctureNeedleOptions: [],
  1587. epoOptions: [],
  1588. impulse:0,
  1589. admin_user_id:"",
  1590. drhy_water:"",
  1591. is_water:0,
  1592. dry_water_hour:"",
  1593. water_machine:"否",
  1594. add_amount:"",
  1595. reduce_amount:"",
  1596. dialysis_remark:"",
  1597. prescribing_number:"",
  1598. treatment_remark:"",
  1599. prescription_sodium:"",
  1600. start_sodium:"",
  1601. sodium_curve:"",
  1602. dialysis_fluid_flow:"",
  1603. sodium_bicarbonate_flow:"",
  1604. prescription_water:"",
  1605. dialysis_strainer:"",
  1606. chaptalization:"",
  1607. warsh_count:"",
  1608. washing_time:"",
  1609. blood_access_part_id:"",
  1610. anticoagulant_weichi_hour:""
  1611. },
  1612. anticoagulant: {
  1613. id: 0,
  1614. name: '',
  1615. type: 1,
  1616. shouji: 1,
  1617. weichi: 1,
  1618. zongliang: 1,
  1619. gaimingcheng: -1,
  1620. gaijiliang: -1,
  1621. shouji_unit: 'mg',
  1622. weichi_unit: 'mg/h',
  1623. zongliang_unit: 'mg',
  1624. gaimingcheng_unit: '',
  1625. gaijiliang_unit: ''
  1626. },
  1627. doctorAdvices: [],
  1628. dialyzerPerfusionApparatus: [],
  1629. bloods: [],
  1630. irrigations: [],
  1631. dialyzers: [],
  1632. dialysisStrainerList:[],
  1633. illnessList: [],
  1634. plasmaSeparatorList: [],
  1635. bilirubinAdsorptionColumn: [],
  1636. oxygenList: [
  1637. { id: 1, name: '需' },
  1638. { id: 2, name: '无' }
  1639. ],
  1640. oxygenShow: false,
  1641. hemodialysisPipelinesOptions: [],
  1642. epoOptions: [],
  1643. isLoading: false,
  1644. adminRoles:[{id:0,name:"请选择"}],
  1645. waterList:[
  1646. {id:0,name:"请选择"},
  1647. {id:1,name:"是"},
  1648. {id:2,name:"否"}
  1649. ],
  1650. machineList:[
  1651. {id:1,name:"是"},
  1652. {id:2,name:"否"}
  1653. ],
  1654. zongliang:"",
  1655. educationList:[],
  1656. value:"",
  1657. infoDialogVisible:false,
  1658. selected_date:"",
  1659. remark:"",
  1660. blood_access_part: [],
  1661. }
  1662. },
  1663. methods: {
  1664. changeOxygenList(val) {
  1665. if (val == 1) {
  1666. this.oxygenShow = true
  1667. }
  1668. if (val == 2) {
  1669. this.oxygenShow = false
  1670. this.prescription.oxygen_flow = ''
  1671. this.prescription.oxygen_time = ''
  1672. }
  1673. },
  1674. changeTime: function(val) {
  1675. this.advice_start_time = val
  1676. },
  1677. showInnerDialog: function(val) {
  1678. this.InnerDialogProps.visibility = true
  1679. switch (val) {
  1680. case '5': // 透析器/灌流器
  1681. this.InnerDialogProps.values = this.dialyzerPerfusionApparatus
  1682. this.InnerDialogProps.titles = '透析器/灌流器'
  1683. this.InnerDialogProps.type = 'dialyzer_perfusion_apparatus'
  1684. this.InnerDialogProps.selected = this.dialysisPrescription.dialyzer_perfusion_apparatus
  1685. this.InnerDialogProps.isShowTextArea = false
  1686. break
  1687. case '6': // 透析器/灌流器
  1688. this.InnerDialogProps.values = this.bloods
  1689. this.InnerDialogProps.titles = '抽血'
  1690. this.InnerDialogProps.type = 'blood'
  1691. this.InnerDialogProps.selected = this.dialysisPrescription.blood
  1692. this.InnerDialogProps.isShowTextArea = false
  1693. case '7': // 透析器
  1694. for (let i = 0; i < this.dialyzers.length; i++) {
  1695. this.dialyzers[i].name = this.dialyzers[i].specification_name
  1696. }
  1697. this.InnerDialogProps.values = this.dialyzers
  1698. this.InnerDialogProps.titles = '透析器'
  1699. this.InnerDialogProps.type = 'dialyzers'
  1700. this.InnerDialogProps.selected = this.dialysisPrescription.dialysis_dialyszers
  1701. this.InnerDialogProps.isShowTextArea = false
  1702. break
  1703. case '8':
  1704. for (let i = 0; i < this.irrigations.length; i++) {
  1705. this.irrigations[i].name = this.irrigations[i].specification_name
  1706. }
  1707. this.InnerDialogProps.values = this.irrigations
  1708. this.InnerDialogProps.titles = '灌流器'
  1709. this.InnerDialogProps.type = 'irrigations'
  1710. this.InnerDialogProps.selected = this.dialysisPrescription.dialysis_irrigation
  1711. this.InnerDialogProps.isShowTextArea = false
  1712. break
  1713. case '9': // 血浆灌流器
  1714. this.InnerDialogProps.values = this.plasmaSeparatorList
  1715. this.InnerDialogProps.titles = '血浆灌流器'
  1716. this.InnerDialogProps.type = 'plasma_separator'
  1717. this.InnerDialogProps.selected = this.dialysisPrescription.plasma_separator
  1718. this.InnerDialogProps.isShowTextArea = false
  1719. break
  1720. mu
  1721. case '10': // 胆红素吸附柱
  1722. this.InnerDialogProps.values = this.bilirubinAdsorptionColumn
  1723. this.InnerDialogProps.titles = '胆红素吸附柱'
  1724. this.InnerDialogProps.type = 'bilirubin_adsorption_column'
  1725. this.InnerDialogProps.selected = this.dialysisPrescription.bilirubin_adsorption_column
  1726. this.InnerDialogProps.isShowTextArea = false
  1727. break
  1728. case '11': //穿刺针
  1729. this.InnerDialogProps.values = this.punctureNeedleOptions
  1730. this.InnerDialogProps.titles = '穿刺针'
  1731. this.InnerDialogProps.type = 'puncture_needle'
  1732. this.InnerDialogProps.selected = this.dialysisPrescription.puncture_needle
  1733. this.InnerDialogProps.isShowTextArea = false
  1734. break
  1735. case '12':
  1736. for (let i = 0; i < this.dialysisStrainerList.length; i++) {
  1737. this.dialysisStrainerList[i].name = this.dialysisStrainerList[i].specification_name
  1738. }
  1739. this.InnerDialogProps.values = this.dialysisStrainerList
  1740. this.InnerDialogProps.titles = '滤过器'
  1741. this.InnerDialogProps.type = 'dialysis_strainer'
  1742. this.InnerDialogProps.selected = this.dialysisPrescription.dialysis_strainer
  1743. this.InnerDialogProps.isShowTextArea = false
  1744. break
  1745. case '17': // 水肿
  1746. this.InnerDialogProps.values = this.blood_access_part
  1747. this.InnerDialogProps.titles = '血管通路部位'
  1748. this.InnerDialogProps.type = 'blood_access_part_id'
  1749. this.InnerDialogProps.selected = this.dialysisPrescription.blood_access_part_id
  1750. this.InnerDialogProps.isShowTextArea = false
  1751. break
  1752. }
  1753. },
  1754. innerDialogComfirm: function(val) {
  1755. this.InnerDialogProps.visibility = false
  1756. switch (val.type) {
  1757. case 'dialyzer_perfusion_apparatus':
  1758. var newArr = []
  1759. if(this.dialyzerPerfusionApparatus!=null && this.dialyzerPerfusionApparatus.length>0){
  1760. for(let i=0;i<this.dialyzerPerfusionApparatus.length;i++){
  1761. for(let j=0;j<val.value.length;j++){
  1762. if(this.dialyzerPerfusionApparatus[i].name == val.value[j]){
  1763. newArr.push(val.value[j])
  1764. }
  1765. }
  1766. }
  1767. }
  1768. if(newArr!=null && newArr.length>0){
  1769. this.dialysisPrescription.dialyzer_perfusion_apparatus = newArr.join(',')
  1770. }else{
  1771. this.dialysisPrescription.dialyzer_perfusion_apparatus = ""
  1772. }
  1773. break
  1774. case 'blood':
  1775. this.dialysisPrescription.blood = val.value.join(',')
  1776. break
  1777. case 'dialyzers':
  1778. var newArr = []
  1779. if(this.dialyzers!=null && this.dialyzers.length >0){
  1780. for(let i=0;i<this.dialyzers.length;i++){
  1781. for(let j=0;j<val.value.length;j++){
  1782. if(this.dialyzers[i].specification_name == val.value[j]){
  1783. newArr.push(val.value[j])
  1784. }
  1785. }
  1786. }
  1787. }
  1788. if(newArr!=null && newArr.length >0){
  1789. this.dialysisPrescription.dialysis_dialyszers = newArr.join(',')
  1790. }else{
  1791. this.dialysisPrescription.dialysis_dialyszers = ""
  1792. }
  1793. break
  1794. case 'irrigations':
  1795. var newArr = []
  1796. if(this.irrigations!=null && this.irrigations.length >0){
  1797. for(let i=0;i<this.irrigations.length;i++){
  1798. for(let j=0;j<val.value.length;j++){
  1799. if(this.irrigations[i].specification_name == val.value[j]){
  1800. newArr.push(val.value[j])
  1801. }
  1802. }
  1803. }
  1804. }
  1805. if(newArr!=null && newArr.length>0){
  1806. this.dialysisPrescription.dialysis_irrigation = newArr.join(',')
  1807. }else{
  1808. this.dialysisPrescription.dialysis_irrigation = ""
  1809. }
  1810. break
  1811. case 'plasma_separator':
  1812. this.dialysisPrescription.plasma_separator = val.value.join(',')
  1813. break
  1814. case 'bilirubin_adsorption_column':
  1815. this.dialysisPrescription.bilirubin_adsorption_column = val.value.join(',')
  1816. break
  1817. case 'puncture_needle':
  1818. this.dialysisPrescription.puncture_needle = val.value.join(',')
  1819. break
  1820. case 'dialysis_strainer':
  1821. this.dialysisPrescription.dialysis_strainer = val.value.join(',')
  1822. break
  1823. case 'blood_access_part_id':
  1824. this.dialysisPrescription.blood_access_part_id = val.value.join(',')
  1825. break
  1826. }
  1827. },
  1828. innerDialogCancle: function() {
  1829. this.InnerDialogProps.visibility = false
  1830. },
  1831. getDryWeight() {
  1832. if (this.dry_weight != null && this.dry_weight.id > 0) {
  1833. return this.dry_weight.dry_weight
  1834. } else {
  1835. if (this.last_predialysis != null && this.last_predialysis.id > 0) {
  1836. return this.last_predialysis.dry_weight
  1837. } else {
  1838. return ''
  1839. }
  1840. }
  1841. },
  1842. getLastAfterWeight(record) {
  1843. if (record != null && record.id > 0) {
  1844. if (record.weight_after > 0) {
  1845. let additional_weight = 0
  1846. if (this.predialysis.additional_weight != undefined) {
  1847. additional_weight = this.predialysis.additional_weight
  1848. }
  1849. return parseFloat(record.weight_after - additional_weight).toFixed(1)
  1850. } else {
  1851. return ''
  1852. }
  1853. }
  1854. },
  1855. getBeforeWeight(predialysis) {
  1856. if (predialysis.id > 0) {
  1857. if (predialysis.weight_before > 0) {
  1858. return parseFloat(predialysis.weight_before - predialysis.additional_weight).toFixed(1)
  1859. } else {
  1860. return ''
  1861. }
  1862. }
  1863. },
  1864. getAfterWeight(record) {
  1865. if (record.id > 0) {
  1866. if (record.weight_after > 0) {
  1867. return parseFloat(record.weight_after - this.predialysis.additional_weight).toFixed(1)
  1868. } else {
  1869. return ''
  1870. }
  1871. }
  1872. },
  1873. setLastRecord: function(schedual, lastAssessmentAfterDislysis, lastPredialysisEvaluation, lastDialysisPrescribe, lastDryWeightDislysis, system_prescribe) {
  1874. this.treatment_mode = this.$store.getters.treatment_mode
  1875. // console.log("99999",this.treatment_mode)
  1876. this.perfusion_apparatus = getDataConfig(
  1877. 'hemodialysis',
  1878. 'perfusion_apparatus'
  1879. )
  1880. this.replacement_ways = getDataConfig('hemodialysis', 'replacement_ways')
  1881. this.dialysate_formulation_options = getDataConfig(
  1882. 'hemodialysis',
  1883. 'dialysate_formulation'
  1884. )
  1885. // this.anticoagulantsConfit = this.$store.getters.anticoagulants_confit
  1886. this.anticoagulantsConfit = this.$store.getters.anticoagulants_confit
  1887. console.log("抗凝剂",this.anticoagulantsConfit)
  1888. // for (let i = 0; i < anticoagulantsConfitOne.length; i++) {
  1889. // console.log('anticoagulantsConfitOne', anticoagulantsConfitOne[i].name)
  1890. // }
  1891. // var anticoagulantsConfit = getDataConfig('hemodialysis', 'anticoagulant')
  1892. // const arr = []
  1893. // anticoagulantsConfit.map((item, index) => {
  1894. // const objChild = { ...item }
  1895. // arr.push(objChild)
  1896. // })
  1897. // var arrthree = {}
  1898. // arrthree = { ...arr }
  1899. // console.log('arrthree', arrthree)
  1900. // const arrFour = []
  1901. // Object.keys(anticoagulantsConfitOne).map((item, index) => {
  1902. // arrFour.push(anticoagulantsConfitOne[item])
  1903. // // if (index != 2) {
  1904. // // arrFour.push(anticoagulantsConfitOne[item])
  1905. // // }
  1906. // })
  1907. // console.log("arrFour0-0000000000000wo",arrFour)
  1908. // this.anticoagulantsConfit = arrFour
  1909. this.dialysisList = this.devices
  1910. this.body_fluid_option = this.$store.getters.body_fluid
  1911. this.special_medicine_option = this.$store.getters.special_medicine
  1912. this.displace_liqui_part_option = this.$store.getters.displace_liqui
  1913. this.hemodialysisPipelinesOptions = getDataConfig('hemodialysis', 'hemodialysis_pipelines')
  1914. this.punctureNeedleOptions = getDataConfig('hemodialysis', 'puncture_needle')
  1915. this.epoOptions = getDataConfig('hemodialysis', 'epo')
  1916. // this.blood_access_option = this.$store.getters.blood_access_internal_fistula;
  1917. this.blood_access_option = getDataConfig(
  1918. 'hemodialysis',
  1919. 'vascular_access_desc'
  1920. )
  1921. // console.log('血管通路', this.blood_access_option)
  1922. this.dialyzerPerfusionApparatus = getDataConfig(
  1923. 'hemodialysis',
  1924. 'dialyzer_perfusion_apparatus'
  1925. )
  1926. // console.log('3333333', this.dialyzerPerfusionApparatus)
  1927. this.bloods = getDataConfig(
  1928. 'hemodialysis',
  1929. 'blood'
  1930. )
  1931. // dialyzerPerfusionApparatus.map(item => {
  1932. // item.name = item.name.toUpperCase()
  1933. // })
  1934. // //去重
  1935. // var arr = this.unique(dialyzerPerfusionApparatus)
  1936. // this.dialyzerPerfusionApparatus = arr
  1937. // console.log('灌流器', arr)
  1938. if (this.$route.query && this.$route.query.date) {
  1939. var date = this.$route.query && this.$route.query.date
  1940. this.record_date = uParseTime(date, '{y}-{m}-{d}')
  1941. } else {
  1942. var date = schedual.schedule_date
  1943. this.record_date = uParseTime(date, '{y}-{m}-{d}')
  1944. }
  1945. if (this.prescription != null && typeof this.prescription.id !== 'undefined' && this.prescription.id > 0) {
  1946. for (const key in this.prescription) {
  1947. this.dialysisPrescription[key] = this.prescription[key]
  1948. }
  1949. } else if (this.solution != null && typeof this.solution.id !== 'undefined' && this.solution.id > 0) {
  1950. for (const key in this.solution) {
  1951. if (key != 'target_ultrafiltration') {
  1952. this.dialysisPrescription[key] = this.solution[key]
  1953. }
  1954. }
  1955. } else if (lastDialysisPrescribe != null && typeof lastDialysisPrescribe.id !== 'undefined' && lastDialysisPrescribe.id > 0) {
  1956. for (const key in lastDialysisPrescribe) {
  1957. if (key != 'target_ultrafiltration') {
  1958. this.dialysisPrescription[key] = lastDialysisPrescribe[key]
  1959. }
  1960. }
  1961. } else if (system_prescribe != null && typeof system_prescribe.id !== 'undefined' && system_prescribe.id > 0) {
  1962. for (const key in system_prescribe) {
  1963. if (key != 'target_ultrafiltration') {
  1964. this.dialysisPrescription[key] = system_prescribe[key]
  1965. }
  1966. }
  1967. } else {
  1968. if (schedual.mode_id == 2 || schedual.mode_id == 5 || schedual.mode_id == 12) {
  1969. this.zhiShow = true
  1970. this.huShow = true
  1971. this.totalShow = true
  1972. } else {
  1973. this.zhiShow = false
  1974. this.huShow = false
  1975. this.totalShow = false
  1976. }
  1977. // this.dialysisPrescription.mode_id = schedual.mode_id
  1978. }
  1979. var thismode = parseInt(this.dialysisPrescription.anticoagulant)
  1980. if (isNaN(thismode) || thismode <= 0) {
  1981. return false
  1982. }
  1983. if (
  1984. typeof this.anticoagulantsConfit[thismode] === 'undefined' ||
  1985. this.anticoagulantsConfit[thismode] == null
  1986. ) {
  1987. return false
  1988. }
  1989. this.anticoagulant = this.$store.getters.anticoagulants_confit[thismode]
  1990. },
  1991. menuMsgTip: function() {
  1992. this.msgtip_visibility = false
  1993. this.isVisibility = true
  1994. },
  1995. handleAdviceCommit() {
  1996. let results = []
  1997. for (let i = 0; i < this.targetAdvices.length; i++) {
  1998. for (let a = 0; a < this.checkedCities.length; a++) {
  1999. if (this.targetAdvices[i].id == this.checkedCities[a]) {
  2000. results.push(this.targetAdvices[i])
  2001. }
  2002. }
  2003. }
  2004. var obj5 = {}
  2005. results = results.reduce((cur, next) => {
  2006. obj5[next.id] ? '' : (obj5[next.id] = true && cur.push(next))
  2007. return cur
  2008. }, [])
  2009. var date = new Date()
  2010. var hour = date.getHours() < 10 ? '0' + date.getHours() : date.getHours()
  2011. var minute = date.getMinutes() < 10 ? '0' + date.getMinutes() : date.getMinutes()
  2012. if (results.length > 0) {
  2013. if(!this.isLoading){
  2014. if (this.is_pre == 1) {
  2015. if (this.patient.id <= 0) {
  2016. this.$message.error('没有选择患者')
  2017. this.loading = false
  2018. return
  2019. }
  2020. var arr = this.dialysisPrescription
  2021. const ParamsQuery = arr
  2022. ParamsQuery['patient'] = this.patient.id
  2023. ParamsQuery['record_date'] = this.record_date
  2024. ParamsQuery['patient_id'] = this.$route.query.patient_id
  2025. if(this.$route.query.patient_id ==undefined){
  2026. ParamsQuery['patient_id'] = this.patient.id
  2027. }
  2028. if (this.prescription.creater <= 0) {
  2029. ParamsQuery['mode'] = '1'
  2030. } else {
  2031. ParamsQuery['mode'] = '2'
  2032. if (
  2033. this.$store.getters.xt_user.user.id !=
  2034. this.dialysisPrescription.creater
  2035. ) {
  2036. ParamsQuery['mode'] = '3'
  2037. }
  2038. }
  2039. this.isLoading = true
  2040. console.log("ParamsQuery233232322323322332232323",ParamsQuery)
  2041. postPrescription(ParamsQuery).then(response => {
  2042. if (response.data.state == 0) {
  2043. this.$message.error(response.data.msg)
  2044. if(response.data.code == 600000008){
  2045. this.infoDialogVisible = true
  2046. }
  2047. this.isLoading = false
  2048. return false
  2049. } else {
  2050. this.$notify({
  2051. title: '成功',
  2052. message: '提交成功',
  2053. type: 'success',
  2054. duration: 2000
  2055. })
  2056. var date = new Date()
  2057. const params = {
  2058. advices: results,
  2059. advice_date: this.start_time.split(' ')[0],
  2060. advice_doctor: results[0].advice_doctor,
  2061. advice_type: results[0].advice_type,
  2062. parent_id: this.patient_id,
  2063. start_time: this.start_time,
  2064. remark: ''
  2065. }
  2066. var patient_id = 0
  2067. if(this.$route.query.patient_id == undefined){
  2068. patient_id = this.patient.id
  2069. }else{
  2070. patient_id = this.$route.query.patient_id
  2071. }
  2072. CreateGroupAdvice(patient_id, 0, params).then(
  2073. rs => {
  2074. var resp = rs.data
  2075. if (resp.state == 1) {
  2076. this.doctorAdvices = resp.data.advices
  2077. this.$emit('advice')
  2078. this.isLoading = false
  2079. } else {
  2080. this.isLoading = false
  2081. if(resp.code == 600000008){
  2082. this.infoDialogVisible = true
  2083. }
  2084. }
  2085. }
  2086. )
  2087. const prescription_resp = response.data.data.prescription
  2088. var prescription = this.prescription
  2089. for (var index in prescription_resp) {
  2090. // prescription[index] = prescription_resp[index];
  2091. this.$set(prescription, index, prescription_resp[index])
  2092. }
  2093. this.hide()
  2094. }
  2095. })
  2096. } else if (this.is_pre == 2) {
  2097. if (this.patient.id <= 0) {
  2098. this.$message.error('没有选择患者')
  2099. this.loading = false
  2100. return
  2101. }
  2102. var arr = this.dialysisPrescription
  2103. const ParamsQuery = arr
  2104. ParamsQuery['patient'] = this.patient.id
  2105. ParamsQuery['record_date'] = this.record_date
  2106. ParamsQuery['mode'] = 1
  2107. postSoulution(ParamsQuery).then(response => {
  2108. if (response.data.state == 0) {
  2109. this.$message.error(response.data.msg)
  2110. if(response.data.code == 600000008){
  2111. this.infoDialogVisible = true
  2112. }
  2113. this.isLoading = false
  2114. return false
  2115. } else {
  2116. this.$notify({
  2117. title: '成功',
  2118. message: '提交成功',
  2119. type: 'success',
  2120. duration: 2000
  2121. })
  2122. // console.log(hour + ':' + minute)
  2123. var date = new Date()
  2124. var hour =
  2125. date.getHours() < 10 ? '0' + date.getHours() : date.getHours()
  2126. var minute =
  2127. date.getMinutes() < 10
  2128. ? '0' + date.getMinutes()
  2129. : date.getMinutes()
  2130. const params = {
  2131. advices: results,
  2132. advice_date: this.start_time.split(' ')[0],
  2133. advice_doctor: results[0].advice_doctor,
  2134. advice_type: results[0].advice_type,
  2135. parent_id: this.patient_id,
  2136. start_time: this.start_time,
  2137. remark: ''
  2138. }
  2139. var patient_id = 0
  2140. if(this.$route.query.patient_id == undefined){
  2141. patient_id = this.patient.id
  2142. }else{
  2143. patient_id = this.$route.query.patient_id
  2144. }
  2145. CreateGroupAdvice(patient_id, 0, params).then(
  2146. rs => {
  2147. var resp = rs.data
  2148. if (resp.state == 1) {
  2149. // this.doctorAdvices = resp.data.advices
  2150. this.$emit('advice')
  2151. this.isLoading = false
  2152. } else {
  2153. this.isLoading = false
  2154. if(resp.code == 600000008){
  2155. this.infoDialogVisible = true
  2156. }
  2157. }
  2158. }
  2159. )
  2160. const prescription_resp = response.data.data.prescription
  2161. const solution_resp = response.data.data.solution
  2162. var prescription = this.prescription
  2163. var solution = this.solution
  2164. for (var index in prescription_resp) {
  2165. // prescription[index] = prescription_resp[index];
  2166. this.$set(prescription, index, prescription_resp[index])
  2167. }
  2168. for (var index in solution_resp) {
  2169. // solution[index] = solution_resp[index];
  2170. this.$set(solution, index, solution_resp[index])
  2171. }
  2172. this.hide()
  2173. }
  2174. })
  2175. }
  2176. }
  2177. } else {
  2178. if (this.is_pre == 1) {
  2179. if (this.patient.id <= 0) {
  2180. this.$message.error('没有选择患者')
  2181. this.loading = false
  2182. return
  2183. }
  2184. var arr = this.dialysisPrescription
  2185. const ParamsQuery = arr
  2186. // console.log('医嘱推送4', ParamsQuery)
  2187. ParamsQuery['patient'] = this.patient.id
  2188. ParamsQuery['record_date'] = this.record_date
  2189. // console.log(this.prescription)
  2190. let mode = ''
  2191. if (this.prescription.creater <= 0) {
  2192. mode = 1
  2193. } else {
  2194. mode = 2
  2195. }
  2196. ParamsQuery['mode'] = mode
  2197. console.log("paramsquery",ParamsQuery)
  2198. postPrescription(ParamsQuery).then(response => {
  2199. if (response.data.state == 0) {
  2200. this.$message.error(response.data.msg)
  2201. if(response.data.code == 600000008){
  2202. this.infoDialogVisible = true
  2203. }
  2204. return false
  2205. } else {
  2206. this.$notify({
  2207. title: '成功',
  2208. message: '提交成功',
  2209. type: 'success',
  2210. duration: 2000
  2211. })
  2212. const prescription_resp = response.data.data.prescription
  2213. var prescription = this.prescription
  2214. for (var index in prescription_resp) {
  2215. // prescription[index] = prescription_resp[index];
  2216. this.$set(prescription, index, prescription_resp[index])
  2217. }
  2218. this.hide()
  2219. }
  2220. })
  2221. } else if (this.is_pre == 2) {
  2222. if (this.patient.id <= 0) {
  2223. this.$message.error('没有选择患者')
  2224. this.loading = false
  2225. return
  2226. }
  2227. var arr = this.dialysisPrescription
  2228. const ParamsQuery = arr
  2229. ParamsQuery['patient'] = this.patient.id
  2230. ParamsQuery['record_date'] = this.record_date
  2231. ParamsQuery['mode'] = 1
  2232. postSoulution(ParamsQuery).then(response => {
  2233. if (response.data.state == 0) {
  2234. this.$message.error(response.data.msg)
  2235. if(response.data.code == 600000008){
  2236. this.infoDialogVisible = true
  2237. }
  2238. return false
  2239. } else {
  2240. this.$notify({
  2241. title: '成功',
  2242. message: '提交成功',
  2243. type: 'success',
  2244. duration: 2000
  2245. })
  2246. const prescription_resp = response.data.data.prescription
  2247. const solution_resp = response.data.data.solution
  2248. var prescription = this.prescription
  2249. var solution = this.solution
  2250. for (var index in prescription_resp) {
  2251. // prescription[index] = prescription_resp[index];
  2252. this.$set(prescription, index, prescription_resp[index])
  2253. }
  2254. for (var index in solution_resp) {
  2255. // solution[index] = solution_resp[index];
  2256. this.$set(solution, index, solution_resp[index])
  2257. }
  2258. this.hide()
  2259. }
  2260. })
  2261. }
  2262. }
  2263. this.isShowRemindAdvice = false
  2264. this.isVisibility = true
  2265. },
  2266. handleAdviceCancle() {
  2267. this.isShowRemindAdvice = false
  2268. this.isVisibility = true
  2269. },
  2270. getTime(val) {
  2271. return uParseTime(val, '{y}-{m}-{d} {h}:{i}')
  2272. },
  2273. showOne(prescription,admins){
  2274. console.log("prescription",prescription)
  2275. if(prescription!=null && prescription.id == 0){
  2276. console.log("开始啊",admins)
  2277. this.dialysisPrescription.admin_user_id = this.$store.getters.xt_user.user.id
  2278. }else{
  2279. this.dialysisPrescription.admin_user_id = prescription.admin_user_id
  2280. }
  2281. this.adminRoles = []
  2282. if(admins.length > 0 ){
  2283. for(let i=0;i<admins.length;i++){
  2284. this.adminRoles.push(admins[i])
  2285. }
  2286. }
  2287. console.log("admin_user_+id2332323223332", this.$store.getters.xt_user.user.id)
  2288. },
  2289. show(pre, schedual, last, his_is_open,is_advice_open,admins) {
  2290. console.log("pres",pre)
  2291. console.log("schedual",schedual)
  2292. if (pre != undefined) {
  2293. this.dialysisPrescription.admin_user_id = pre.id == 0 ? this.$store.getters.xt_user.user.id : pre.admin_user_id
  2294. if (pre.oxygen_uptake == 1) {
  2295. this.oxygenShow = true
  2296. }
  2297. if (pre.oxygen_uptake == 2) {
  2298. this.oxygenShow = false
  2299. this.prescription.oxygen_flow = ''
  2300. this.prescription.oxygen_time = ''
  2301. }
  2302. }
  2303. if (his_is_open == 1) {
  2304. this.is_open = 0
  2305. }
  2306. if(is_advice_open == 1){
  2307. this.is_open = 1
  2308. }
  2309. if(this.$store.getters.xt_user.org.id == 10101){
  2310. if (this.predialysis.id > 0 && this.predialysis.created_time > 0) {
  2311. var date = new Date(this.predialysis.created_time * 1000)
  2312. var year = date.getFullYear()
  2313. var month = date.getMonth() + 1
  2314. var day = date.getDate()
  2315. var hours = date.getHours()
  2316. var minites = date.getMinutes()
  2317. if (month < 10) {
  2318. month = '0' + month
  2319. }
  2320. if (day < 10) {
  2321. day = '0' + day
  2322. }
  2323. if (hours < 10) {
  2324. hours = '0' + hours
  2325. }
  2326. if (minites < 10) {
  2327. minites = '0' + minites
  2328. }
  2329. this.start_time = year + '-' + month + '-' + day + ' ' + hours + ':' + minites
  2330. } else {
  2331. var date = new Date()
  2332. var year = date.getFullYear()
  2333. var month = date.getMonth() + 1
  2334. var day = date.getDate()
  2335. var hours = date.getHours()
  2336. var minites = date.getMinutes()
  2337. if (month < 10) {
  2338. month = '0' + month
  2339. }
  2340. if (day < 10) {
  2341. day = '0' + day
  2342. }
  2343. if (hours < 10) {
  2344. hours = '0' + hours
  2345. }
  2346. if (minites < 10) {
  2347. minites = '0' + minites
  2348. }
  2349. this.start_time = year + '-' + month + '-' + day + ' ' + hours + ':' + minites
  2350. }
  2351. }else{
  2352. var date = new Date()
  2353. var year = date.getFullYear()
  2354. var month = date.getMonth() + 1
  2355. var day = date.getDate()
  2356. var hours = date.getHours()
  2357. var minites = date.getMinutes()
  2358. if (month < 10) {
  2359. month = '0' + month
  2360. }
  2361. if (day < 10) {
  2362. day = '0' + day
  2363. }
  2364. if (hours < 10) {
  2365. hours = '0' + hours
  2366. }
  2367. if (minites < 10) {
  2368. minites = '0' + minites
  2369. }
  2370. 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 || this.$store.getters.xt_user.org.id == 9970) {
  2371. this.start_time = year + '-' + month + '-' + day + ' ' + hours + ':' + minites
  2372. }else if(this.$store.getters.xt_user.org.id == 9990 || this.$store.getters.xt_user.org.id==10432){
  2373. if (schedual.schedule_type == 1) {
  2374. this.start_time = year + '-' + month + '-' + day + ' ' + '06:00'
  2375. } else if (schedual.schedule_type == 2) {
  2376. this.start_time = year + '-' + month + '-' + day + ' ' + '11:00'
  2377. } else if (schedual.schedule_type == 3) {
  2378. this.start_time = year + '-' + month + '-' + day + ' ' + '18:00'
  2379. }
  2380. }else if(this.$store.getters.xt_user.org.id == 9671 ||this.$store.getters.xt_user.org.id == 10340){
  2381. if (schedual.schedule_type == 1) {
  2382. this.start_time = year + '-' + month + '-' + day + ' ' + '6:30'
  2383. } else if (schedual.schedule_type == 2) {
  2384. this.start_time = year + '-' + month + '-' + day + ' ' + '11:00'
  2385. } else if (schedual.schedule_type == 3) {
  2386. this.start_time = year + '-' + month + '-' + day + ' ' + '18:00'
  2387. }
  2388. }else if(this.$store.getters.xt_user.org.id == 10447){
  2389. if (schedual.schedule_type == 1) {
  2390. this.start_time = year + '-' + month + '-' + day + ' ' + '7:00'
  2391. } else if (schedual.schedule_type == 2) {
  2392. this.start_time = year + '-' + month + '-' + day + ' ' + '11:00'
  2393. } else if (schedual.schedule_type == 3) {
  2394. this.start_time = year + '-' + month + '-' + day + ' ' + '18:00'
  2395. }
  2396. }else if(this.$store.getters.xt_user.org.id == 10440){
  2397. if (schedual.schedule_type == 1) {
  2398. this.start_time = year + '-' + month + '-' + day + ' ' + '7:00'
  2399. } else if (schedual.schedule_type == 2) {
  2400. this.start_time = year + '-' + month + '-' + day + ' ' + '11:00'
  2401. } else if (schedual.schedule_type == 3) {
  2402. this.start_time = year + '-' + month + '-' + day + ' ' + '15:00'
  2403. }
  2404. }else if(this.$store.getters.xt_user.org.id == 9829){
  2405. if (schedual.schedule_type == 1) {
  2406. this.start_time = year + '-' + month + '-' + day + ' ' + '6:30'
  2407. } else if (schedual.schedule_type == 2) {
  2408. this.start_time = year + '-' + month + '-' + day + ' ' + '11:00'
  2409. } else if (schedual.schedule_type == 3) {
  2410. this.start_time = year + '-' + month + '-' + day + ' ' + '15:30'
  2411. }
  2412. }else if(this.$store.getters.xt_user.org.id == 10469){
  2413. if (schedual.schedule_type == 1) {
  2414. this.start_time = year + '-' + month + '-' + day + ' ' + '7:00'
  2415. } else if (schedual.schedule_type == 2) {
  2416. this.start_time = year + '-' + month + '-' + day + ' ' + '11:00'
  2417. } else if (schedual.schedule_type == 3) {
  2418. this.start_time = year + '-' + month + '-' + day + ' ' + '15:00'
  2419. }
  2420. }else if(this.$store.getters.xt_user.org.id == 10471){
  2421. if (schedual.schedule_type == 1) {
  2422. this.start_time = year + '-' + month + '-' + day + ' ' + '7:00'
  2423. } else if (schedual.schedule_type == 2) {
  2424. this.start_time = year + '-' + month + '-' + day + ' ' + '11:00'
  2425. } else if (schedual.schedule_type == 3) {
  2426. this.start_time = year + '-' + month + '-' + day + ' ' + '15:00'
  2427. }
  2428. }else if(this.$store.getters.xt_user.org.id == 10580){
  2429. if (schedual.schedule_type == 1) {
  2430. this.start_time = year + '-' + month + '-' + day + ' ' + '7:00'
  2431. } else if (schedual.schedule_type == 2) {
  2432. this.start_time = year + '-' + month + '-' + day + ' ' + '10:30'
  2433. } else if (schedual.schedule_type == 3) {
  2434. this.start_time = year + '-' + month + '-' + day + ' ' + '15:00'
  2435. }
  2436. }else if(this.$store.getters.xt_user.org.id == 10517){
  2437. if (schedual.schedule_type == 1) {
  2438. this.start_time = year + '-' + month + '-' + day + ' ' + '7:00'
  2439. } else if (schedual.schedule_type == 2) {
  2440. this.start_time = year + '-' + month + '-' + day + ' ' + '11:00'
  2441. } else if (schedual.schedule_type == 3) {
  2442. this.start_time = year + '-' + month + '-' + day + ' ' + '15:00'
  2443. }
  2444. }else if(this.$store.getters.xt_user.org.id == 10234){
  2445. if (schedual.schedule_type == 1) {
  2446. this.start_time = year + '-' + month + '-' + day + ' ' + '7:30'
  2447. } else if (schedual.schedule_type == 2) {
  2448. this.start_time = year + '-' + month + '-' + day + ' ' + '12:00'
  2449. } else if (schedual.schedule_type == 3) {
  2450. this.start_time = year + '-' + month + '-' + day + ' ' + '15:00'
  2451. }
  2452. }else if (this.$store.getters.xt_user.org.id == 10551){
  2453. var date = new Date()
  2454. var year = date.getFullYear()
  2455. var month = date.getMonth() + 1
  2456. var day = date.getDate()
  2457. var hours = date.getHours()
  2458. var minites = date.getMinutes()
  2459. if (month < 10) {
  2460. month = '0' + month
  2461. }
  2462. if (day < 10) {
  2463. day = '0' + day
  2464. }
  2465. if (hours < 10) {
  2466. hours = '0' + hours
  2467. }
  2468. if (minites < 10) {
  2469. minites = '0' + minites
  2470. }
  2471. this.start_time = year + '-' + month + '-' + day + ' ' + hours + ':' + minites
  2472. }else if (this.$store.getters.xt_user.org.id == 10597){
  2473. var date = new Date()
  2474. var year = date.getFullYear()
  2475. var month = date.getMonth() + 1
  2476. var day = date.getDate()
  2477. var hours = date.getHours()
  2478. var minites = date.getMinutes()
  2479. if (month < 10) {
  2480. month = '0' + month
  2481. }
  2482. if (day < 10) {
  2483. day = '0' + day
  2484. }
  2485. if (hours < 10) {
  2486. hours = '0' + hours
  2487. }
  2488. if (minites < 10) {
  2489. minites = '0' + minites
  2490. }
  2491. this.start_time = year + '-' + month + '-' + day + ' ' + hours + ':' + minites
  2492. }else if (this.$store.getters.xt_user.org.id == 10587){
  2493. var date = new Date()
  2494. var year = date.getFullYear()
  2495. var month = date.getMonth() + 1
  2496. var day = date.getDate()
  2497. var hours = date.getHours()
  2498. var minites = date.getMinutes()
  2499. if (month < 10) {
  2500. month = '0' + month
  2501. }
  2502. if (day < 10) {
  2503. day = '0' + day
  2504. }
  2505. if (hours < 10) {
  2506. hours = '0' + hours
  2507. }
  2508. if (minites < 10) {
  2509. minites = '0' + minites
  2510. }
  2511. this.start_time = year + '-' + month + '-' + day + ' ' + hours + ':' + minites
  2512. } else {
  2513. if (schedual.schedule_type == 1) {
  2514. this.start_time = year + '-' + month + '-' + day + ' ' + '07:00'
  2515. } else if (schedual.schedule_type == 2) {
  2516. this.start_time = year + '-' + month + '-' + day + ' ' + '12:00'
  2517. } else if (schedual.schedule_type == 3) {
  2518. this.start_time = year + '-' + month + '-' + day + ' ' + '18:00'
  2519. }
  2520. }
  2521. }
  2522. if (pre.anticoagulant == 3) {
  2523. this.dialysisPrescription.anticoagulant = '低分子肝素'
  2524. }
  2525. // 入口
  2526. var pre = pre
  2527. this.dialysisPrescription.mode_id = this.$route.query.mode_id ? this.$route.query.mode_id : this.mode_id
  2528. if (pre.id > 0) {
  2529. this.dialysisPrescription.mode_id = pre.mode_id
  2530. this.dialysisPrescription.water_machine = pre.water_machine
  2531. this.zongliang = this.dialysisPrescription.anticoagulant_zongliang
  2532. }
  2533. // console.log('this.dialysisPrescription.mode_id', this.dialysisPrescription.mode_id)
  2534. // console.log('this.schedual', schedual.mode_id)
  2535. 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) {
  2536. this.zhiShow = true
  2537. this.huShow = true
  2538. this.totalShow = true
  2539. } else if (
  2540. pre.mode_id == 1 ||
  2541. pre.mode_id == 3 ||
  2542. pre.mode_id == 4 ||
  2543. pre.mode_id == 6 ||
  2544. pre.mode_id == 7 ||
  2545. pre.mode_id == 8 ||
  2546. pre.mode_id == 9 ||
  2547. pre.mode_id == 10 ||
  2548. pre.mode_id == 11 ||
  2549. pre.mode_id == 13 ||
  2550. pre.mode_id == 14 ||
  2551. pre.mode_id == 19
  2552. ) {
  2553. this.zhiShow = false
  2554. this.huShow = false
  2555. this.totalShow = false
  2556. }
  2557. this.pre = pre
  2558. // console.log("pre1", pre);
  2559. this.getPermission()
  2560. let last_weight_after = 0
  2561. let weight_before = 0
  2562. if (this.last_record == null) {
  2563. last_weight_after = 0
  2564. } else {
  2565. last_weight_after = this.last_record.weight_after
  2566. }
  2567. console.log("last2323232323232332wode",this.predialysis)
  2568. console.log("lastwoowowow",last)
  2569. if(this.predialysis!=null && this.predialysis.id == 0){
  2570. if(this.$store.getters.xt_user.org.id == 9671 || this.$store.getters.xt_user.org.id == 9675 || this.$store.getters.xt_user.org.id == 10340 || this.$store.getters.xt_user.org.id == 10600){
  2571. this.dialysisPrescription.sodium = 138
  2572. this.dialysisPrescription.bicarbonate = 31.1
  2573. this.dialysisPrescription.dialysate_flow = 500
  2574. this.dialysisPrescription.dialysate_temperature = 36.5
  2575. this.dialysisPrescription.prescribing_number = 1
  2576. }
  2577. if(this.$store.getters.xt_user.org.id == 10447 || this.$store.getters.xt_user.org.id == 10600){
  2578. this.dialysisPrescription.dialysate_flow = 500
  2579. }
  2580. }
  2581. if (this.predialysis == null || this.predialysis.id == 0) {
  2582. if (last != null) {
  2583. this.dialysisPrescription.niprocart = last.niprocart
  2584. this.dialysisPrescription.jms = last.jms
  2585. this.dialysisPrescription.fistula_needle_set = last.fistula_needle_set
  2586. this.dialysisPrescription.fistula_needle_set_16 = last.fistula_needle_set_16
  2587. this.dialysisPrescription.hemoperfusion = last.hemoperfusion
  2588. this.dialysisPrescription.dialyser_sterilised = last.dialyser_sterilised
  2589. this.dialysisPrescription.filtryzer = last.filtryzer
  2590. this.dialysisPrescription.target_ktv = last.target_ktv
  2591. this.dialysisPrescription.dialyzers = last.dialyzers
  2592. this.dialysisPrescription.injector = last.injector
  2593. this.dialysisPrescription.bloodlines = last.bloodlines
  2594. this.dialysisPrescription.tubing_hemodialysis = last.tubing_hemodialysis
  2595. this.dialysisPrescription.package = last.package
  2596. this.dialysisPrescription.a_liquid = last.a_liquid
  2597. this.zongliang = last.anticoagulant_zongliang
  2598. this.dialysisPrescription.chaptalization = last.chaptalization
  2599. this.dialysisPrescription.blood_access_part_id = last.blood_access_part_id
  2600. if(this.$store.getters.xt_user.template_info.org_id!=10013 && this.$store.getters.xt_user.template_info.org_id!=10014){
  2601. this.remark = last.remark
  2602. }
  2603. weight_before = 0
  2604. }
  2605. } else {
  2606. weight_before = this.predialysis.weight_before
  2607. }
  2608. if (weight_before > 0 && last_weight_after > 0) {
  2609. this.add_weight = parseFloat(weight_before - last_weight_after).toFixed(
  2610. 2
  2611. )
  2612. // console.log('体重增加', this.add_weight)
  2613. }
  2614. this.isVisibility = true
  2615. this.checkedCities = []
  2616. var total_day = ""
  2617. if(moment().weekday() == 1){
  2618. total_day ="周一"
  2619. }
  2620. if(moment().weekday() == 2){
  2621. total_day ="周二"
  2622. }
  2623. if(moment().weekday() == 3){
  2624. total_day ="周三"
  2625. }
  2626. if(moment().weekday() == 4){
  2627. total_day ="周四"
  2628. }
  2629. if(moment().weekday() == 5){
  2630. total_day ="周五"
  2631. }
  2632. if(moment().weekday() == 6){
  2633. total_day ="周六"
  2634. }
  2635. if(moment().weekday() == 0){
  2636. total_day ="周日"
  2637. }
  2638. if(this.targetAdvices!=null && this.targetAdvices.length >0){
  2639. for (let i = 0; i < this.targetAdvices.length; i++) {
  2640. if(this.targetAdvices[i].week_day.indexOf(total_day)!=-1){
  2641. this.targetAdvices[i].isCheck = 1
  2642. }
  2643. if(this.targetAdvices[i].frequency_type == 1){
  2644. this.targetAdvices[i].isCheck = 1
  2645. }
  2646. }
  2647. }
  2648. for (let i = 0; i < this.targetAdvices.length; i++) {
  2649. if (this.targetAdvices[i].isCheck == 1) {
  2650. this.checkedCities.push(this.targetAdvices[i].id)
  2651. }
  2652. }
  2653. if(admins.length > 0 ){
  2654. for(let i=0;i<admins.length;i++){
  2655. this.adminRoles.push(admins[i])
  2656. }
  2657. }
  2658. console.log("---------",this.targetAdvices)
  2659. console.log("admin_user_+id2332323223332", this.adminRoles)
  2660. },
  2661. hide() {
  2662. this.isVisibility = false
  2663. },
  2664. changeThisAnticoagulant: function(val) {
  2665. console.log("val",val)
  2666. var thismode = val
  2667. if (isNaN(thismode) || thismode <= 0) {
  2668. return false
  2669. }
  2670. // if (val != 12 && val!=1) {
  2671. // this.anticoagulant = this.anticoagulantsConfit[thismode - 1]
  2672. // }
  2673. // if (val == 12 || val == 1) {
  2674. // this.anticoagulant = this.anticoagulantsConfit[thismode - 2]
  2675. // console.log("抗凝剂",this.anticoagulant)
  2676. // }
  2677. if (
  2678. typeof this.anticoagulantsConfit[thismode] === 'undefined' ||
  2679. this.anticoagulantsConfit[thismode] == null
  2680. ) {
  2681. return false
  2682. }
  2683. this.anticoagulant = this.anticoagulantsConfit[thismode]
  2684. if ((this.$store.getters.xt_user.template_info.template_id == 13 || this.$store.getters.xt_user.template_info.template_id == 41 || this.$store.getters.xt_user.template_info.template_id == 6 || this.$store.getters.xt_user.template_info.template_id == 47) && val == 2) {
  2685. if(val == 2){
  2686. this.anticoagulant.shouji_unit = 'mg'
  2687. }else{
  2688. this.anticoagulant.shouji_unit = 'iu'
  2689. }
  2690. this.anticoagulant.weichi_unit = 'mg/h'
  2691. this.anticoagulant.zongliang_unit = 'mg'
  2692. }
  2693. if (this.$store.getters.xt_user.template_info.template_id == 27 && val == 4) {
  2694. this.anticoagulant.shouji_unit = 'ml'
  2695. this.anticoagulant.weichi_unit = 'ml'
  2696. this.anticoagulant.zongliang_unit = 'ml'
  2697. }
  2698. if(this.$store.getters.xt_user.template_info.template_id == 41 && this.$store.getters.xt_user.template_info.template_id == 6 && this.dialysisPrescription.anticoagulant == 2){
  2699. this.dialysisPrescription.anticoagulant_zongliang = ""
  2700. this.dialysisPrescription.anticoagulant_zongliang = parseInt(this.dialysisPrescription.anticoagulant_shouji) + parseInt(this.dialysisPrescription.anticoagulant_weichi)
  2701. }
  2702. },
  2703. handleCommit (formName) {
  2704. if(this.$store.getters.xt_user.template_info.org_id ==10579 ){
  2705. if(this.dialysisPrescription.target_ultrafiltration==0){
  2706. this.$message.error("目标超滤量不能为空")
  2707. return false
  2708. }
  2709. }
  2710. this.$refs[formName].validate((valid)=>{
  2711. if(valid){
  2712. if(!this.isLoading){
  2713. if (this.dialysisPrescription.anticoagulant == '低分子肝素') {
  2714. this.dialysisPrescription.anticoagulant = 3
  2715. }
  2716. if (this.dialysisPrescription.anticoagulant == 1) {
  2717. this.dialysisPrescription.anticoagulant_weichi = '0'
  2718. this.dialysisPrescription.anticoagulant_shouji = '0'
  2719. this.dialysisPrescription.anticoagulant_zongliang = '0'
  2720. }
  2721. // if (this.$store.getters.xt_user.template_info.template_id == 6) {
  2722. // if (this.dialysisPrescription.mode_id == 2) {
  2723. // if (
  2724. // this.dialysisPrescription.displace_liqui_part == 0 ||
  2725. // this.dialysisPrescription.displace_liqui_part == -2 ||
  2726. // this.dialysisPrescription.displace_liqui_value == 0 ||
  2727. // this.dialysisPrescription.displace_liqui_value == ''
  2728. // || this.dialysisPrescription.replacement_total == 0 ||
  2729. // this.dialysisPrescription.replacement_total == '' ||
  2730. // this.dialysisPrescription.displace_speed == 0 ||
  2731. // this.dialysisPrescription.displace_speed == ''
  2732. // ) {
  2733. // this.$message.error('HDF模式下置换液和置换液总量不能为空!')
  2734. // return
  2735. // }
  2736. // }
  2737. // }
  2738. if(this.dialysisPrescription.mode_id!=2 && this.dialysisPrescription.mode_id!=5 && this.dialysisPrescription.mode_id!=12){
  2739. this.dialysisPrescription.displace_liqui_part = 0
  2740. this.dialysisPrescription.displace_liqui_value = 0
  2741. this.dialysisPrescription.replacement_total = 0
  2742. this.dialysisPrescription.displace_speed = 0
  2743. console.log('this.dialysisPrescription.displace_liqui_part',this.dialysisPrescription.displace_liqui_part);
  2744. console.log('this.dialysisPrescription.replacement_total',this.dialysisPrescription.replacement_total);
  2745. }
  2746. this.is_pre = 1
  2747. if (this.prescription.id == 0) {
  2748. if (this.is_open == 0) {
  2749. if (this.patient.id <= 0) {
  2750. this.$message.error('没有选择患者')
  2751. this.loading = false
  2752. return
  2753. }
  2754. var arr = this.dialysisPrescription
  2755. const ParamsQuery = arr
  2756. // console.log('night', ParamsQuery)
  2757. ParamsQuery['patient'] = this.patient.id
  2758. ParamsQuery['record_date'] = this.record_date
  2759. ParamsQuery['mode'] = '1'
  2760. ParamsQuery['patient_id'] = this.patient.id
  2761. console.log('第一', ParamsQuery)
  2762. postPrescription(ParamsQuery).then(response => {
  2763. if (response.data.state == 0) {
  2764. this.$message.error(response.data.msg)
  2765. if(response.data.code == 600000008){
  2766. this.infoDialogVisible = true
  2767. }
  2768. return false
  2769. } else {
  2770. this.$notify({
  2771. title: '成功',
  2772. message: '提交成功',
  2773. type: 'success',
  2774. duration: 2000
  2775. })
  2776. const prescription_resp = response.data.data.prescription
  2777. var prescription = this.prescription
  2778. for (var index in prescription_resp) {
  2779. // prescription[index] = prescription_resp[index];
  2780. this.$set(prescription, index, prescription_resp[index])
  2781. }
  2782. this.hide()
  2783. }
  2784. })
  2785. } else if (this.is_open == 1) {
  2786. if (this.targetAdvices.length > 0) {
  2787. // 弹框推送提醒
  2788. this.isShowRemindAdvice = true
  2789. this.isVisibility = false
  2790. } else {
  2791. if (this.patient.id <= 0) {
  2792. this.$message.error('没有选择患者')
  2793. this.loading = false
  2794. return
  2795. }
  2796. var arr = this.dialysisPrescription
  2797. const ParamsQuery = arr
  2798. // console.log('ParamsQuerytwo', ParamsQuery)
  2799. ParamsQuery['patient'] = this.patient.id
  2800. ParamsQuery['record_date'] = this.record_date
  2801. ParamsQuery['mode'] = '1'
  2802. ParamsQuery['patient_id'] = this.patient.id
  2803. console.log('第二')
  2804. postPrescription(ParamsQuery).then(response => {
  2805. if (response.data.state == 0) {
  2806. this.$message.error(response.data.msg)
  2807. if(response.data.code == 600000008){
  2808. this.infoDialogVisible = true
  2809. }
  2810. return false
  2811. } else {
  2812. this.$notify({
  2813. title: '成功',
  2814. message: '提交成功',
  2815. type: 'success',
  2816. duration: 2000
  2817. })
  2818. const prescription_resp = response.data.data.prescription
  2819. var prescription = this.prescription
  2820. for (var index in prescription_resp) {
  2821. // prescription[index] = prescription_resp[index];
  2822. this.$set(prescription, index, prescription_resp[index])
  2823. }
  2824. this.hide()
  2825. }
  2826. })
  2827. }
  2828. } else if (this.is_open == 2) {
  2829. var date = new Date()
  2830. var hour =
  2831. date.getHours() < 10 ? '0' + date.getHours() : date.getHours()
  2832. var minute =
  2833. date.getMinutes() < 10
  2834. ? '0' + date.getMinutes()
  2835. : date.getMinutes()
  2836. if (this.waitUploadAdvices.length > 0) {
  2837. if (this.patient.id <= 0) {
  2838. this.$message.error('没有选择患者')
  2839. this.loading = false
  2840. return
  2841. }
  2842. var arr = this.dialysisPrescription
  2843. const ParamsQuery = arr
  2844. console.log('paramsquerythree', ParamsQuery)
  2845. ParamsQuery['patient'] = this.patient.id
  2846. ParamsQuery['record_date'] = this.record_date
  2847. ParamsQuery['mode'] = '1'
  2848. ParamsQuery['patient_id'] = this.patient.id
  2849. console.log('第三')
  2850. postPrescription(ParamsQuery).then(response => {
  2851. if (response.data.state == 0) {
  2852. this.$message.error(response.data.msg)
  2853. if(response.data.code == 600000008){
  2854. this.infoDialogVisible = true
  2855. }
  2856. return false
  2857. } else {
  2858. this.$notify({
  2859. title: '成功',
  2860. message: '提交成功',
  2861. type: 'success',
  2862. duration: 2000
  2863. })
  2864. const params = {
  2865. advices: this.waitUploadAdvices,
  2866. advice_date: uParseTime(
  2867. this.$route.query.date,
  2868. '{y}-{m}-{d}'
  2869. ),
  2870. advice_doctor: this.waitUploadAdvices[0].advice_doctor,
  2871. advice_type: this.waitUploadAdvices[0].advice_type,
  2872. parent_id: this.patient_id,
  2873. // start_time: uParseTime(this.$route.query.date, '{y}-{m}-{d}'),
  2874. start_time:
  2875. uParseTime(this.$route.query.date, '{y}-{m}-{d}') +
  2876. ' ' +
  2877. this.advice_start_time,
  2878. remark: ''
  2879. }
  2880. console.log('params--------', params)
  2881. CreateGroupAdvice(this.$route.query.patient_id, 0, params).then(
  2882. rs => {
  2883. var resp = rs.data
  2884. if (resp.state == 1) {
  2885. // this.doctorAdvices = resp.data.advices
  2886. this.$emit('advice')
  2887. } else {
  2888. if(resp.code == 600000008){
  2889. this.infoDialogVisible = true
  2890. }
  2891. }
  2892. }
  2893. )
  2894. const prescription_resp = response.data.data.prescription
  2895. var prescription = this.prescription
  2896. for (var index in prescription_resp) {
  2897. // prescription[index] = prescription_resp[index];
  2898. this.$set(prescription, index, prescription_resp[index])
  2899. }
  2900. this.hide()
  2901. }
  2902. })
  2903. } else {
  2904. if (this.patient.id <= 0) {
  2905. this.$message.error('没有选择患者')
  2906. this.loading = false
  2907. return
  2908. }
  2909. var arr = this.dialysisPrescription
  2910. const ParamsQuery = arr
  2911. // console.log('paramsqueryfour', ParamsQuery)
  2912. // console.log('创建者', this.prescription.creater)
  2913. // if (this.prescription.creater <= 0) {
  2914. // mode = 1;
  2915. // } else {
  2916. // mode = 2;
  2917. // }
  2918. ParamsQuery['patient'] = this.patient.id
  2919. ParamsQuery['record_date'] = this.record_date
  2920. // console.log(this.prescription);
  2921. console.log('第四')
  2922. ParamsQuery['patient_id'] = this.patient.id
  2923. postPrescription(ParamsQuery).then(response => {
  2924. if (response.data.state == 0) {
  2925. this.$message.error(response.data.msg)
  2926. if(response.data.code == 600000008){
  2927. this.infoDialogVisible = true
  2928. }
  2929. return false
  2930. } else {
  2931. this.$notify({
  2932. title: '成功',
  2933. message: '提交成功',
  2934. type: 'success',
  2935. duration: 2000
  2936. })
  2937. const prescription_resp = response.data.data.prescription
  2938. // console.log("aaaaaaa", prescription_resp);
  2939. var prescription = this.prescription
  2940. for (var index in prescription_resp) {
  2941. // prescription[index] = prescription_resp[index];
  2942. this.$set(prescription, index, prescription_resp[index])
  2943. }
  2944. this.hide()
  2945. }
  2946. })
  2947. }
  2948. }
  2949. } else {
  2950. if (this.prescription.creater == 0) {
  2951. if (this.is_open == 0) {
  2952. if (this.patient.id <= 0) {
  2953. this.$message.error('没有选择患者')
  2954. this.loading = false
  2955. return
  2956. }
  2957. var arr = this.dialysisPrescription
  2958. // console.log('arr', arr)
  2959. const ParamsQuery = arr
  2960. // console.log('paramsqueryfive', ParamsQuery)
  2961. ParamsQuery['patient'] = this.patient.id
  2962. ParamsQuery['record_date'] = this.record_date
  2963. ParamsQuery['mode'] = '1'
  2964. ParamsQuery['patient_id'] = this.patient.id
  2965. console.log('第五')
  2966. postPrescription(ParamsQuery).then(response => {
  2967. if (response.data.state == 0) {
  2968. this.$message.error(response.data.msg)
  2969. if(response.data.code == 600000008){
  2970. this.infoDialogVisible = true
  2971. }
  2972. return false
  2973. } else {
  2974. this.$notify({
  2975. title: '成功',
  2976. message: '提交成功',
  2977. type: 'success',
  2978. duration: 2000
  2979. })
  2980. const prescription_resp = response.data.data.prescription
  2981. var prescription = this.prescription
  2982. for (var index in prescription_resp) {
  2983. // prescription[index] = prescription_resp[index];
  2984. this.$set(prescription, index, prescription_resp[index])
  2985. }
  2986. this.hide()
  2987. }
  2988. })
  2989. } else if (this.is_open == 1) {
  2990. if (this.targetAdvices.length > 0) {
  2991. // 弹框推送提醒
  2992. this.isShowRemindAdvice = true
  2993. this.isVisibility = false
  2994. } else {
  2995. if (this.patient.id <= 0) {
  2996. this.$message.error('没有选择患者')
  2997. this.loading = false
  2998. return
  2999. }
  3000. var arr = this.dialysisPrescription
  3001. // console.log('arr', arr)
  3002. const ParamsQuery = arr
  3003. // console.log('ParamsQuerysix', ParamsQuery)
  3004. ParamsQuery['patient'] = this.patient.id
  3005. ParamsQuery['record_date'] = this.record_date
  3006. ParamsQuery['mode'] = '1'
  3007. console.log('第6')
  3008. ParamsQuery['patient_id'] = this.patient.id
  3009. postPrescription(ParamsQuery).then(response => {
  3010. if (response.data.state == 0) {
  3011. this.$message.error(response.data.msg)
  3012. if(response.data.code == 600000008){
  3013. this.infoDialogVisible = true
  3014. }
  3015. return false
  3016. } else {
  3017. this.$notify({
  3018. title: '成功',
  3019. message: '提交成功',
  3020. type: 'success',
  3021. duration: 2000
  3022. })
  3023. const prescription_resp = response.data.data.prescription
  3024. var prescription = this.prescription
  3025. for (var index in prescription_resp) {
  3026. // prescription[index] = prescription_resp[index];
  3027. this.$set(prescription, index, prescription_resp[index])
  3028. }
  3029. this.hide()
  3030. }
  3031. })
  3032. }
  3033. } else if (this.is_open == 2) {
  3034. var date = new Date()
  3035. var hour =
  3036. date.getHours() < 10 ? '0' + date.getHours() : date.getHours()
  3037. var minute =
  3038. date.getMinutes() < 10
  3039. ? '0' + date.getMinutes()
  3040. : date.getMinutes()
  3041. if (this.waitUploadAdvices.length > 0) {
  3042. if (this.patient.id <= 0) {
  3043. this.$message.error('没有选择患者')
  3044. this.loading = false
  3045. return
  3046. }
  3047. var arr = this.dialysisPrescription
  3048. // console.log('arr', arr)
  3049. const ParamsQuery = arr
  3050. // console.log('parasmqueryseven', parasmqueryseven)
  3051. ParamsQuery['patient'] = this.patient.id
  3052. ParamsQuery['record_date'] = this.record_date
  3053. ParamsQuery['mode'] = '1'
  3054. console.log('第七')
  3055. ParamsQuery['patient_id'] = this.patient.id
  3056. postPrescription(ParamsQuery).then(response => {
  3057. if (response.data.state == 0) {
  3058. this.$message.error(response.data.msg)
  3059. if(response.data.code == 600000008){
  3060. this.infoDialogVisible = true
  3061. }
  3062. return false
  3063. } else {
  3064. this.$notify({
  3065. title: '成功',
  3066. message: '提交成功',
  3067. type: 'success',
  3068. duration: 2000
  3069. })
  3070. const params = {
  3071. advices: this.waitUploadAdvices,
  3072. advice_date: uParseTime(
  3073. this.$route.query.date,
  3074. '{y}-{m}-{d}'
  3075. ),
  3076. advice_doctor: this.waitUploadAdvices[0].advice_doctor,
  3077. advice_type: this.waitUploadAdvices[0].advice_type,
  3078. parent_id: this.patient_id,
  3079. // start_time: uParseTime(this.$route.query.date, '{y}-{m}-{d}'),
  3080. start_time:
  3081. uParseTime(this.$route.query.date, '{y}-{m}-{d}') +
  3082. ' ' +
  3083. hour +
  3084. ':' +
  3085. minute,
  3086. remark: ''
  3087. }
  3088. CreateGroupAdvice(
  3089. this.$route.query.patient_id,
  3090. 0,
  3091. params
  3092. ).then(rs => {
  3093. var resp = rs.data
  3094. if (resp.state == 1) {
  3095. // this.doctorAdvices = resp.data.advices
  3096. this.$emit('advice')
  3097. } else {
  3098. if(resp.code == 600000008){
  3099. this.infoDialogVisible = true
  3100. }
  3101. }
  3102. })
  3103. const prescription_resp = response.data.data.prescription
  3104. var prescription = this.prescription
  3105. for (var index in prescription_resp) {
  3106. // prescription[index] = prescription_resp[index];
  3107. this.$set(prescription, index, prescription_resp[index])
  3108. }
  3109. this.hide()
  3110. }
  3111. })
  3112. } else {
  3113. if (this.patient.id <= 0) {
  3114. this.$message.error('没有选择患者')
  3115. this.loading = false
  3116. return
  3117. }
  3118. var arr = this.dialysisPrescription
  3119. // console.log('arr', arr)
  3120. const ParamsQuery = arr
  3121. // console.log('eight', ParamsQuery)
  3122. ParamsQuery['patient'] = this.patient.id
  3123. ParamsQuery['record_date'] = this.record_date
  3124. ParamsQuery['mode'] = '1'
  3125. ParamsQuery['patient_id'] = this.patient.id
  3126. console.log('第八')
  3127. postPrescription(ParamsQuery).then(response => {
  3128. if (response.data.state == 0) {
  3129. this.$message.error(response.data.msg)
  3130. if(response.data.code == 600000008){
  3131. this.infoDialogVisible = true
  3132. }
  3133. return false
  3134. } else {
  3135. this.$notify({
  3136. title: '成功',
  3137. message: '提交成功',
  3138. type: 'success',
  3139. duration: 2000
  3140. })
  3141. const prescription_resp = response.data.data.prescription
  3142. var prescription = this.prescription
  3143. for (var index in prescription_resp) {
  3144. // prescription[index] = prescription_resp[index];
  3145. this.$set(prescription, index, prescription_resp[index])
  3146. }
  3147. this.hide()
  3148. }
  3149. })
  3150. }
  3151. }
  3152. } else {
  3153. if (this.patient.id <= 0) {
  3154. this.$message.error('没有选择患者')
  3155. this.loading = false
  3156. return
  3157. }
  3158. var arr = this.dialysisPrescription
  3159. // console.log('arr', arr)
  3160. const ParamsQuery = arr
  3161. // console.log('night', ParamsQuery)
  3162. ParamsQuery['patient'] = this.patient.id
  3163. ParamsQuery['record_date'] = this.record_date
  3164. ParamsQuery['mode'] = '2'
  3165. ParamsQuery['patient_id'] = this.patient.id
  3166. if (
  3167. this.$store.getters.xt_user.user.id !=
  3168. this.dialysisPrescription.creater
  3169. ) {
  3170. ParamsQuery['mode'] = '3'
  3171. }
  3172. console.log('第九',ParamsQuery)
  3173. postPrescription(ParamsQuery).then(response => {
  3174. if (response.data.state == 0) {
  3175. this.$message.error(response.data.msg)
  3176. if(response.data.code == 600000008){
  3177. this.infoDialogVisible = true
  3178. }
  3179. return false
  3180. } else {
  3181. this.$notify({
  3182. title: '成功',
  3183. message: '提交成功',
  3184. type: 'success',
  3185. duration: 2000
  3186. })
  3187. const prescription_resp = response.data.data.prescription
  3188. var prescription = this.prescription
  3189. for (var index in prescription_resp) {
  3190. // prescription[index] = prescription_resp[index];
  3191. this.$set(prescription, index, prescription_resp[index])
  3192. }
  3193. this.hide()
  3194. }
  3195. })
  3196. }
  3197. }
  3198. }
  3199. }else {
  3200. console.log("error submit!!");
  3201. return false;
  3202. }
  3203. })
  3204. },
  3205. handleCancle: function() {
  3206. this.hide()
  3207. },
  3208. handleSolution: function(formName) {
  3209. if(this.dialysisPrescription.anticoagulant == "" || this.dialysisPrescription.anticoagulant == 0){
  3210. this.dialysisPrescription.anticoagulant = 3
  3211. }
  3212. if(this.$store.getters.xt_user.template_info.org_id ==10579 ){
  3213. if(this.dialysisPrescription.target_ultrafiltration==0){
  3214. this.$message.error("目标超滤量不能为空")
  3215. return false
  3216. }
  3217. }
  3218. this.$refs[formName].validate((valid)=>{
  3219. if(valid){
  3220. if(!this.isLoading){
  3221. if (this.dialysisPrescription.anticoagulant == 1) {
  3222. this.dialysisPrescription.anticoagulant_weichi = '0'
  3223. this.dialysisPrescription.anticoagulant_shouji = '0'
  3224. this.dialysisPrescription.anticoagulant_zongliang = '0'
  3225. }
  3226. // if (this.$store.getters.xt_user.template_info.template_id == 6) {
  3227. // if (this.dialysisPrescription.mode_id == 2) {
  3228. // if (
  3229. // this.dialysisPrescription.displace_liqui_part == 0 ||
  3230. // this.dialysisPrescription.displace_liqui_part == -2 ||
  3231. // this.dialysisPrescription.displace_liqui_value == 0 ||
  3232. // this.dialysisPrescription.displace_liqui_value == ''
  3233. // || this.dialysisPrescription.replacement_total == 0 ||
  3234. // this.dialysisPrescription.replacement_total == ''||
  3235. // this.dialysisPrescription.displace_speed == 0 ||
  3236. // this.dialysisPrescription.displace_speed == ''
  3237. // ) {
  3238. // this.$message.error('HDF模式下置换液和置换液总量不能为空!')
  3239. // return
  3240. // }
  3241. // }
  3242. // if(this.dialysisPrescription.mode_id!=2 && this.dialysisPrescription.mode_id!=5 && this.dialysisPrescription.mode_id!=12){
  3243. // this.dialysisPrescription.displace_liqui_part == 0
  3244. // this.dialysisPrescription.displace_liqui_value == 0
  3245. // this.dialysisPrescription.replacement_total == 0
  3246. // this.dialysisPrescription.displace_speed == 0
  3247. // console.log('this.dialysisPrescription.displace_liqui_part',this.dialysisPrescription.displace_liqui_part);
  3248. // console.log('this.dialysisPrescription.replacement_total',this.dialysisPrescription.replacement_total);
  3249. // // this.dialysisPrescription.displace_liqui_part = 0
  3250. // // this.dialysisPrescription.displace_liqui_value = 0
  3251. // // this.dialysisPrescription.replacement_total = 0
  3252. // // this.dialysisPrescription.displace_speed = 0
  3253. // }
  3254. // }
  3255. this.is_pre = 2
  3256. if (this.prescription.id == 0) {
  3257. if (this.is_open == 0) {
  3258. if (this.patient.id <= 0) {
  3259. this.$message.error('没有选择患者')
  3260. this.loading = false
  3261. return
  3262. }
  3263. console.log("预充了2",this.dialysisPrescription.pre_impulse)
  3264. this.dialysisPrescription.impulse = this.dialysisPrescription.pre_impulse
  3265. var arr = this.dialysisPrescription
  3266. const ParamsQuery = arr
  3267. ParamsQuery['patient'] = this.patient.id
  3268. ParamsQuery['record_date'] = this.record_date
  3269. ParamsQuery['mode'] = '1'
  3270. postSoulution(ParamsQuery).then(response => {
  3271. if (response.data.state == 0) {
  3272. this.$message.error(response.data.msg)
  3273. if(response.data.code == 600000008){
  3274. this.infoDialogVisible = true
  3275. }
  3276. return false
  3277. } else {
  3278. this.$notify({
  3279. title: '成功',
  3280. message: '提交成功',
  3281. type: 'success',
  3282. duration: 2000
  3283. })
  3284. const prescription_resp = response.data.data.prescription
  3285. const solution_resp = response.data.data.solution
  3286. var prescription = this.prescription
  3287. var solution = this.solution
  3288. for (var index in prescription_resp) {
  3289. // prescription[index] = prescription_resp[index];
  3290. this.$set(prescription, index, prescription_resp[index])
  3291. }
  3292. for (var index in solution_resp) {
  3293. // solution[index] = solution_resp[index];
  3294. this.$set(solution, index, solution_resp[index])
  3295. }
  3296. this.hide()
  3297. }
  3298. })
  3299. } else if (this.is_open == 1) {
  3300. if (this.targetAdvices.length > 0) {
  3301. // 弹框推送提
  3302. this.isShowRemindAdvice = true
  3303. this.isVisibility = false
  3304. } else {
  3305. if (this.patient.id <= 0) {
  3306. this.$message.error('没有选择患者')
  3307. this.loading = false
  3308. return
  3309. }
  3310. console.log("预充了3",this.dialysisPrescription.pre_impulse)
  3311. this.dialysisPrescription.impulse = this.dialysisPrescription.pre_impulse
  3312. var arr = this.dialysisPrescription
  3313. console.log('arr3', arr)
  3314. const ParamsQuery = arr
  3315. // console.log('长期处方2', ParamsQuery)
  3316. ParamsQuery['patient'] = this.patient.id
  3317. ParamsQuery['record_date'] = this.record_date
  3318. ParamsQuery['mode'] = '1'
  3319. postSoulution(ParamsQuery).then(response => {
  3320. if (response.data.state == 0) {
  3321. this.$message.error(response.data.msg)
  3322. if(response.data.code == 600000008){
  3323. this.infoDialogVisible = true
  3324. }
  3325. return false
  3326. } else {
  3327. this.$notify({
  3328. title: '成功',
  3329. message: '提交成功',
  3330. type: 'success',
  3331. duration: 2000
  3332. })
  3333. const prescription_resp = response.data.data.prescription
  3334. const solution_resp = response.data.data.solution
  3335. var prescription = this.prescription
  3336. var solution = this.solution
  3337. for (var index in prescription_resp) {
  3338. // prescription[index] = prescription_resp[index];
  3339. this.$set(prescription, index, prescription_resp[index])
  3340. }
  3341. for (var index in solution_resp) {
  3342. // solution[index] = solution_resp[index];
  3343. this.$set(solution, index, solution_resp[index])
  3344. }
  3345. this.hide()
  3346. }
  3347. })
  3348. }
  3349. } else if (this.is_open == 2) {
  3350. var date = new Date()
  3351. var hour =
  3352. date.getHours() < 10 ? '0' + date.getHours() : date.getHours()
  3353. var minute =
  3354. date.getMinutes() < 10
  3355. ? '0' + date.getMinutes()
  3356. : date.getMinutes()
  3357. if (this.waitUploadAdvices.length > 0) {
  3358. // if (this.patient.id <= 0) {
  3359. // this.$message.error('没有选择患者')
  3360. // this.loading = false
  3361. // return
  3362. // }
  3363. this.dialysisPrescription.impulse = this.dialysisPrescription.pre_impulse
  3364. var arr = this.dialysisPrescription
  3365. const ParamsQuery = arr
  3366. // console.log('长期处方3', ParamsQuery)
  3367. ParamsQuery['patient'] = this.patient.id
  3368. ParamsQuery['record_date'] = this.record_date
  3369. // console.log(this.prescription)
  3370. ParamsQuery['mode'] = '1'
  3371. postPrescription(ParamsQuery).then(response => {
  3372. if (response.data.state == 0) {
  3373. this.$message.error(response.data.msg)
  3374. if(response.data.code == 600000008){
  3375. this.infoDialogVisible = true
  3376. }
  3377. return false
  3378. } else {
  3379. this.$notify({
  3380. title: '成功',
  3381. message: '提交成功',
  3382. type: 'success',
  3383. duration: 2000
  3384. })
  3385. const params = {
  3386. advices: this.waitUploadAdvices,
  3387. advice_date: uParseTime(
  3388. this.$route.query.date,
  3389. '{y}-{m}-{d}'
  3390. ),
  3391. advice_doctor: this.waitUploadAdvices[0].advice_doctor,
  3392. advice_type: this.waitUploadAdvices[0].advice_type,
  3393. parent_id: this.patient_id,
  3394. // start_time: uParseTime(this.$route.query.date, '{y}-{m}-{d}'),
  3395. start_time:
  3396. uParseTime(this.$route.query.date, '{y}-{m}-{d}') +
  3397. ' ' +
  3398. hour +
  3399. ':' +
  3400. minute,
  3401. remark: ''
  3402. }
  3403. CreateGroupAdvice(this.$route.query.patient_id, 0, params).then(
  3404. rs => {
  3405. var resp = rs.data
  3406. if (resp.state == 1) {
  3407. // this.doctorAdvices = resp.data.advices
  3408. this.$emit('advice')
  3409. } else {
  3410. if(resp.code == 600000008){
  3411. this.infoDialogVisible = true
  3412. }
  3413. }
  3414. }
  3415. )
  3416. const prescription_resp = response.data.data.prescription
  3417. var prescription = this.prescription
  3418. for (var index in prescription_resp) {
  3419. // prescription[index] = prescription_resp[index];
  3420. this.$set(prescription, index, prescription_resp[index])
  3421. }
  3422. this.hide()
  3423. }
  3424. })
  3425. } else {
  3426. if (this.patient.id <= 0) {
  3427. this.$message.error('没有选择患者')
  3428. this.loading = false
  3429. return
  3430. }
  3431. console.log("预充了5",this.dialysisPrescription.pre_impulse)
  3432. this.dialysisPrescription.impulse = this.dialysisPrescription.pre_impulse
  3433. var arr = this.dialysisPrescription
  3434. console.log('arr5', arr)
  3435. const ParamsQuery = arr
  3436. // console.log('长期处方5', ParamsQuery)
  3437. ParamsQuery['patient'] = this.patient.id
  3438. ParamsQuery['record_date'] = this.record_date
  3439. ParamsQuery['mode'] = '1'
  3440. postSoulution(ParamsQuery).then(response => {
  3441. if (response.data.state == 0) {
  3442. this.$message.error(response.data.msg)
  3443. if(response.data.code == 600000008){
  3444. this.infoDialogVisible = true
  3445. }
  3446. return false
  3447. } else {
  3448. this.$notify({
  3449. title: '成功',
  3450. message: '提交成功',
  3451. type: 'success',
  3452. duration: 2000
  3453. })
  3454. const prescription_resp = response.data.data.prescription
  3455. const solution_resp = response.data.data.solution
  3456. var prescription = this.prescription
  3457. var solution = this.solution
  3458. for (var index in prescription_resp) {
  3459. // prescription[index] = prescription_resp[index];
  3460. this.$set(prescription, index, prescription_resp[index])
  3461. }
  3462. for (var index in solution_resp) {
  3463. // solution[index] = solution_resp[index];
  3464. this.$set(solution, index, solution_resp[index])
  3465. }
  3466. this.hide()
  3467. }
  3468. })
  3469. }
  3470. }
  3471. } else {
  3472. if (this.prescription.creater == 0) {
  3473. if (this.is_open == 0) {
  3474. if (this.patient.id <= 0) {
  3475. this.$message.error('没有选择患者')
  3476. this.loading = false
  3477. return
  3478. }
  3479. this.dialysisPrescription.impulse = this.dialysisPrescription.pre_impulse
  3480. var arr = this.dialysisPrescription
  3481. console.log('arr', arr)
  3482. const ParamsQuery = arr
  3483. // console.log('长期处方6', ParamsQuery)
  3484. ParamsQuery['patient'] = this.patient.id
  3485. ParamsQuery['record_date'] = this.record_date
  3486. ParamsQuery['mode'] = '1'
  3487. postSoulution(ParamsQuery).then(response => {
  3488. if (response.data.state == 0) {
  3489. this.$message.error(response.data.msg)
  3490. if(response.data.code == 600000008){
  3491. this.infoDialogVisible = true
  3492. }
  3493. return false
  3494. } else {
  3495. this.$notify({
  3496. title: '成功',
  3497. message: '提交成功',
  3498. type: 'success',
  3499. duration: 2000
  3500. })
  3501. const prescription_resp = response.data.data.prescription
  3502. const solution_resp = response.data.data.solution
  3503. var prescription = this.prescription
  3504. var solution = this.solution
  3505. for (var index in prescription_resp) {
  3506. // prescription[index] = prescription_resp[index];
  3507. this.$set(prescription, index, prescription_resp[index])
  3508. }
  3509. for (var index in solution_resp) {
  3510. // solution[index] = solution_resp[index];
  3511. this.$set(solution, index, solution_resp[index])
  3512. }
  3513. this.hide()
  3514. }
  3515. })
  3516. } else if (this.is_open == 1) {
  3517. if (this.targetAdvices.length > 0) {
  3518. // 弹框推送提醒
  3519. this.isShowRemindAdvice = true
  3520. this.isVisibility = false
  3521. } else {
  3522. if (this.patient.id <= 0) {
  3523. this.$message.error('没有选择患者')
  3524. this.loading = false
  3525. return
  3526. }
  3527. console.log("预充了7",this.dialysisPrescription.pre_impulse)
  3528. this.dialysisPrescription.impulse = this.dialysisPrescription.pre_impulse
  3529. var arr = this.dialysisPrescription
  3530. // console.log('arr', arr)
  3531. const ParamsQuery = arr
  3532. console.log('长期处方7', ParamsQuery)
  3533. ParamsQuery['patient'] = this.patient.id
  3534. ParamsQuery['record_date'] = this.record_date
  3535. ParamsQuery['mode'] = '1'
  3536. postSoulution(ParamsQuery).then(response => {
  3537. if (response.data.state == 0) {
  3538. this.$message.error(response.data.msg)
  3539. if(response.data.code == 600000008){
  3540. this.infoDialogVisible = true
  3541. }
  3542. return false
  3543. } else {
  3544. this.$notify({
  3545. title: '成功',
  3546. message: '提交成功',
  3547. type: 'success',
  3548. duration: 2000
  3549. })
  3550. const prescription_resp = response.data.data.prescription
  3551. const solution_resp = response.data.data.solution
  3552. var prescription = this.prescription
  3553. var solution = this.solution
  3554. for (var index in prescription_resp) {
  3555. // prescription[index] = prescription_resp[index];
  3556. this.$set(prescription, index, prescription_resp[index])
  3557. }
  3558. for (var index in solution_resp) {
  3559. // solution[index] = solution_resp[index];
  3560. this.$set(solution, index, solution_resp[index])
  3561. }
  3562. this.hide()
  3563. }
  3564. })
  3565. }
  3566. } else if (this.is_open == 2) {
  3567. var date = new Date()
  3568. var hour =
  3569. date.getHours() < 10 ? '0' + date.getHours() : date.getHours()
  3570. var minute =
  3571. date.getMinutes() < 10
  3572. ? '0' + date.getMinutes()
  3573. : date.getMinutes()
  3574. if (this.waitUploadAdvices.length > 0) {
  3575. if (this.patient.id <= 0) {
  3576. this.$message.error('没有选择患者')
  3577. this.loading = false
  3578. return
  3579. }
  3580. this.dialysisPrescription.impulse = this.dialysisPrescription.pre_impulse
  3581. var arr = this.dialysisPrescription
  3582. const ParamsQuery = arr
  3583. // console.log('长期处方8', ParamsQuery)
  3584. ParamsQuery['patient'] = this.patient.id
  3585. ParamsQuery['record_date'] = this.record_date
  3586. ParamsQuery['mode'] = '1'
  3587. postSoulution(ParamsQuery).then(response => {
  3588. if (response.data.state == 0) {
  3589. this.$message.error(response.data.msg)
  3590. if(response.data.code == 600000008){
  3591. this.infoDialogVisible = true
  3592. }
  3593. return false
  3594. } else {
  3595. this.$notify({
  3596. title: '成功',
  3597. message: '提交成功',
  3598. type: 'success',
  3599. duration: 2000
  3600. })
  3601. const params = {
  3602. advices: this.waitUploadAdvices,
  3603. advice_date: uParseTime(
  3604. this.$route.query.date,
  3605. '{y}-{m}-{d}'
  3606. ),
  3607. advice_doctor: this.waitUploadAdvices[0].advice_doctor,
  3608. advice_type: this.waitUploadAdvices[0].advice_type,
  3609. parent_id: this.patient_id,
  3610. start_time: uParseTime(this.$route.query.date, '{y}-{m}-{d} {h}{i}'),
  3611. // start_time:
  3612. // uParseTime(this.$route.query.date, '{y}-{m}-{d}') +
  3613. // ' ' +
  3614. // hour +
  3615. // ':' +
  3616. // minute,
  3617. remark: ''
  3618. }
  3619. CreateGroupAdvice(
  3620. this.$route.query.patient_id,
  3621. 0,
  3622. params
  3623. ).then(rs => {
  3624. var resp = rs.data
  3625. if (resp.state == 1) {
  3626. // this.doctorAdvices = resp.data.advices
  3627. this.$emit('advice')
  3628. } else {
  3629. if(resp.code == 600000008){
  3630. this.infoDialogVisible = true
  3631. }
  3632. }
  3633. })
  3634. const prescription_resp = response.data.data.prescription
  3635. const solution_resp = response.data.data.solution
  3636. var prescription = this.prescription
  3637. var solution = this.solution
  3638. for (var index in prescription_resp) {
  3639. // prescription[index] = prescription_resp[index];
  3640. this.$set(prescription, index, prescription_resp[index])
  3641. }
  3642. for (var index in solution_resp) {
  3643. // solution[index] = solution_resp[index];
  3644. this.$set(solution, index, solution_resp[index])
  3645. }
  3646. this.hide()
  3647. }
  3648. })
  3649. } else {
  3650. if (this.patient.id <= 0) {
  3651. this.$message.error('没有选择患者')
  3652. this.loading = false
  3653. return
  3654. }
  3655. console.log("预充了99999",this.dialysisPrescription.pre_impulse)
  3656. this.dialysisPrescription.impulse = this.dialysisPrescription.pre_impulse
  3657. var arr = this.dialysisPrescription
  3658. console.log('arr', arr)
  3659. const ParamsQuery = arr
  3660. // console.log('长期处方9', ParamsQuery)
  3661. ParamsQuery['patient'] = this.patient.id
  3662. ParamsQuery['record_date'] = this.record_date
  3663. ParamsQuery['mode'] = '1'
  3664. postSoulution(ParamsQuery).then(response => {
  3665. if (response.data.state == 0) {
  3666. this.$message.error(response.data.msg)
  3667. if(response.data.code == 600000008){
  3668. this.infoDialogVisible = true
  3669. }
  3670. return false
  3671. } else {
  3672. this.$notify({
  3673. title: '成功',
  3674. message: '提交成功',
  3675. type: 'success',
  3676. duration: 2000
  3677. })
  3678. const prescription_resp = response.data.data.prescription
  3679. const solution_resp = response.data.data.solution
  3680. var prescription = this.prescription
  3681. var solution = this.solution
  3682. for (var index in prescription_resp) {
  3683. // prescription[index] = prescription_resp[index];
  3684. this.$set(prescription, index, prescription_resp[index])
  3685. }
  3686. for (var index in solution_resp) {
  3687. // solution[index] = solution_resp[index];
  3688. this.$set(solution, index, solution_resp[index])
  3689. }
  3690. this.hide()
  3691. }
  3692. })
  3693. }
  3694. }
  3695. } else {
  3696. if (this.patient.id <= 0) {
  3697. this.$message.error('没有选择患者')
  3698. this.loading = false
  3699. return
  3700. }
  3701. console.log("预充了1",this.dialysisPrescription.pre_impulse)
  3702. this.dialysisPrescription.impulse = this.dialysisPrescription.pre_impulse
  3703. var arr = this.dialysisPrescription
  3704. console.log('arr12333223', arr)
  3705. const ParamsQuery = arr
  3706. ParamsQuery['patient'] = this.patient.id
  3707. ParamsQuery['record_date'] = this.record_date
  3708. ParamsQuery['mode'] = '1'
  3709. console.log('长期处方10', ParamsQuery)
  3710. postSoulution(ParamsQuery).then(response => {
  3711. if (response.data.state == 0) {
  3712. this.$message.error(response.data.msg)
  3713. if(response.data.code == 600000008){
  3714. this.infoDialogVisible = true
  3715. }
  3716. return false
  3717. } else {
  3718. this.$notify({
  3719. title: '成功',
  3720. message: '提交成功',
  3721. type: 'success',
  3722. duration: 2000
  3723. })
  3724. const prescription_resp = response.data.data.prescription
  3725. const solution_resp = response.data.data.solution
  3726. var prescription = this.prescription
  3727. var solution = this.solution
  3728. for (var index in prescription_resp) {
  3729. // prescription[index] = prescription_resp[index];
  3730. this.$set(prescription, index, prescription_resp[index])
  3731. }
  3732. for (var index in solution_resp) {
  3733. // solution[index] = solution_resp[index];
  3734. this.$set(solution, index, solution_resp[index])
  3735. }
  3736. this.hide()
  3737. }
  3738. })
  3739. }
  3740. }
  3741. }
  3742. }
  3743. })
  3744. },
  3745. isName(name) {
  3746. let filedList = store.getters.xt_user.fileds;
  3747. for (let i = 0; i < filedList.length; i++) {
  3748. if (filedList[i].module == 1 && filedList[i].filed_name_cn == name && filedList[i].is_show == 1) {
  3749. return filedList[i].filed_name;
  3750. }
  3751. }
  3752. },
  3753. isShows(name) {
  3754. var filedList = store.getters.xt_user.fileds
  3755. for (let i = 0; i < filedList.length; i++) {
  3756. if (filedList[i].module == 1 && filedList[i].filed_name_cn == name && filedList[i].is_show == 1) {
  3757. return true
  3758. }
  3759. }
  3760. return false
  3761. },
  3762. isCheckmust(name) {
  3763. let filedList = store.getters.xt_user.fileds;
  3764. for (let i = 0; i < filedList.length; i++) {
  3765. if (
  3766. filedList[i].module == 1 &&
  3767. filedList[i].filed_name_cn == name &&
  3768. filedList[i].is_write == 1&&
  3769. filedList[i].is_show == 1
  3770. ) {
  3771. // console.log(filedList[i],'false')
  3772. if (name == "透析模式" || name == "透析时长") {
  3773. return [
  3774. { required: true, message: `请输入${name}`,trigger: ['blur','change'] },
  3775. // {
  3776. // required: true,
  3777. // pattern: /^[1-9]\d*$/,
  3778. // message: `请输入${name}`,
  3779. // trigger: ['blur','change']
  3780. // },
  3781. ];
  3782. }
  3783. return [{ required: true ,message:`请输入${name}`, trigger: ['blur','change'] }];
  3784. }
  3785. }
  3786. },
  3787. isNas(name){
  3788. let filedList = store.getters.xt_user.fileds;
  3789. for (let i = 0; i < filedList.length; i++) {
  3790. if (
  3791. filedList[i].module == 1 &&
  3792. filedList[i].filed_name_cn == name &&
  3793. filedList[i].is_write == 1&&
  3794. filedList[i].is_show == 1
  3795. ) {
  3796. return [{ required: true ,message:`请输入${name}`, trigger: ['blur','change'] }];
  3797. }
  3798. }
  3799. },
  3800. isSubstitution(name){
  3801. if(this.dialysisPrescription.mode_id == 2 ||this.dialysisPrescription.mode_id == 5 || this.dialysisPrescription.mode_id == 12){
  3802. let filedList = store.getters.xt_user.fileds;
  3803. for (let i = 0; i < filedList.length; i++) {
  3804. if (
  3805. filedList[i].module == 1 &&
  3806. filedList[i].filed_name_cn == name &&
  3807. filedList[i].is_write == 1&&
  3808. filedList[i].is_show == 1
  3809. ) {
  3810. if(name == '置换速度'){
  3811. return [
  3812. { required: true, message: `请输入${name}`,trigger: ['blur','change'] },
  3813. // {
  3814. // required: true,
  3815. // pattern: /^[1-9]\d*$/,
  3816. // message: `请输入${name}`,
  3817. // trigger: ['blur','change']
  3818. // },
  3819. ];
  3820. }
  3821. return [{ required: true ,message:`请输入${name}`, trigger: ['blur','change'] }];
  3822. }
  3823. }
  3824. }else{
  3825. return [{required: false}]
  3826. }
  3827. },
  3828. getDoctorName(doctor_id) {
  3829. for (let i = 0; i < this.admin_users.length; i++) {
  3830. if (this.admin_users[i].id == doctor_id) {
  3831. return this.admin_users[i].name
  3832. }
  3833. }
  3834. },
  3835. getContent(val) {
  3836. let prescribing_number = ''
  3837. let single_dose = ''
  3838. let advice_desc = ''
  3839. if (val.prescribing_number > 0) {
  3840. prescribing_number =
  3841. val.prescribing_number + val.prescribing_number_unit
  3842. }
  3843. if (val.single_dose > 0) {
  3844. single_dose = ' 单次用量 ' + val.single_dose + val.single_dose_unit
  3845. }
  3846. if (val.advice_desc > 0 || val.advice_desc.length > 0) {
  3847. advice_desc = val.advice_desc + val.drug_spec_unit
  3848. }
  3849. let name = ''
  3850. if (val.child.length > 0) {
  3851. for (let i = 0; i < val.child.length; i++) {
  3852. if (val.child[i].prescribing_number > 0) {
  3853. val.child[i]['presc'] =
  3854. val.child[i].prescribing_number +
  3855. val.child[i].prescribing_number_unit
  3856. } else {
  3857. val.child[i]['presc'] = ''
  3858. }
  3859. if (val.child[i].single_dose > 0) {
  3860. val.child[i]['single'] =
  3861. ' ' +
  3862. ' 单次用量 ' +
  3863. ' ' +
  3864. val.child[i].single_dose +
  3865. val.child[i].single_dose_unit
  3866. } else {
  3867. val.child[i]['single'] = ''
  3868. }
  3869. name =
  3870. name +
  3871. '▲' +
  3872. val.child[i].advice_name +
  3873. '' +
  3874. val.child[i].advice_desc +
  3875. val.child[i].drug_spec_unit +
  3876. val.child[i].presc +
  3877. val.child[i].single
  3878. }
  3879. return (
  3880. val.advice_name +
  3881. ' ' +
  3882. advice_desc +
  3883. ' ' +
  3884. val.drug_spec_unit +
  3885. prescribing_number +
  3886. ' ' +
  3887. single_dose +
  3888. ' ' +
  3889. ' ' +
  3890. val.delivery_way +
  3891. ' ' +
  3892. val.execution_frequency +
  3893. val.remark +
  3894. name
  3895. )
  3896. } else {
  3897. return (
  3898. val.advice_name +
  3899. ' ' +
  3900. advice_desc +
  3901. prescribing_number +
  3902. ' ' +
  3903. single_dose +
  3904. ' ' +
  3905. ' ' +
  3906. val.delivery_way +
  3907. ' ' +
  3908. val.execution_frequency +
  3909. val.remark
  3910. )
  3911. }
  3912. },
  3913. changePrescription(id) {
  3914. console.log("id233223232323232323",id)
  3915. if(id != 2 && id!=5 && id!= 12&&id!=34 &&id!=35&&id!=35&&id!=36&&id!=37){
  3916. this.dialysisPrescription.displace_liqui_value = ""
  3917. this.dialysisPrescription.displace_liqui_part = ""
  3918. this.dialysisPrescription.replacement_total = ""
  3919. this.dialysisPrescription.displace_speed = ""
  3920. }
  3921. const ParamsQuery = {}
  3922. ParamsQuery['patient_id'] = this.$route.query.patient_id
  3923. ParamsQuery['mode_id'] = id
  3924. GetSolution(ParamsQuery).then(response => {
  3925. if (response.data.state == 0) {
  3926. this.$message.error(response.data.msg)
  3927. return false
  3928. } else {
  3929. console.log('切换数据', response.data.data.solution)
  3930. this.$message.success('切换成功')
  3931. console.log("dialysisPrescription",response.data.data.dialysisPrescription)
  3932. if (response.data.data.solution != null) {
  3933. for (const key in response.data.data.solution) {
  3934. // 长期处方不为空
  3935. if (key != 'target_ultrafiltration' && key != 'niprocart' && key != 'target_ultrafiltration' && key != 'jms' && key != 'fistula_needle_set' && key != 'fistula_needle_set_16'
  3936. && key != 'hemoperfusion' && key != 'dialyser_sterilised' && key != 'filtryzer' && key != 'target_ktv' && key != 'dialyzers'
  3937. && key != 'injector' && key != 'bloodlines' && key != 'tubing_hemodialysis' && key != 'package' && key != 'a_liquid'&& key != 'remark') {
  3938. this.dialysisPrescription[key] =
  3939. response.data.data.solution[key]
  3940. }
  3941. }
  3942. if (this.$store.getters.xt_user.template_info.org_id== 9671 || this.$store.getters.xt_user.template_info.org_id == 9675 || this.$store.getters.xt_user.template_info.org_id == 10340) {
  3943. console.log('抠门;哦啊', response.data.data.dialysisPrescription.remark)
  3944. this.dialysisPrescription.sodium = 138
  3945. this.dialysisPrescription.bicarbonate = 31.1
  3946. this.dialysisPrescription.dialysate_flow = 500
  3947. if (this.last_prescription != null && response.data.data.dialysisPrescription != null) {
  3948. this.dialysisPrescription.remark = response.data.data.dialysisPrescription.remark
  3949. }
  3950. }
  3951. if(this.$store.getters.xt_user.template_info.org_id== 10013 || this.$store.getters.xt_user.template_info.org_id== 10014){
  3952. if (this.last_prescription != null && response.data.data.dialysisPrescription != null) {
  3953. this.dialysisPrescription.remark = response.data.data.dialysisPrescription.remark
  3954. }
  3955. }
  3956. } else {
  3957. if (response.data.data.prescription != null) {
  3958. // 临时处方不为空
  3959. for (const key in response.data.data.prescription) {
  3960. if (key != 'target_ultrafiltration' && key != 'niprocart' && key != 'target_ultrafiltration' && key != 'jms' && key != 'fistula_needle_set' && key != 'fistula_needle_set_16'
  3961. && key != 'hemoperfusion' && key != 'dialyser_sterilised' && key != 'filtryzer' && key != 'target_ktv' && key != 'dialyzers'
  3962. && key != 'injector' && key != 'bloodlines' && key != 'tubing_hemodialysis' && key != 'package' && key != 'a_liquid' && key != 'remark') {
  3963. this.dialysisPrescription[key] =
  3964. response.data.data.prescription[key]
  3965. }
  3966. }
  3967. } else if (response.data.data.system_prescription != null) {
  3968. // 系统处方不为空
  3969. for (const key in response.data.data.system_prescription) {
  3970. if (key != 'target_ultrafiltration' && key != 'niprocart' && key != 'target_ultrafiltration' && key != 'jms' && key != 'fistula_needle_set' && key != 'fistula_needle_set_16'
  3971. && key != 'hemoperfusion' && key != 'dialyser_sterilised' && key != 'filtryzer' && key != 'target_ktv' && key != 'dialyzers'
  3972. && key != 'injector' && key != 'bloodlines' && key != 'tubing_hemodialysis' && key != 'package' && key != 'a_liquid' && key != 'remark') {
  3973. this.dialysisPrescription[key] =
  3974. response.data.data.system_prescription[key]
  3975. }
  3976. }
  3977. } else {
  3978. for (const key in this.dialysisPrescription) {
  3979. // 临时处方为空
  3980. if (key != 'target_ultrafiltration' && key != 'niprocart' && key != 'target_ultrafiltration' && key != 'jms' && key != 'fistula_needle_set' && key != 'fistula_needle_set_16'
  3981. && key != 'hemoperfusion' && key != 'dialyser_sterilised' && key != 'filtryzer' && key != 'target_ktv' && key != 'dialyzers'
  3982. && key != 'injector' && key != 'bloodlines' && key != 'tubing_hemodialysis' && key != 'package' && key != 'a_liquid' && key != 'remark') {
  3983. this.dialysisPrescription[key] = ''
  3984. }
  3985. }
  3986. this.dialysisPrescription.mode_id = id
  3987. }
  3988. if (this.$store.getters.xt_user.template_info.org_id == 9671 ||this.$store.getters.xt_user.template_info.org_id == 9675 ||this.$store.getters.xt_user.template_info.org_id== 10340) {
  3989. this.dialysisPrescription.sodium = 138
  3990. this.dialysisPrescription.bicarbonate = 31.1
  3991. this.dialysisPrescription.dialysate_flow = 500
  3992. if (this.last_prescription != null && response.data.data.system_prescription != null && response.data.data.system_prescription.remark == '') {
  3993. this.dialysisPrescription.remark = response.data.data.system_prescription.remark
  3994. }
  3995. }
  3996. }
  3997. if(response.data.data.dialysisPrescription!=null){
  3998. this.dialysisPrescription.remark = response.data.data.dialysisPrescription.remark
  3999. }
  4000. }
  4001. if (response.data.data.solution == null) {
  4002. if (this.$store.getters.xt_user.template_info.org_id== 9671 || this.$store.getters.xt_user.template_info.org_id == 9675 ||this.$store.getters.xt_user.template_info.org_id== 10340) {
  4003. this.dialysisPrescription.sodium = 138
  4004. this.dialysisPrescription.bicarbonate = 31.1
  4005. this.dialysisPrescription.dialysate_flow = 500
  4006. if (this.last_prescription != null) {
  4007. this.dialysisPrescription.remark = this.last_prescription.remark
  4008. }
  4009. }
  4010. if(this.$store.getters.xt_user.template_info.org_id== 10013 || this.$store.getters.xt_user.template_info.org_id== 10014){
  4011. if (this.last_prescription != null) {
  4012. this.dialysisPrescription.remark = this.last_prescription.remark
  4013. }
  4014. }
  4015. }
  4016. if (
  4017. this.dialysisPrescription.dialysis_duration_hour === '' ||
  4018. this.dialysisPrescription.dialysis_duration_minute === ''
  4019. ) {
  4020. this.timeValue = ''
  4021. this.time = '03:00'
  4022. } else {
  4023. this.timeValue =
  4024. this.dialysisPrescription.dialysis_duration_hour +
  4025. '小时' +
  4026. this.dialysisPrescription.dialysis_duration_minute +
  4027. '分钟'
  4028. this.time =
  4029. (this.dialysisPrescription.dialysis_duration_hour > 10
  4030. ? this.dialysisPrescription.dialysis_duration_hour
  4031. : '0' + this.dialysisPrescription.dialysis_duration_hour) +
  4032. ':' +
  4033. (this.dialysisPrescription.dialysis_duration_minute > 10
  4034. ? this.dialysisPrescription.dialysis_duration_minute
  4035. : '0' + this.dialysisPrescription.dialysis_duration_minute)
  4036. }
  4037. })
  4038. if (
  4039. id === 1 ||
  4040. id === 3 ||
  4041. id === 4 ||
  4042. id === 6 ||
  4043. id === 7 ||
  4044. id === 8 ||
  4045. id === 9 ||
  4046. id === 10 ||
  4047. id === 11 ||
  4048. id === 13 ||
  4049. id === 14 ||
  4050. id === 15 ||
  4051. id === 16 ||
  4052. id === 19
  4053. ) {
  4054. this.zhiShow = false
  4055. this.huShow = false
  4056. this.totalShow = false
  4057. } else {
  4058. this.zhiShow = true
  4059. this.huShow = true
  4060. this.totalShow = true
  4061. //针对新化博翔
  4062. if(this.$store.getters.xt_user.template_info.org_id ==10447){
  4063. this.dialysisPrescription.displace_liqui_part = 1
  4064. this.dialysisPrescription.displace_liqui_value = 35
  4065. }
  4066. }
  4067. },
  4068. handlePatientInfo() {
  4069. this.isVisibility = false
  4070. this.msgtip_visibility = true
  4071. },
  4072. handlePatientInfoOne(){
  4073. this.isVisibility = false
  4074. this.startVisibility = true
  4075. },
  4076. cancleMsg() {
  4077. this.isVisibility = true
  4078. this.msgtip_visibility = false
  4079. },
  4080. cancleMsgOne(){
  4081. this.isVisibility = true
  4082. this.startVisibility = false
  4083. },
  4084. getPermission() {
  4085. request
  4086. .get('/api/func_per/get', {
  4087. params: {
  4088. create_url: '/api/dialysis/prescription?mode=1',
  4089. modify_url: '/api/dialysis/prescription?mode=2',
  4090. modify_other_url: '/api/dialysis/prescription?mode=3',
  4091. module: 1
  4092. }
  4093. })
  4094. .then(res => {
  4095. // console.log(res)
  4096. // console.log('predialysis.creater', this.pre.creater)
  4097. // console.log('admin.id', this.$store.getters.xt_user.user.id)
  4098. if (res.data.state == 0) {
  4099. this.hasPermission = false
  4100. } else if (res.data.state == 1) {
  4101. if (this.pre.id != '' && this.pre.creater != 0) {
  4102. // 有数据
  4103. if (this.pre.creater == this.$store.getters.xt_user.user.id) {
  4104. // 创建人是自己
  4105. if (res.data.data.is_has_modify == false) {
  4106. this.hasPermission = false
  4107. this.showTxt = '你没有修改透析处方权限'
  4108. }
  4109. } else {
  4110. // 创建人不是自己
  4111. if (res.data.data.is_has_modify_other == false) {
  4112. this.hasPermission = false
  4113. this.showTxt = '你没有修改他人透析处方权限'
  4114. }
  4115. }
  4116. } else if (this.pre.id == '' || this.pre.creater == 0) {
  4117. if (res.data.data.is_has_create == false) {
  4118. this.hasPermission = false
  4119. this.showTxt = '你没有新增透析处方权限'
  4120. }
  4121. }
  4122. }
  4123. })
  4124. },
  4125. unique(arr) {
  4126. const res = new Map()
  4127. return arr.filter((arr) => !res.has(arr.name) && res.set(arr.name, 1))
  4128. },
  4129. dialysisAfterTeachSelectChange: function(values) {
  4130. console.log("values232323232wo",values)
  4131. if (this.dialysisPrescription.dialysis_remark == '' || this.dialysisPrescription.dialysis_remark==undefined) {
  4132. this.dialysisPrescription.dialysis_remark = values
  4133. } else {
  4134. console.log("this.dialysisPrescription.dialysis_remark",this.dialysisPrescription.dialysis_remark)
  4135. if (this.dialysisPrescription.dialysis_remark!=undefined&&this.dialysisPrescription.dialysis_remark.indexOf(values) == -1) {
  4136. if (this.dialysisPrescription.dialysis_remark.charAt(this.dialysisPrescription.dialysis_remark.length - 1).indexOf('。') == -1) {
  4137. this.dialysisPrescription.dialysis_remark = this.dialysisPrescription.dialysis_remark + ',' + values
  4138. } else {
  4139. this.dialysisPrescription.dialysis_remark = this.dialysisPrescription.dialysis_remark + values
  4140. }
  4141. }
  4142. }
  4143. },
  4144. saveInformation(){
  4145. var params = {
  4146. selected_date:this.selected_date,
  4147. patient_id:this.$route.query.patient_id,
  4148. record_date:this.$route.query.date,
  4149. module:1,
  4150. remark:this.remark,
  4151. }
  4152. saveInformation(params).then(response=>{
  4153. if(response.data.state == 1){
  4154. var information = response.data.data.information
  4155. this.$message.success("提交成功!")
  4156. this.infoDialogVisible = false
  4157. }
  4158. })
  4159. }
  4160. },
  4161. watch: {
  4162. // 'dialysisPrescription.blood_flow_volume': function () {
  4163. // this.dialysisPrescription.blood_flow_volume = replacementFlow(this.dialysisPrescription.blood_flow_volume)
  4164. // },
  4165. // 'dialysisPrescription.replacement_flow': function () {
  4166. // console.log("血流量",this.dialysisPrescription.replacement_flow)
  4167. // this.dialysisPrescription.replacement_flow = this.dialysisPrescription.replacement_flow
  4168. // },
  4169. 'dialysisPrescription.dialysis_duration_hour': function() {
  4170. let dialysis_duration_minute = 0
  4171. let dialysis_duration_hour = 0
  4172. let duration = 0
  4173. if (this.dialysisPrescription.dialysis_duration_minute == '') {
  4174. dialysis_duration_minute = 0
  4175. } else {
  4176. dialysis_duration_minute = this.dialysisPrescription
  4177. .dialysis_duration_minute
  4178. }
  4179. if (this.dialysisPrescription.dialysis_duration_hour == '') {
  4180. dialysis_duration_hour = 0
  4181. } else {
  4182. dialysis_duration_hour = this.dialysisPrescription
  4183. .dialysis_duration_hour
  4184. }
  4185. duration = parseFloat(dialysis_duration_hour) + parseFloat(dialysis_duration_minute) / 60
  4186. this.dialysisPrescription.anticoagulant_zongliang = calculateAnticoagulantZL(1, this.dialysisPrescription.anticoagulant_shouji, duration, this.dialysisPrescription.anticoagulant_weichi,this.dialysisPrescription.add_amount,this.dialysisPrescription.reduce_amount)
  4187. if (isNaN(this.dialysisPrescription.anticoagulant_zongliang)) {
  4188. this.dialysisPrescription.anticoagulant_zongliang = ''
  4189. }
  4190. this.zongliang = this.dialysisPrescription.anticoagulant_zongliang
  4191. },
  4192. 'dialysisPrescription.dialysis_duration_minute': function() {
  4193. let dialysis_duration_minute = 0
  4194. let dialysis_duration_hour = 0
  4195. let duration = 0
  4196. if (this.dialysisPrescription.dialysis_duration_minute == '') {
  4197. dialysis_duration_minute = 0
  4198. } else {
  4199. dialysis_duration_minute = this.dialysisPrescription.dialysis_duration_minute
  4200. }
  4201. if (this.dialysisPrescription.dialysis_duration_hour == '') {
  4202. dialysis_duration_hour = 0
  4203. } else {
  4204. dialysis_duration_hour = this.dialysisPrescription
  4205. .dialysis_duration_hour
  4206. }
  4207. duration =
  4208. parseFloat(dialysis_duration_hour) +
  4209. parseFloat(dialysis_duration_minute) / 60
  4210. this.dialysisPrescription.anticoagulant_zongliang = calculateAnticoagulantZL(1, this.dialysisPrescription.anticoagulant_shouji, duration,
  4211. this.dialysisPrescription.anticoagulant_weichi,this.dialysisPrescription.add_amount,this.dialysisPrescription.reduce_amount
  4212. )
  4213. if (isNaN(this.dialysisPrescription.anticoagulant_zongliang)) {
  4214. this.dialysisPrescription.anticoagulant_zongliang = ''
  4215. }
  4216. },
  4217. 'dialysisPrescription.anticoagulant_shouji': function() {
  4218. let dialysis_duration_minute = 0
  4219. let dialysis_duration_hour = 0
  4220. let duration = 0
  4221. if (this.dialysisPrescription.dialysis_duration_minute == '') {
  4222. dialysis_duration_minute = 0
  4223. } else {
  4224. dialysis_duration_minute = this.dialysisPrescription
  4225. .dialysis_duration_minute
  4226. }
  4227. if (this.dialysisPrescription.dialysis_duration_hour == '') {
  4228. dialysis_duration_hour = 0
  4229. } else {
  4230. dialysis_duration_hour = this.dialysisPrescription
  4231. .dialysis_duration_hour
  4232. }
  4233. duration =
  4234. parseFloat(dialysis_duration_hour) +
  4235. parseFloat(dialysis_duration_minute) / 60
  4236. this.dialysisPrescription.anticoagulant_zongliang = calculateAnticoagulantZL(
  4237. 1,
  4238. this.dialysisPrescription.anticoagulant_shouji,
  4239. duration,
  4240. this.dialysisPrescription.anticoagulant_weichi,
  4241. this.dialysisPrescription.add_amount,
  4242. this.dialysisPrescription.reduce_amount
  4243. )
  4244. this.zongliang = this.dialysisPrescription.anticoagulant_zongliang
  4245. if (isNaN(this.dialysisPrescription.anticoagulant_zongliang)) {
  4246. this.dialysisPrescription.anticoagulant_zongliang = ''
  4247. }
  4248. if(this.$store.getters.xt_user.template_info.template_id == 41 && this.dialysisPrescription.anticoagulant == 2){
  4249. this.dialysisPrescription.anticoagulant_zongliang = ""
  4250. this.dialysisPrescription.anticoagulant_zongliang = parseInt(this.dialysisPrescription.anticoagulant_shouji) + parseInt(this.dialysisPrescription.anticoagulant_weichi)
  4251. }
  4252. },
  4253. 'dialysisPrescription.anticoagulant_weichi': function() {
  4254. let dialysis_duration_minute = 0
  4255. let dialysis_duration_hour = 0
  4256. let duration = 0
  4257. if (this.dialysisPrescription.dialysis_duration_minute == '') {
  4258. dialysis_duration_minute = 0
  4259. } else {
  4260. dialysis_duration_minute = this.dialysisPrescription
  4261. .dialysis_duration_minute
  4262. }
  4263. if (this.dialysisPrescription.dialysis_duration_hour == '') {
  4264. dialysis_duration_hour = 0
  4265. } else {
  4266. dialysis_duration_hour = this.dialysisPrescription
  4267. .dialysis_duration_hour
  4268. }
  4269. duration = parseFloat(dialysis_duration_hour) + parseFloat(dialysis_duration_minute) / 60
  4270. this.dialysisPrescription.anticoagulant_zongliang = calculateAnticoagulantZL(1, this.dialysisPrescription.anticoagulant_shouji, duration, this.dialysisPrescription.anticoagulant_weichi,this.dialysisPrescription.add_amount,this.dialysisPrescription.reduce_amount)
  4271. if (isNaN(this.dialysisPrescription.anticoagulant_zongliang)) {
  4272. this.dialysisPrescription.anticoagulant_zongliang = ''
  4273. }
  4274. this.zongliang = this.dialysisPrescription.anticoagulant_zongliang
  4275. if(this.$store.getters.xt_user.template_info.template_id == 41 && this.dialysisPrescription.anticoagulant == 2){
  4276. this.dialysisPrescription.anticoagulant_zongliang = ""
  4277. this.dialysisPrescription.anticoagulant_zongliang = parseInt(this.dialysisPrescription.anticoagulant_shouji) + parseInt(this.dialysisPrescription.anticoagulant_weichi)
  4278. }
  4279. this.zongliang = this.dialysisPrescription.anticoagulant_zongliang
  4280. },
  4281. 'prescription.id': {
  4282. immediate: true,
  4283. deep: true,
  4284. handler(oldVal, newVal) {
  4285. if (oldVal == newVal) {
  4286. for (var index in this.dialysisPrescription) {
  4287. this.dialysisPrescription[index] = this.prescription[index]
  4288. }
  4289. if (this.prescription['dialysate_formulation'] == 0) {
  4290. this.dialysisPrescription['dialysate_formulation'] = ''
  4291. }
  4292. if (this.prescription['anticoagulant'] == 0) {
  4293. this.dialysisPrescription['anticoagulant'] = ''
  4294. }
  4295. if (this.prescription['dialysis_duration_hour'] == 0) {
  4296. this.dialysisPrescription['dialysis_duration_hour'] = ''
  4297. }
  4298. if (this.prescription['dialysis_duration_minute'] == 0) {
  4299. this.dialysisPrescription['dialysis_duration_minute'] = ''
  4300. }
  4301. if (this.prescription['blood_flow_volume'] == 0) {
  4302. this.dialysisPrescription['blood_flow_volume'] = ''
  4303. }
  4304. if (this.prescription['target_ultrafiltration'] == 0) {
  4305. this.dialysisPrescription['target_ultrafiltration'] = ''
  4306. }
  4307. if (this.prescription['dialysate_temperature'] == 0) {
  4308. this.dialysisPrescription['dialysate_temperature'] = ''
  4309. }
  4310. if (this.prescription['anticoagulant_shouji'] == 0) {
  4311. this.dialysisPrescription['anticoagulant_shouji'] = 0
  4312. }
  4313. if (this.prescription['anticoagulant_weichi'] == 0) {
  4314. this.dialysisPrescription['anticoagulant_weichi'] = 0
  4315. }
  4316. if (this.prescription['anticoagulant_zongliang'] == 0) {
  4317. this.dialysisPrescription['anticoagulant_zongliang'] = 0
  4318. }
  4319. if (this.prescription['anticoagulant_gaijiliang'] == 0) {
  4320. this.dialysisPrescription['anticoagulant_gaijiliang'] = ''
  4321. }
  4322. if (this.prescription['kalium'] == 0) {
  4323. this.dialysisPrescription['kalium'] = ''
  4324. }
  4325. if (this.prescription['sodium'] == 0) {
  4326. this.dialysisPrescription['sodium'] = ''
  4327. }
  4328. if (this.prescription['calcium'] == 0) {
  4329. this.dialysisPrescription['calcium'] = ''
  4330. }
  4331. if (this.prescription['bicarbonate'] == 0) {
  4332. this.dialysisPrescription['bicarbonate'] = ''
  4333. }
  4334. if (this.prescription['glucose'] == 0) {
  4335. this.dialysisPrescription['glucose'] = ''
  4336. }
  4337. if (this.prescription['dialysate_flow'] == 0) {
  4338. this.dialysisPrescription['dialysate_flow'] = ''
  4339. }
  4340. if (this.prescription['conductivity'] == 0) {
  4341. this.dialysisPrescription['conductivity'] = ''
  4342. }
  4343. if (this.prescription['replacement_total'] == 0) {
  4344. this.dialysisPrescription['replacement_total'] = ''
  4345. }
  4346. if (this.prescription['target_ktv'] == 0) {
  4347. this.dialysisPrescription['target_ktv'] = ''
  4348. }
  4349. }
  4350. if (this.prescription.id > 0) {
  4351. for (var index in this.dialysisPrescription) {
  4352. this.dialysisPrescription[index] = this.prescription[index]
  4353. }
  4354. if (this.prescription['dialysate_formulation'] == 0) {
  4355. this.dialysisPrescription['dialysate_formulation'] = ''
  4356. }
  4357. if (this.prescription['anticoagulant'] == 0) {
  4358. this.dialysisPrescription['anticoagulant'] = ''
  4359. }
  4360. if (this.prescription['dialysis_duration_hour'] == 0) {
  4361. this.dialysisPrescription['dialysis_duration_hour'] = ''
  4362. }
  4363. if (this.prescription['dialysis_duration_minute'] == 0) {
  4364. this.dialysisPrescription['dialysis_duration_minute'] = ''
  4365. }
  4366. if (this.prescription['blood_flow_volume'] == 0) {
  4367. this.dialysisPrescription['blood_flow_volume'] = ''
  4368. }
  4369. if (this.prescription['target_ultrafiltration'] == 0) {
  4370. this.dialysisPrescription['target_ultrafiltration'] = ''
  4371. }
  4372. if (this.prescription['dialysate_temperature'] == 0) {
  4373. this.dialysisPrescription['dialysate_temperature'] = ''
  4374. }
  4375. if (this.prescription['anticoagulant_shouji'] == 0) {
  4376. this.dialysisPrescription['anticoagulant_shouji'] = 0
  4377. }
  4378. if (this.prescription['anticoagulant_weichi'] == 0) {
  4379. this.dialysisPrescription['anticoagulant_weichi'] = 0
  4380. }
  4381. if (this.prescription['anticoagulant_zongliang'] == 0) {
  4382. this.dialysisPrescription['anticoagulant_zongliang'] = 0
  4383. }
  4384. if (this.prescription['anticoagulant_gaijiliang'] == 0) {
  4385. this.dialysisPrescription['anticoagulant_gaijiliang'] = ''
  4386. }
  4387. if (this.prescription['kalium'] == 0) {
  4388. this.dialysisPrescription['kalium'] = ''
  4389. }
  4390. if (this.prescription['sodium'] == 0) {
  4391. this.dialysisPrescription['sodium'] = ''
  4392. }
  4393. if (this.prescription['calcium'] == 0) {
  4394. this.dialysisPrescription['calcium'] = ''
  4395. }
  4396. if (this.prescription['bicarbonate'] == 0) {
  4397. this.dialysisPrescription['bicarbonate'] = ''
  4398. }
  4399. if (this.prescription['glucose'] == 0) {
  4400. this.dialysisPrescription['glucose'] = ''
  4401. }
  4402. if (this.prescription['dialysate_flow'] == 0) {
  4403. this.dialysisPrescription['dialysate_flow'] = ''
  4404. }
  4405. if (this.prescription['conductivity'] == 0) {
  4406. this.dialysisPrescription['conductivity'] = ''
  4407. }
  4408. if (this.prescription['replacement_total'] == 0) {
  4409. this.dialysisPrescription['replacement_total'] = ''
  4410. }
  4411. if (this.prescription['target_ktv'] == 0) {
  4412. this.dialysisPrescription['target_ktv'] = ''
  4413. }
  4414. } else if (this.prescription.id == 0) {
  4415. for (var index in this.dialysisPrescription) {
  4416. this.dialysisPrescription[index] = this.prescription[index]
  4417. }
  4418. if (this.prescription['dialysate_formulation'] == 0) {
  4419. this.dialysisPrescription['dialysate_formulation'] = ''
  4420. }
  4421. if (this.prescription['anticoagulant'] == 0) {
  4422. this.dialysisPrescription['anticoagulant'] = ''
  4423. }
  4424. if (this.prescription['dialysis_duration_hour'] == 0) {
  4425. this.dialysisPrescription['dialysis_duration_hour'] = ''
  4426. }
  4427. if (this.prescription['dialysis_duration_minute'] == 0) {
  4428. this.dialysisPrescription['dialysis_duration_minute'] = ''
  4429. }
  4430. if (this.prescription['blood_flow_volume'] == 0) {
  4431. this.dialysisPrescription['blood_flow_volume'] = ''
  4432. }
  4433. if (this.prescription['target_ultrafiltration'] == 0) {
  4434. this.dialysisPrescription['target_ultrafiltration'] = ''
  4435. }
  4436. if (this.prescription['dialysate_temperature'] == 0) {
  4437. this.dialysisPrescription['dialysate_temperature'] = ''
  4438. }
  4439. if (this.prescription['anticoagulant_shouji'] == 0) {
  4440. this.dialysisPrescription['anticoagulant_'] = 0
  4441. }
  4442. if (this.prescription['anticoagulant_weichi'] == 0) {
  4443. this.dialysisPrescription['anticoagulant_weichi'] = 0
  4444. }
  4445. if (this.prescription['anticoagulant_zongliang'] == 0) {
  4446. this.dialysisPrescription['anticoagulant_zongliang'] = 0
  4447. }
  4448. if (this.prescription['anticoagulant_gaijiliang'] == 0) {
  4449. this.dialysisPrescription['anticoagulant_gaijiliang'] = ''
  4450. }
  4451. if (this.prescription['kalium'] == 0) {
  4452. this.dialysisPrescription['kalium'] = ''
  4453. }
  4454. if (this.prescription['sodium'] == 0) {
  4455. this.dialysisPrescription['sodium'] = ''
  4456. }
  4457. if (this.prescription['calcium'] == 0) {
  4458. this.dialysisPrescription['calcium'] = ''
  4459. }
  4460. if (this.prescription['bicarbonate'] == 0) {
  4461. this.dialysisPrescription['bicarbonate'] = ''
  4462. }
  4463. if (this.prescription['glucose'] == 0) {
  4464. this.dialysisPrescription['glucose'] = ''
  4465. }
  4466. if (this.prescription['dialysate_flow'] == 0) {
  4467. this.dialysisPrescription['dialysate_flow'] = ''
  4468. }
  4469. if (this.prescription['conductivity'] == 0) {
  4470. this.dialysisPrescription['conductivity'] = ''
  4471. }
  4472. if (this.prescription['replacement_total'] == 0) {
  4473. this.dialysisPrescription['replacement_total'] = ''
  4474. }
  4475. if (this.prescription['target_ktv'] == 0) {
  4476. this.dialysisPrescription['target_ktv'] = ''
  4477. }
  4478. }
  4479. }
  4480. },
  4481. 'solution.id': function() {
  4482. if (this.solution.id > 0) {
  4483. if (
  4484. this.prescription != null &&
  4485. typeof this.prescription.id !== 'undefined' &&
  4486. this.prescription.id > 0
  4487. ) {
  4488. for (const key in this.prescription) {
  4489. this.dialysisPrescription[key] = this.prescription[key]
  4490. }
  4491. if (this.prescription['dialysate_formulation'] == 0) {
  4492. this.dialysisPrescription['dialysate_formulation'] = ''
  4493. }
  4494. if (this.prescription['anticoagulant'] == 0) {
  4495. this.dialysisPrescription['anticoagulant'] = ''
  4496. }
  4497. if (this.prescription['dialysis_duration_hour'] == 0) {
  4498. this.dialysisPrescription['dialysis_duration_hour'] = ''
  4499. }
  4500. if (this.prescription['dialysis_duration_minute'] == 0) {
  4501. this.dialysisPrescription['dialysis_duration_minute'] = ''
  4502. }
  4503. if (this.prescription['blood_flow_volume'] == 0) {
  4504. this.dialysisPrescription['blood_flow_volume'] = ''
  4505. }
  4506. if (this.prescription['target_ultrafiltration'] == 0) {
  4507. this.dialysisPrescription['target_ultrafiltration'] = ''
  4508. }
  4509. if (this.prescription['dialysate_temperature'] == 0) {
  4510. this.dialysisPrescription['dialysate_temperature'] = ''
  4511. }
  4512. if (this.prescription['anticoagulant_shouji'] == 0) {
  4513. this.dialysisPrescription['anticoagulant_shouji'] = 0
  4514. }
  4515. if (this.prescription['anticoagulant_weichi'] == 0) {
  4516. this.dialysisPrescription['anticoagulant_weichi'] = 0
  4517. }
  4518. if (this.prescription['anticoagulant_zongliang'] == 0) {
  4519. this.dialysisPrescription['anticoagulant_zongliang'] = 0
  4520. }
  4521. if (this.prescription['anticoagulant_gaijiliang'] == 0) {
  4522. this.dialysisPrescription['anticoagulant_gaijiliang'] = ''
  4523. }
  4524. if (this.prescription['kalium'] == 0) {
  4525. this.dialysisPrescription['kalium'] = ''
  4526. }
  4527. if (this.prescription['sodium'] == 0) {
  4528. this.dialysisPrescription['sodium'] = ''
  4529. }
  4530. if (this.prescription['calcium'] == 0) {
  4531. this.dialysisPrescription['calcium'] = ''
  4532. }
  4533. if (this.prescription['bicarbonate'] == 0) {
  4534. this.dialysisPrescription['bicarbonate'] = ''
  4535. }
  4536. if (this.prescription['glucose'] == 0) {
  4537. this.dialysisPrescription['glucose'] = ''
  4538. }
  4539. if (this.prescription['dialysate_flow'] == 0) {
  4540. this.dialysisPrescription['dialysate_flow'] = ''
  4541. }
  4542. if (this.prescription['conductivity'] == 0) {
  4543. this.dialysisPrescription['conductivity'] = ''
  4544. }
  4545. if (this.prescription['replacement_total'] == 0) {
  4546. this.dialysisPrescription['replacement_total'] = ''
  4547. }
  4548. if (this.prescription['target_ktv'] == 0) {
  4549. this.dialysisPrescription['target_ktv'] = ''
  4550. }
  4551. } else if (
  4552. this.solution != null &&
  4553. typeof this.solution.id !== 'undefined' &&
  4554. this.solution.id
  4555. ) {
  4556. for (const key in this.solution) {
  4557. this.dialysisPrescription[key] = this.solution[key]
  4558. }
  4559. if (this.solution['dialysate_formulation'] == 0) {
  4560. this.dialysisPrescription['dialysate_formulation'] = ''
  4561. }
  4562. if (this.solution['anticoagulant'] == 0) {
  4563. this.dialysisPrescription['anticoagulant'] = ''
  4564. }
  4565. if (this.solution['dialysis_duration_hour'] == 0) {
  4566. this.dialysisPrescription['dialysis_duration_hour'] = ''
  4567. }
  4568. if (this.solution['dialysis_duration_minute'] == 0) {
  4569. this.dialysisPrescription['dialysis_duration_minute'] = ''
  4570. }
  4571. if (this.solution['blood_flow_volume'] == 0) {
  4572. this.dialysisPrescription['blood_flow_volume'] = ''
  4573. }
  4574. if (this.solution['target_ultrafiltration'] == 0) {
  4575. this.dialysisPrescription['target_ultrafiltration'] = ''
  4576. }
  4577. if (this.solution['dialysate_temperature'] == 0) {
  4578. this.dialysisPrescription['dialysate_temperature'] = ''
  4579. }
  4580. if (this.solution['anticoagulant_shouji'] == 0) {
  4581. this.dialysisPrescription['anticoagulant_shouji'] = 0
  4582. }
  4583. if (this.solution['anticoagulant_weichi'] == 0) {
  4584. this.dialysisPrescription['anticoagulant_weichi'] = 0
  4585. }
  4586. if (this.solution['anticoagulant_zongliang'] == 0) {
  4587. this.dialysisPrescription['anticoagulant_zongliang'] = 0
  4588. }
  4589. if (this.solution['anticoagulant_gaijiliang'] == 0) {
  4590. this.dialysisPrescription['anticoagulant_gaijiliang'] = ''
  4591. }
  4592. if (this.solution['kalium'] == 0) {
  4593. this.dialysisPrescription['kalium'] = ''
  4594. }
  4595. if (this.solution['sodium'] == 0) {
  4596. this.dialysisPrescription['sodium'] = ''
  4597. }
  4598. if (this.solution['calcium'] == 0) {
  4599. this.dialysisPrescription['calcium'] = ''
  4600. }
  4601. if (this.solution['bicarbonate'] == 0) {
  4602. this.dialysisPrescription['bicarbonate'] = ''
  4603. }
  4604. if (this.solution['glucose'] == 0) {
  4605. this.dialysisPrescription['glucose'] = ''
  4606. }
  4607. if (this.solution['dialysate_flow'] == 0) {
  4608. this.dialysisPrescription['dialysate_flow'] = ''
  4609. }
  4610. if (this.solution['conductivity'] == 0) {
  4611. this.dialysisPrescription['conductivity'] = ''
  4612. }
  4613. if (this.solution['replacement_total'] == 0) {
  4614. this.dialysisPrescription['replacement_total'] = ''
  4615. }
  4616. if (this.solution['target_ktv'] == 0) {
  4617. this.dialysisPrescription['target_ktv'] = ''
  4618. }
  4619. }
  4620. }
  4621. },
  4622. 'dialysisPrescription.add_amount': function() {
  4623. let dialysis_duration_minute = 0
  4624. let dialysis_duration_hour = 0
  4625. let duration = 0
  4626. if (this.dialysisPrescription.dialysis_duration_minute == '') {
  4627. dialysis_duration_minute = 0
  4628. } else {
  4629. dialysis_duration_minute = this.dialysisPrescription
  4630. .dialysis_duration_minute
  4631. }
  4632. if (this.dialysisPrescription.dialysis_duration_hour == '') {
  4633. dialysis_duration_hour = 0
  4634. } else {
  4635. dialysis_duration_hour = this.dialysisPrescription
  4636. .dialysis_duration_hour
  4637. }
  4638. duration =
  4639. parseFloat(dialysis_duration_hour) +
  4640. parseFloat(dialysis_duration_minute) / 60
  4641. this.dialysisPrescription.anticoagulant_zongliang = calculateAnticoagulantZL(
  4642. 1,
  4643. this.dialysisPrescription.anticoagulant_shouji,
  4644. duration,
  4645. this.dialysisPrescription.anticoagulant_weichi,
  4646. this.dialysisPrescription.add_amount,
  4647. this.dialysisPrescription.reduce_amount
  4648. )
  4649. this.zongliang = this.dialysisPrescription.anticoagulant_zongliang
  4650. if (isNaN(this.dialysisPrescription.anticoagulant_zongliang)) {
  4651. this.dialysisPrescription.anticoagulant_zongliang = ''
  4652. }
  4653. if(this.$store.getters.xt_user.template_info.template_id == 41 && this.dialysisPrescription.anticoagulant == 2){
  4654. this.dialysisPrescription.anticoagulant_zongliang = ""
  4655. this.dialysisPrescription.anticoagulant_zongliang = parseInt(this.dialysisPrescription.anticoagulant_shouji) + parseInt(this.dialysisPrescription.anticoagulant_weichi)
  4656. }
  4657. },
  4658. 'dialysisPrescription.reduce_amount': function() {
  4659. let dialysis_duration_minute = 0
  4660. let dialysis_duration_hour = 0
  4661. let duration = 0
  4662. if (this.dialysisPrescription.dialysis_duration_minute == '') {
  4663. dialysis_duration_minute = 0
  4664. } else {
  4665. dialysis_duration_minute = this.dialysisPrescription
  4666. .dialysis_duration_minute
  4667. }
  4668. if (this.dialysisPrescription.dialysis_duration_hour == '') {
  4669. dialysis_duration_hour = 0
  4670. } else {
  4671. dialysis_duration_hour = this.dialysisPrescription
  4672. .dialysis_duration_hour
  4673. }
  4674. duration =
  4675. parseFloat(dialysis_duration_hour) +
  4676. parseFloat(dialysis_duration_minute) / 60
  4677. this.dialysisPrescription.anticoagulant_zongliang = calculateAnticoagulantZL(
  4678. 1,
  4679. this.dialysisPrescription.anticoagulant_shouji,
  4680. duration,
  4681. this.dialysisPrescription.anticoagulant_weichi,
  4682. this.dialysisPrescription.add_amount,
  4683. this.dialysisPrescription.reduce_amount
  4684. )
  4685. this.zongliang = this.dialysisPrescription.anticoagulant_zongliang
  4686. if (isNaN(this.dialysisPrescription.anticoagulant_zongliang)) {
  4687. this.dialysisPrescription.anticoagulant_zongliang = ''
  4688. }
  4689. if(this.$store.getters.xt_user.template_info.template_id == 41 && this.dialysisPrescription.anticoagulant == 2){
  4690. this.dialysisPrescription.anticoagulant_zongliang = ""
  4691. this.dialysisPrescription.anticoagulant_zongliang = parseInt(this.dialysisPrescription.anticoagulant_shouji) + parseInt(this.dialysisPrescription.anticoagulant_weichi)
  4692. }
  4693. },
  4694. stockType: function() {
  4695. console.log('stockType', this.stockType)
  4696. var arr = []
  4697. var arrTwo = []
  4698. var arrThree = []
  4699. for (let i = 0; i < this.stockType.length; i++) {
  4700. if (this.stockType[i].stock_attribute == 2) {
  4701. arr.push(this.stockType[i])
  4702. }
  4703. if (this.stockType[i].stock_attribute == 3) {
  4704. arrTwo.push(this.stockType[i])
  4705. }
  4706. if(this.stockType[i].stock_attribute == 4){
  4707. arrThree.push(this.stockType[i])
  4708. }
  4709. }
  4710. var dialyzator = []
  4711. var irrigation = []
  4712. var dialysis_strainer = []
  4713. for (let i = 0; i < arr.length; i++) {
  4714. for (let j = 0; j < arr[i].GoodInfo.length; j++) {
  4715. dialyzator.push(arr[i].GoodInfo[j])
  4716. }
  4717. }
  4718. this.dialyzers = dialyzator
  4719. for (let i = 0; i < arrTwo.length; i++) {
  4720. for (let j = 0; j < arrTwo[i].GoodInfo.length; j++) {
  4721. irrigation.push(arrTwo[i].GoodInfo[j])
  4722. }
  4723. }
  4724. this.irrigations = irrigation
  4725. for(let i=0;i<arrThree.length;i++){
  4726. for (let j = 0; j < arrThree[i].GoodInfo.length; j++) {
  4727. dialysis_strainer.push(arrThree[i].GoodInfo[j])
  4728. }
  4729. }
  4730. this.dialysisStrainerList = dialysis_strainer
  4731. },
  4732. admin_user_id:function(){
  4733. console.log("处方医生",this.admins)
  4734. if(this.admins.length > 0 ){
  4735. for(let i=0;i<this.admins.length;i++){
  4736. this.adminRoles.push(this.admins[i])
  4737. }
  4738. }
  4739. console.log(" 人员",this.adminRoles)
  4740. }
  4741. },
  4742. created() {
  4743. this.illnessList = getDataConfig('hemodialysis', 'illness')
  4744. this.blood_access_part = getDataConfig('hemodialysis', 'vascular_access')
  4745. this.plasmaSeparatorList = getDataConfig('hemodialysis', 'plasma_separator')
  4746. this.bilirubinAdsorptionColumn = getDataConfig('hemodialysis', 'bilirubin_adsorption_column')
  4747. this.educationList = getDataConfig('dialysis_remark', 'dialysis_remark')
  4748. }
  4749. }
  4750. </script>
  4751. <style rel="stylesheet/scss" lang="scss" scoped>
  4752. .el-checkbox,
  4753. .el-checkbox__input {
  4754. vertical-align: middle;
  4755. }
  4756. .newLine {
  4757. display: flex;
  4758. justify-content: space-between;
  4759. height: 40px;
  4760. line-height: 40px;
  4761. border-bottom: 1px solid #ccc;
  4762. color: #303133;
  4763. }
  4764. .warnTxt {
  4765. text-align: center;
  4766. margin: 0 auto;
  4767. background: #faa331;
  4768. max-width: 240px;
  4769. padding: 10px 20px;
  4770. border-radius: 4px;
  4771. margin-bottom: 10px;
  4772. color: #fff;
  4773. }
  4774. </style>
  4775. <style lang="scss">
  4776. .newDialog {
  4777. .el-dialog__body {
  4778. padding: 10px 20px 30px;
  4779. }
  4780. }
  4781. </style>