血透系统PC前端

home.vue 209KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221422242234224422542264227422842294230423142324233423442354236423742384239424042414242424342444245424642474248424942504251425242534254425542564257425842594260426142624263426442654266426742684269427042714272427342744275427642774278427942804281428242834284428542864287428842894290429142924293429442954296429742984299430043014302430343044305430643074308430943104311431243134314431543164317431843194320432143224323432443254326432743284329433043314332433343344335433643374338433943404341434243434344434543464347434843494350435143524353435443554356435743584359436043614362436343644365436643674368436943704371437243734374437543764377437843794380438143824383438443854386438743884389439043914392439343944395439643974398439944004401440244034404440544064407440844094410441144124413441444154416441744184419442044214422442344244425442644274428442944304431443244334434443544364437443844394440444144424443444444454446444744484449445044514452445344544455445644574458445944604461446244634464446544664467446844694470447144724473447444754476447744784479448044814482448344844485448644874488448944904491449244934494449544964497449844994500450145024503450445054506450745084509451045114512451345144515451645174518451945204521452245234524452545264527452845294530453145324533453445354536453745384539454045414542454345444545454645474548454945504551455245534554455545564557455845594560456145624563456445654566456745684569457045714572457345744575457645774578457945804581458245834584458545864587458845894590459145924593459445954596459745984599460046014602460346044605460646074608460946104611461246134614461546164617461846194620462146224623462446254626
  1. <template>
  2. <div class="main-contain">
  3. <div class="position">
  4. <bread-crumb :crumbs='crumbs'></bread-crumb>
  5. </div>
  6. <div class="app-container">
  7. <el-container>
  8. <div style="width:22%">
  9. <el-row>
  10. <el-col :span="24">
  11. <span class="zone">分&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;区:</span>
  12. <el-select v-model="forms.zone_id" placeholder="请选择" class="a" @change="changeBedNumber" style="width:70%" :disabled="zoneDisabled">
  13. <el-option
  14. v-for="item in bedZone"
  15. :key="item.id"
  16. :label="item.name"
  17. :value="item.id"
  18. >
  19. </el-option>
  20. </el-select>
  21. </el-col>
  22. </el-row>
  23. <!-- <el-row>-->
  24. <!-- <el-col>-->
  25. <!-- <span class="zone">班&nbsp;&nbsp;&nbsp;&nbsp;次:</span>-->
  26. <!-- <el-select v-model="forms.class_id" placeholder="请选择" class="a" @change="changeClassId" style="width:125px">-->
  27. <!-- <el-option-->
  28. <!-- v-for="item in Classes"-->
  29. <!-- :key="item.id"-->
  30. <!-- :label="item.name"-->
  31. <!-- :value="item.id">-->
  32. <!-- </el-option>-->
  33. <!-- </el-select>-->
  34. <!-- </el-col>-->
  35. <!-- </el-row>-->
  36. <el-row>
  37. <el-col>
  38. <span class="zone">设备类型:</span>
  39. <el-select v-model="forms.device_type" placeholder="请选择" class="a" @change="changeDeviceId" style="width:70%">
  40. <el-option
  41. v-for="item in DeviceTypeType"
  42. :key="item.id"
  43. :label="item.name"
  44. :value="item.id">
  45. </el-option>
  46. </el-select>
  47. </el-col>
  48. </el-row>
  49. <el-row>
  50. <el-table
  51. ref="singleTable"
  52. :data="tableDatatwo"
  53. highlight-current-row
  54. border
  55. @current-change="handleCurrentChange"
  56. height="440"
  57. :row-style="{ color: '#303133' }"
  58. :header-cell-style="{
  59. backgroundColor: 'rgb(245, 247, 250)',
  60. color: '#606266'
  61. }"
  62. >
  63. <el-table-column
  64. prop="date"
  65. label="设备名称"
  66. width="90"
  67. align="center"
  68. >
  69. <template slot-scope="scope">
  70. <div @click="handleIndex(scope.$index)">{{scope.row.device_name}}</div>
  71. </template>
  72. </el-table-column>
  73. <el-table-column
  74. prop="name"
  75. label="设备型号"
  76. width="90"
  77. align="center">
  78. <template slot-scope="scope">
  79. <div @click="handleIndex(scope.$index)">{{scope.row.device_mode}}</div>
  80. </template>
  81. </el-table-column>
  82. <el-table-column
  83. prop="address"
  84. label="机位号"
  85. align="center"
  86. widwid="60">
  87. <template slot-scope="scope">
  88. <div @click="handleIndex(scope.$index)">{{scope.row.bed_number}}</div>
  89. </template>
  90. </el-table-column>
  91. </el-table>
  92. </el-row>
  93. </div>
  94. <el-main>
  95. <div class="main newMain">
  96. <div class="newButtonOne">
  97. <el-button
  98. type="success"
  99. @click="clickQuery()"
  100. >
  101. 综合查询
  102. </el-button>
  103. </div>
  104. <el-tabs v-model="activeName" @tab-click="handleClick">
  105. <!-- 透析机基本信息 -->
  106. <el-tab-pane label="基本信息" name="first" >
  107. <!-- 透析机基本信息 -->
  108. <div class="disinfectOne newDisinfectOne" v-show="tShow">
  109. <el-row>
  110. <div class="b">
  111. <el-button @click="UpdateMachine()">修改</el-button>
  112. </div>
  113. </el-row>
  114. <el-row>
  115. <el-form :model="form" ref="form" :rules="rules">
  116. <el-row>
  117. <el-col :span="8">
  118. <el-form-item label="序列号:" required prop="serial_number">
  119. <el-input style="width:150px" v-model="form.serial_number" :disabled="disableThree"></el-input>
  120. </el-form-item>
  121. </el-col>
  122. <el-col :span="8">
  123. <el-form-item label="设备类型:" required prop="devicetype">
  124. <el-select style="width:150px" v-model="form.devicetype" :disabled="true">
  125. <el-option v-for="item in this.DeviceTypes" :key="item.id" :label="item.name" :value="item.id" ></el-option>
  126. </el-select>
  127. </el-form-item>
  128. </el-col>
  129. <el-col :span="8">
  130. <el-form-item label="机位号:">
  131. <el-select style="width:150px" v-model="form.bed_number" :disabled="disableThree">
  132. <el-option v-for="item in this.Number" :key="item.bed_id" :label="item.bed_number" :value="item.bed_id"></el-option>
  133. </el-select>
  134. </el-form-item>
  135. </el-col>
  136. </el-row>
  137. <el-row>
  138. <el-col :span="8">
  139. <el-form-item label="设备名称:" required prop="device_name">
  140. <el-input style="width:150px" v-model="form.device_name" :disabled="disableThree"></el-input>
  141. </el-form-item>
  142. </el-col>
  143. <el-col :span="8">
  144. <el-form-item label="生产厂家:">
  145. <el-input style="width:150px" v-model="form.manufacture_factory" :disabled="disableThree"></el-input>
  146. </el-form-item>
  147. </el-col>
  148. <el-col :span="8">
  149. <el-form-item label="维修厂家:">
  150. <el-input style="width:150px" v-model="form.service_manufacturer" :disabled="disableThree"></el-input>
  151. </el-form-item>
  152. </el-col>
  153. </el-row>
  154. <el-row>
  155. <el-col :span="8">
  156. <el-form-item label="设备型号:" required prop="unit_type">
  157. <el-select style="width:150px" v-model="form.unit_type" :disabled="disableThree">
  158. <el-option
  159. v-for="item in this.deviceMode"
  160. :key="item.id"
  161. :label="item.device_mode"
  162. :value="item.id"
  163. ></el-option>
  164. </el-select>
  165. </el-form-item>
  166. </el-col>
  167. <el-col :span="8">
  168. <el-form-item label="使用科室:">
  169. <el-input style="width:150px" v-model="form.use_section" :disabled="disableThree"></el-input>
  170. </el-form-item>
  171. </el-col>
  172. <el-col :span="8">
  173. <el-form-item label="科室编号:">
  174. <el-input style="width:150px" v-model="form.section_number" :disabled="disableThree"></el-input>
  175. </el-form-item>
  176. </el-col>
  177. </el-row>
  178. <el-row>
  179. <el-col :span="8">
  180. <el-form-item label="购买日期:">
  181. <el-date-picker
  182. v-model="form.buy_date"
  183. prefix-icon="none"
  184. type="date"
  185. placeholder="请选择"
  186. format="yyyy-MM-dd"
  187. value-format="yyyy-MM-dd"
  188. style="width:150px"
  189. :disabled="disableThree">
  190. </el-date-picker>
  191. </el-form-item>
  192. </el-col>
  193. <el-col :span="8">
  194. <el-form-item label="安装日期:">
  195. <el-date-picker
  196. v-model="form.install_date"
  197. prefix-icon="none"
  198. type="date"
  199. placeholder="请选择"
  200. format="yyyy-MM-dd"
  201. value-format="yyyy-MM-dd"
  202. style="width:150px"
  203. :disabled="disableThree">
  204. </el-date-picker>
  205. </el-form-item>
  206. </el-col>
  207. <el-col :span="8">
  208. <el-form-item label="启用日期:">
  209. <el-date-picker
  210. v-model="form.start_date"
  211. prefix-icon="none"
  212. type="date"
  213. placeholder="请选择"
  214. format="yyyy-MM-dd"
  215. value-format="yyyy-MM-dd"
  216. style="width:150px"
  217. :disabled="disableThree">
  218. </el-date-picker>
  219. </el-form-item>
  220. </el-col>
  221. <el-col :span="8">
  222. <el-form-item label="维修工程师:">
  223. <el-input style="width:150px" v-model="form.maintenance_engineer" :disabled="disableThree"></el-input>
  224. </el-form-item>
  225. </el-col>
  226. <el-col :span="8">
  227. <el-form-item label="联系电话:">
  228. <el-input style="width:150px" v-model="form.telephone" :disabled="disableThree"></el-input>
  229. </el-form-item>
  230. </el-col>
  231. <el-col :span="8">
  232. <el-form-item label="保修期限:">
  233. <el-input style="width:150px" v-model="form.guarantee_date" :disabled="disableThree"></el-input>
  234. </el-form-item>
  235. </el-col>
  236. </el-row>
  237. <el-row>
  238. <el-col :span="8">
  239. <el-form-item label="机器状态:">
  240. <el-select style="width:150px" v-model="form.machine_status" @change="changeMachineStatus">
  241. <el-option v-for="item in machineStatus" :key="item.id" :label="item.name" :value="item.id" :disabled="disableThree"></el-option>
  242. </el-select>
  243. </el-form-item>
  244. </el-col>
  245. <el-col :span="8">
  246. <el-form-item label="初次使用次数:">
  247. <el-input v-model="form.user_total" style="width:150px" :disabled="disableThree"></el-input>
  248. </el-form-item>
  249. </el-col>
  250. <el-col :span="8">
  251. <el-form-item label="备注:">
  252. <el-input style="width:150px" v-model="form.remarks" :disabled="disableThree"></el-input>
  253. </el-form-item>
  254. </el-col>
  255. </el-row>
  256. <el-row>
  257. <el-col :span="8">
  258. <el-form-item label="报废日期:">
  259. <el-date-picker
  260. v-model="form.rubbish_date"
  261. prefix-icon="none"
  262. type="date"
  263. placeholder="请选择"
  264. format="yyyy-MM-dd"
  265. value-format="yyyy-MM-dd"
  266. style="width:150px"
  267. :disabled="disableThree">
  268. </el-date-picker>
  269. </el-form-item>
  270. </el-col>
  271. <el-col :span="8">
  272. <el-form-item label="报废原因:">
  273. <el-select style="width:150px" v-model="form.rubbish_reason" :disabled="readisable">
  274. <el-option v-for="item in this.DisCardResion" :key="item.id" :label="item.name" :value="item.id" :disabled="disableThree"></el-option>
  275. </el-select>
  276. </el-form-item>
  277. </el-col>
  278. <el-col :span="8">
  279. <el-form-item label="使用年限(年):">
  280. <el-input style="width:150px" v-model="form.user_year" :disabled="disableThree"></el-input>
  281. </el-form-item>
  282. </el-col>
  283. </el-row>
  284. <el-row>
  285. <el-col :span="8">
  286. <el-form-item label="工作时长(时):">
  287. <el-input style="width:150px" v-model="form.work_time" :disabled="disableThree"></el-input>
  288. </el-form-item>
  289. </el-col>
  290. </el-row>
  291. <el-row>
  292. <el-form-item label="治疗模式:">
  293. <el-checkbox-group v-model="form.treat_mode" @change="handleCheckedCitiesChange">
  294. <el-checkbox v-for="city in cities" :label="city" :key="city">{{city}}</el-checkbox>
  295. </el-checkbox-group>
  296. </el-form-item>
  297. </el-row>
  298. <el-row>
  299. <el-col>
  300. <el-checkbox :indeterminate="isIndeterminate" v-model="checkAll" @change="handleCheckAllChange">全选</el-checkbox>
  301. </el-col>
  302. </el-row>
  303. <el-row>
  304. <div class="but">
  305. <el-col :span="12">
  306. <el-button size="medium" v-show="cancelShow" @click="cleanMainchine">取消</el-button>
  307. </el-col>
  308. <el-col :span="8">
  309. <el-button type="primary" size="medium" v-show="confirmShow" @click="UpdateMachineInfo('form')">保存</el-button>
  310. </el-col>
  311. </div>
  312. </el-row>
  313. </el-form>
  314. </el-row>
  315. </div>
  316. <!-- 水处理机基本信息 -->
  317. <div v-show="sShow">
  318. <el-row>
  319. <div class="b">
  320. <el-button size="small" @click="UpdateMachine()">修改</el-button>
  321. </div>
  322. </el-row>
  323. <el-row>
  324. <el-form :model="form" ref="form" :rules="rules">
  325. <el-row>
  326. <el-col :span="7">
  327. <el-form-item label="序列号:" required prop="serial_number">
  328. <el-input style="width:150px" v-model="form.serial_number" :disabled="disableFour"></el-input>
  329. </el-form-item>
  330. </el-col>
  331. <el-col :span="7">
  332. <el-form-item label="设备类型:" required prop="devicetype">
  333. <el-select style="width:150px" v-model="form.devicetype" :disabled="true">
  334. <el-option v-for="item in this.DeviceTypes" :key="item.id" :label="item.name" :value="item.id" :disabled="disableFour" ></el-option>
  335. </el-select>
  336. </el-form-item>
  337. </el-col>
  338. <el-col :span="7">
  339. <el-form-item label="机位号">
  340. <el-input style="width:150px" v-model="form.beds" :disabled="disableFour"></el-input>
  341. </el-form-item>
  342. </el-col>
  343. </el-row>
  344. <el-row>
  345. <el-col :span="7">
  346. <el-form-item label="设备名称:" required prop="device_name">
  347. <el-input style="width:150px" v-model="form.device_name" :disabled="disableFour"></el-input>
  348. </el-form-item>
  349. </el-col>
  350. <el-col :span="7">
  351. <el-form-item label="生产厂家:">
  352. <el-input style="width:150px" v-model="form.manufacture_factory" :disabled="disableFour"></el-input>
  353. </el-form-item>
  354. </el-col>
  355. <el-col :span="7">
  356. <el-form-item label="维修厂家:">
  357. <el-input style="width:150px" v-model="form.service_manufacturer" :disabled="disableFour"></el-input>
  358. </el-form-item>
  359. </el-col>
  360. </el-row>
  361. <el-row>
  362. <el-col :span="7">
  363. <el-form-item label="设备型号:" required prop="unit_type">
  364. <el-select style="width:135px" v-model="form.unit_type" :disabled="disableFour">
  365. <el-option
  366. v-for="item in this.deviceMode"
  367. :key="item.id"
  368. :label="item.device_mode"
  369. :value="item.id"
  370. ></el-option>
  371. </el-select>
  372. </el-form-item>
  373. </el-col>
  374. <el-col :span="7">
  375. <el-form-item label="使用科室:">
  376. <el-input style="width:150px" v-model="form.use_section" :disabled="disableFour"></el-input>
  377. </el-form-item>
  378. </el-col>
  379. <el-col :span="7">
  380. <el-form-item label="科室编号:">
  381. <el-input style="width:150px" v-model="form.section_number" :disabled="disableFour"></el-input>
  382. </el-form-item>
  383. </el-col>
  384. </el-row>
  385. <el-row>
  386. <el-col :span="7">
  387. <el-form-item label="购买日期:">
  388. <el-date-picker
  389. v-model="form.buy_date"
  390. prefix-icon="none"
  391. type="date"
  392. placeholder="请选择"
  393. format="yyyy-MM-dd"
  394. value-format="yyyy-MM-dd"
  395. style="width:150px"
  396. :disabled="disableFour">
  397. </el-date-picker>
  398. </el-form-item>
  399. </el-col>
  400. <el-col :span="7">
  401. <el-form-item label="安装日期:">
  402. <el-date-picker
  403. v-model="form.install_date"
  404. prefix-icon="none"
  405. type="date"
  406. placeholder="请选择"
  407. format="yyyy-MM-dd"
  408. value-format="yyyy-MM-dd"
  409. style="width:150px"
  410. :disabled="disableFour">
  411. </el-date-picker>
  412. </el-form-item>
  413. </el-col>
  414. <el-col :span="7">
  415. <el-form-item label="启用日期:">
  416. <el-date-picker
  417. v-model="form.start_date"
  418. prefix-icon="none"
  419. type="date"
  420. placeholder="请选择"
  421. format="yyyy-MM-dd"
  422. value-format="yyyy-MM-dd"
  423. style="width:150px"
  424. :disabled="disableFour">
  425. </el-date-picker>
  426. </el-form-item>
  427. </el-col>
  428. <el-col :span="7">
  429. <el-form-item label="维修工程师:">
  430. <el-input style="width:150px" v-model="form.maintenance_engineer" :disabled="disableFour"></el-input>
  431. </el-form-item>
  432. </el-col>
  433. <el-col :span="7">
  434. <el-form-item label="联系电话:">
  435. <el-input style="width:150px" v-model="form.telephone" :disabled="disableFour"></el-input>
  436. </el-form-item>
  437. </el-col>
  438. <el-col :span="7">
  439. <el-form-item label="保修期限:">
  440. <el-input style="width:150px" v-model="form.guarantee_date" :disabled="disableFour"></el-input>
  441. </el-form-item>
  442. </el-col>
  443. </el-row>
  444. <el-row>
  445. <el-col :span="7">
  446. <el-form-item label="机器状态:">
  447. <el-select style="width:150px" v-model="form.machine_status" :disabled="disableFour">
  448. <el-option v-for="item in machineStatus" :key="item.id" :label="item.name" :value="item.id" ></el-option>
  449. </el-select>
  450. </el-form-item>
  451. </el-col>
  452. <el-col :span="7">
  453. <el-form-item label="消毒方式:">
  454. <el-select style="width:135px" v-model="form.Disinfection_mode" :disabled="disableFour">
  455. <el-option
  456. v-for="item in this.DisinfectionMode"
  457. :key="item.id"
  458. :label="item.name"
  459. :value="item.id"
  460. ></el-option>
  461. </el-select>
  462. </el-form-item>
  463. </el-col>
  464. <el-col :span="7">
  465. <el-form-item label="备注:">
  466. <el-input style="width:150px" v-model="form.remarks" :disabled="disableFour"></el-input>
  467. </el-form-item>
  468. </el-col>
  469. </el-row>
  470. <el-row>
  471. <el-col :span="7">
  472. <el-form-item label="报废日期:">
  473. <el-date-picker
  474. v-model="form.rubbish_date"
  475. prefix-icon="none"
  476. type="date"
  477. placeholder="请选择"
  478. format="yyyy-MM-dd"
  479. value-format="yyyy-MM-dd"
  480. style="width:135px"
  481. :disabled="disableFour">
  482. </el-date-picker>
  483. </el-form-item>
  484. </el-col>
  485. <el-col :span="7">
  486. <el-form-item label="报废原因:">
  487. <el-select style="width:150px" v-model="form.rubbish_reason" :disabled="disableFour">
  488. <el-option v-for="item in this.DisCardResion" :key="item.id" :label="item.name" :value="item.id" ></el-option>
  489. </el-select>
  490. </el-form-item>
  491. </el-col>
  492. <el-col :span="7">
  493. <el-form-item label="使用年限(年):">
  494. <el-input style="width:150px" v-model="form.user_year" :disabled="disableFour"></el-input>
  495. </el-form-item>
  496. </el-col>
  497. </el-row>
  498. <el-row>
  499. <el-col :span="8">
  500. <el-form-item label="工作时长(h):">
  501. <el-input style="width:150px" v-model="form.work_time" :disabled="disableFour"></el-input>
  502. </el-form-item>
  503. </el-col>
  504. <el-col :span="8">
  505. <el-form-item label="反渗模式:">
  506. <el-select style="width:135px" v-model="form.revers_mode" :disabled="disableFour">
  507. <el-option
  508. v-for="item in this.reverseMode"
  509. :key="item.id"
  510. :label="item.name"
  511. :value="item.id"
  512. ></el-option>
  513. </el-select>
  514. </el-form-item>
  515. </el-col>
  516. </el-row>
  517. <el-row>
  518. <div class="but">
  519. <el-col :span="12">
  520. <el-button size="medium" v-show="cancelShow" @click="cleanMainchine">取消</el-button>
  521. </el-col>
  522. <el-col :span="8">
  523. <el-button type="primary" size="medium" v-show="confirmShow" @click="UpdateMachineInfoTwo('form')">保存</el-button>
  524. </el-col>
  525. </div>
  526. </el-row>
  527. </el-form>
  528. </el-row>
  529. </div>
  530. <!-- 其他信息 -->
  531. <div v-show="qShow" class="disinfectOne">
  532. <el-row>
  533. <div class="b">
  534. <el-button size="small" @click="UpdateMachine()">修改</el-button>
  535. </div>
  536. </el-row>
  537. <el-form :model="form" ref="form" :rules="rules">
  538. <el-row>
  539. <el-col :span="8">
  540. <el-form-item label="序列号:" required prop="serial_number">
  541. <el-input style="width:150px" v-model="form.serial_number" :disabled="disableFive"></el-input>
  542. </el-form-item>
  543. </el-col>
  544. <el-col :span="8">
  545. <el-form-item label="设备类型:" required prop="devicetype">
  546. <el-select style="width:150px" v-model="form.devicetype" :disabled="true">
  547. <el-option v-for="item in this.DeviceTypes" :key="item.id" :label="item.name" :value="item.id" ></el-option>
  548. </el-select>
  549. </el-form-item>
  550. </el-col>
  551. <el-col :span="8">
  552. <el-form-item label="机位号:">
  553. <!-- <el-select style="width:150px" v-model="form.bed_number" :disabled="true">
  554. <el-option v-for="item in this.Number" :key="item.id" :label="item.number" :value="item.id"></el-option>
  555. </el-select> -->
  556. <el-input v-model="form.bed_numbers" style="width:150px" :disabled="disableFive"></el-input>
  557. </el-form-item>
  558. </el-col>
  559. </el-row>
  560. <el-row>
  561. <el-col :span="8">
  562. <el-form-item label="设备名称:" required prop="device_name">
  563. <el-input style="width:150px" v-model="form.device_name" :disabled="disableFive"></el-input>
  564. </el-form-item>
  565. </el-col>
  566. <el-col :span="8">
  567. <el-form-item label="生产厂家:">
  568. <el-input style="width:150px" v-model="form.manufacture_factory" :disabled="disableFive"></el-input>
  569. </el-form-item>
  570. </el-col>
  571. <el-col :span="8">
  572. <el-form-item label="维修厂家:">
  573. <el-input style="width:150px" v-model="form.service_manufacturer" :disabled="disableFive"></el-input>
  574. </el-form-item>
  575. </el-col>
  576. </el-row>
  577. <el-row>
  578. <el-col :span="8">
  579. <el-form-item label="设备型号:" required prop="unit_type">
  580. <el-select style="width:135px" v-model="form.unit_type" :disabled="disableFive">
  581. <el-option
  582. v-for="item in this.deviceMode"
  583. :key="item.id"
  584. :label="item.device_mode"
  585. :value="item.id"
  586. ></el-option>
  587. </el-select>
  588. </el-form-item>
  589. </el-col>
  590. <el-col :span="8">
  591. <el-form-item label="使用科室:">
  592. <el-input style="width:150px" v-model="form.use_section" :disabled="disableFive"></el-input>
  593. </el-form-item>
  594. </el-col>
  595. <el-col :span="8">
  596. <el-form-item label="科室编号:">
  597. <el-input style="width:150px" v-model="form.section_number" :disabled="disableFive"></el-input>
  598. </el-form-item>
  599. </el-col>
  600. </el-row>
  601. <el-row>
  602. <el-col :span="8">
  603. <el-form-item label="购买日期:">
  604. <el-date-picker
  605. v-model="form.buy_date"
  606. prefix-icon="none"
  607. type="date"
  608. placeholder="请选择"
  609. format="yyyy-MM-dd"
  610. value-format="yyyy-MM-dd"
  611. style="width:150px"
  612. :disabled="disableFive">
  613. </el-date-picker>
  614. </el-form-item>
  615. </el-col>
  616. <el-col :span="8">
  617. <el-form-item label="安装日期:">
  618. <el-date-picker
  619. v-model="form.install_date"
  620. prefix-icon="none"
  621. type="date"
  622. placeholder="请选择"
  623. format="yyyy-MM-dd"
  624. value-format="yyyy-MM-dd"
  625. style="width:150px"
  626. :disabled="disableFive">
  627. </el-date-picker>
  628. </el-form-item>
  629. </el-col>
  630. <el-col :span="8">
  631. <el-form-item label="启用日期:">
  632. <el-date-picker
  633. v-model="form.start_date"
  634. prefix-icon="none"
  635. type="date"
  636. placeholder="请选择"
  637. format="yyyy-MM-dd"
  638. value-format="yyyy-MM-dd"
  639. style="width:150px"
  640. :disabled="disableFive">
  641. </el-date-picker>
  642. </el-form-item>
  643. </el-col>
  644. <el-col :span="8">
  645. <el-form-item label="维修工程师:">
  646. <el-input style="width:150px" v-model="form.maintenance_engineer" :disabled="disableFive"></el-input>
  647. </el-form-item>
  648. </el-col>
  649. <el-col :span="8">
  650. <el-form-item label="联系电话:">
  651. <el-input style="width:150px" v-model="form.telephone" :disabled="disableFive"></el-input>
  652. </el-form-item>
  653. </el-col>
  654. <el-col :span="8">
  655. <el-form-item label="保修期限:">
  656. <el-input style="width:150px" v-model="form.guarantee_date" :disabled="disableFive"></el-input>
  657. </el-form-item>
  658. </el-col>
  659. </el-row>
  660. <el-row>
  661. <el-col :span="8">
  662. <el-form-item label="机器状态:">
  663. <el-select style="width:150px" v-model="form.machine_status" @change="changeMachineStatus">
  664. <el-option v-for="item in machineStatus" :key="item.id" :label="item.name" :value="item.id" :disabled="disableFive"></el-option>
  665. </el-select>
  666. </el-form-item>
  667. </el-col>
  668. <el-col :span="8">
  669. <el-form-item label="消毒方式:">
  670. <el-select style="width:135px" v-model="form.Disinfection_mode" :disabled="disableFive">
  671. <el-option
  672. v-for="item in this.DisinfectionMode"
  673. :key="item.id"
  674. :label="item.name"
  675. :value="item.id"
  676. ></el-option>
  677. </el-select>
  678. </el-form-item>
  679. </el-col>
  680. <el-col :span="8">
  681. <el-form-item label="备注:">
  682. <el-input style="width:150px" v-model="form.remarks" :disabled="disableFive"></el-input>
  683. </el-form-item>
  684. </el-col>
  685. </el-row>
  686. <el-row>
  687. <el-col :span="8">
  688. <el-form-item label="报废日期:">
  689. <el-date-picker
  690. v-model="form.rubbish_date"
  691. prefix-icon="none"
  692. type="date"
  693. placeholder="请选择"
  694. format="yyyy-MM-dd"
  695. value-format="yyyy-MM-dd"
  696. style="width:135px"
  697. :disabled="disableFive">
  698. </el-date-picker>
  699. </el-form-item>
  700. </el-col>
  701. <el-col :span="8">
  702. <el-form-item label="报废原因:">
  703. <el-select style="width:150px" v-model="form.rubbish_reason" :disabled="readisable">
  704. <el-option v-for="item in this.DisCardResion" :key="item.id" :label="item.name" :value="item.id" :disabled="disableFive"></el-option>
  705. </el-select>
  706. </el-form-item>
  707. </el-col>
  708. <el-col :span="8">
  709. <el-form-item label="使用年限(年):">
  710. <el-input style="width:150px" v-model="form.user_year" :disabled="disableFive"></el-input>
  711. </el-form-item>
  712. </el-col>
  713. </el-row>
  714. <el-row>
  715. <el-col :span="8">
  716. <el-form-item label="工作时长:">
  717. <el-input style="width:150px" v-model="form.work_time" :disabled="disableFive"></el-input>
  718. </el-form-item>
  719. </el-col>
  720. </el-row>
  721. <el-row>
  722. <div class="but">
  723. <el-col :span="12">
  724. <el-button size="medium" v-show="cancelShow" @click="cleanMainchine">取消</el-button>
  725. </el-col>
  726. <el-col :span="8">
  727. <el-button type="primary" size="medium" v-show="confirmShow" @click="UpdateMacheineTwo('form')">保存</el-button>
  728. </el-col>
  729. </div>
  730. </el-row>
  731. </el-form>
  732. </div>
  733. </el-tab-pane>
  734. <el-tab-pane label="消毒计划" name="second">
  735. <div class="disinfect" v-show="DisShow">
  736. <div class="newButton">
  737. <el-button
  738. type="primary"
  739. size="small"
  740. @click="addPlan"
  741. >
  742. 新增计划
  743. </el-button>
  744. </div>
  745. <el-tabs type="border-card" v-model="activeNameTwo" @tab-click="handleClick" >
  746. <el-tab-pane label="当前设备计划列表" name="first">
  747. <el-row style="display: flex;align-items: center;">
  748. <el-col :span="2">
  749. <el-checkbox style="width: 30px" @change="changeCheckOne" v-model="checkAllStatus">全选</el-checkbox>
  750. </el-col>
  751. <el-col :span="2">
  752. <el-button size="small" @click="openDeleteMahcine">批量删除</el-button>
  753. </el-col>
  754. </el-row>
  755. <el-row>
  756. <el-table
  757. ref="multipleTable"
  758. @selection-change="handleSelectionChangeOne"
  759. :data="planData"
  760. border
  761. fit
  762. highlight-current-row
  763. style="width: 100%;margin-top: 10px;"
  764. :row-style="{ color: '#303133' }"
  765. :header-cell-style="{
  766. backgroundColor: 'rgb(245, 247, 250)',
  767. color: '#606266'
  768. }"
  769. >
  770. <el-table-column align="center" type="selection" width="55"></el-table-column>
  771. <el-table-column label="时间" align="center" min-width="50px">
  772. <template slot-scope="scope">
  773. {{scope.row.time}}
  774. </template>
  775. </el-table-column>
  776. <el-table-column label="班次" align="center" min-width="50px">
  777. <template slot-scope="scope">
  778. {{scope.row.classtime}}
  779. </template>
  780. </el-table-column>
  781. <el-table-column label="机表消毒方式" align="center" min-width="110px" >
  782. <template slot-scope="scope">
  783. {{scope.row.way}}
  784. </template>
  785. </el-table-column>
  786. <el-table-column label="机表消毒液" align="center" min-width="100px" >
  787. <template slot-scope="scope">
  788. {{scope.row.machine_disinfectant}}
  789. </template>
  790. </el-table-column>
  791. <el-table-column label="液路消毒方式" align="center" min-width="110px" >
  792. <template slot-scope="scope">
  793. {{scope.row.disinfectan_way}}
  794. </template>
  795. </el-table-column>
  796. <el-table-column label="液路消毒液" align="center" min-width="100px" >
  797. <template slot-scope="scope">
  798. {{scope.row.disinfectant}}
  799. </template>
  800. </el-table-column>
  801. <el-table-column label="消毒时长/min" align="center" min-width="60px" >
  802. <template slot-scope="scope">
  803. {{scope.row.disinfec_time}}
  804. </template>
  805. </el-table-column>
  806. <el-table-column label="操作" align="center" min-width="130px">
  807. <template slot-scope="scope">
  808. <el-tooltip class="item" effect="dark" content="编辑" placement="top">
  809. <el-button
  810. size="mini"
  811. type="primary"
  812. icon="el-icon-edit-outline"
  813. @click="EditMachine(scope.row.id, scope.$index)"
  814. ></el-button>
  815. </el-tooltip>
  816. <el-tooltip class="item" effect="dark" content="删除" placement="top">
  817. <el-button
  818. size="mini"
  819. type="danger"
  820. icon="el-icon-delete"
  821. @click="openDelete(scope.row.id, scope.$index)"
  822. ></el-button>
  823. </el-tooltip>
  824. </template>
  825. </el-table-column>
  826. </el-table>
  827. </el-row>
  828. </el-tab-pane>
  829. <el-tab-pane label="按机型列表" name="second">
  830. <el-row style="display: flex;align-items: center;">
  831. <el-col :span="2">
  832. <el-checkbox style="width: 30px" @change="changeCheck" v-model="checkAllStatusOne">全选</el-checkbox>
  833. </el-col>
  834. <el-col :span="2">
  835. <el-button size="small" @click="openDeleteMahcineOne">批量删除</el-button>
  836. </el-col>
  837. </el-row>
  838. <el-row>
  839. <el-table
  840. ref="multipleTableOne"
  841. @selection-change="handleSelectionChange"
  842. :row-style="{ color: '#303133' }"
  843. :header-cell-style="{
  844. backgroundColor: 'rgb(245, 247, 250)',
  845. color: '#606266'
  846. }"
  847. :data="tableData"
  848. border
  849. fit
  850. highlight-current-row
  851. style="width: 100%;margin-top: 10px;"
  852. >
  853. <el-table-column align="center" type="selection" width="55"></el-table-column>
  854. <el-table-column label="型号" align="center" min-width="60px">
  855. <template slot-scope="scope">
  856. {{scope.row.device_mode}}
  857. </template>
  858. </el-table-column>
  859. <el-table-column label="时间" align="center" min-width="60px" >
  860. <template slot-scope="scope">
  861. {{scope.row.time}}
  862. </template>
  863. </el-table-column>
  864. <el-table-column label="班次" align="center" min-width="60px" >
  865. <template slot-scope="scope">
  866. {{scope.row.classtime}}
  867. </template>
  868. </el-table-column>
  869. <el-table-column label="基表消毒方式" align="center" min-width="110px" >
  870. <template slot-scope="scope">
  871. {{scope.row.way}}
  872. </template>
  873. </el-table-column>
  874. <el-table-column label="基表消毒液" align="center" min-width="100px" >
  875. <template slot-scope="scope">
  876. {{scope.row.machine_disinfectant}}
  877. </template>
  878. </el-table-column>
  879. <el-table-column label="液路消毒方式" align="center" min-width="110px" >
  880. <template slot-scope="scope">
  881. {{scope.row.disinfectant}}
  882. </template>
  883. </el-table-column>
  884. <el-table-column label="液路消毒液" align="center" min-width="100px" >
  885. <template slot-scope="scope">
  886. {{scope.row.disinfectan_way}}
  887. </template>
  888. </el-table-column>
  889. <el-table-column label="消毒时长/min" align="center" min-width="60px" >
  890. <template slot-scope="scope">
  891. {{scope.row.disinfec_time}}
  892. </template>
  893. </el-table-column>
  894. <el-table-column label="操作" align="center" width="130px">
  895. <template slot-scope="scope">
  896. <el-tooltip class="item" effect="dark" content="编辑" placement="top">
  897. <el-button
  898. size="mini"
  899. type="primary"
  900. icon="el-icon-edit-outline"
  901. @click="EditMachine(scope.row.id, scope.$index)"
  902. ></el-button>
  903. </el-tooltip>
  904. <el-tooltip class="item" effect="dark" content="删除" placement="top">
  905. <el-button
  906. size="mini"
  907. type="danger"
  908. icon="el-icon-delete"
  909. @click="openDelete(scope.row.id, scope.$index)"
  910. ></el-button>
  911. </el-tooltip>
  912. </template>
  913. </el-table-column>
  914. </el-table>
  915. </el-row>
  916. </el-tab-pane>
  917. </el-tabs>
  918. </div>
  919. <div class="zClass" v-show="DioShow">
  920. 暂无数据
  921. </div>
  922. </el-tab-pane>
  923. <el-tab-pane label="使用登记" name="third">
  924. <div class="userbutton">
  925. <el-button type="primary" @click="ToReminders">自动生成使用登记</el-button>
  926. </div>
  927. <div v-show="UserShow">
  928. <el-tabs type="border-card" v-model="activeNameThree" @tab-click="handleClick">
  929. <el-tab-pane label="新增使用登记" name="first">
  930. <el-form :model="userform" ref="userform" :rules="userRules">
  931. <el-row>
  932. <el-col :span="8">
  933. <el-form-item label="日期:" required prop="date" class="st">
  934. <el-date-picker
  935. v-model="userform.date"
  936. prefix-icon="none"
  937. type="date"
  938. placeholder="请选择"
  939. format="yyyy-MM-dd"
  940. value-format="yyyy-MM-dd"
  941. style="width:150px">
  942. </el-date-picker>
  943. </el-form-item>
  944. </el-col>
  945. <el-col :span="8">
  946. <el-form-item label="班次:" required prop="classtype" class="st">
  947. <el-select v-model="userform.classtype" placeholder="请选择" style="width:150px">
  948. <el-option
  949. v-for="item in classType"
  950. :key="item.id"
  951. :label="item.name"
  952. :value="item.id"
  953. style="width:90px">
  954. </el-option>
  955. </el-select>
  956. </el-form-item>
  957. </el-col>
  958. <el-col :span="8">
  959. <el-form-item label="分区:" required prop="zone" >
  960. <el-select v-model="userform.zone" placeholder="请选择" style="width:150px" :disabled="true">
  961. <el-option
  962. v-for="item in bedZoneThree"
  963. :key="item.id"
  964. :label="item.name"
  965. :value="item.id"
  966. >
  967. </el-option>
  968. </el-select>
  969. </el-form-item>
  970. </el-col>
  971. </el-row>
  972. <el-row>
  973. <el-col :span="8">
  974. <el-form-item label="机位号:" required prop="bed_number">
  975. <el-select style="width:150px" v-model="userform.bed_number" :disabled="true">
  976. <el-option v-for="item in this.bedNumberTwo" :key="item.id" :label="item.number" :value="item.id"></el-option>
  977. </el-select>
  978. </el-form-item>
  979. </el-col>
  980. <el-col :span="8">
  981. <el-form-item label="患者:" required prop ="patient_name">
  982. <el-autocomplete
  983. style="width:150px"
  984. popper-class="my-autocomplete"
  985. v-model="userform.patient_name"
  986. :fetch-suggestions="querySearchAsync"
  987. placeholder="请输入内容"
  988. @select="handleSelect">
  989. <i
  990. class="el-icon-search el-input__icon"
  991. slot="suffix"
  992. >
  993. </i>
  994. <template slot-scope="{ item }">
  995. <span class="addr">{{ item.name }}</span>
  996. </template>
  997. </el-autocomplete>
  998. </el-form-item>
  999. </el-col>
  1000. <el-col :span="8">
  1001. <el-form-item label="传染病:">
  1002. <el-input style="width:150px" v-model="userform.contagion" :disabled="true"></el-input>
  1003. </el-form-item>
  1004. </el-col>
  1005. </el-row>
  1006. <el-row>
  1007. <el-col :span="8">
  1008. <el-form-item label="透析方式:">
  1009. <el-select v-model="userform.dialysis_mode" placeholder="请选择" style="width:150px">
  1010. <el-option
  1011. v-for="item in treatmode"
  1012. :key="item.id"
  1013. :label="item.name"
  1014. :value="item.id">
  1015. </el-option>
  1016. </el-select>
  1017. </el-form-item>
  1018. </el-col>
  1019. <el-col :span="8">
  1020. <el-form-item label="上机时间:">
  1021. <el-date-picker
  1022. type="datetime"
  1023. format="yyyy-MM-dd HH:mm"
  1024. value-format="yyyy-MM-dd HH:mm"
  1025. placeholder="选择时间"
  1026. v-model="userform.start_time"
  1027. style="width:185px"
  1028. ></el-date-picker>
  1029. </el-form-item>
  1030. </el-col>
  1031. <el-col :span="8">
  1032. <el-form-item label="下机时间:">
  1033. <el-date-picker
  1034. type="datetime"
  1035. format="yyyy-MM-dd HH:mm"
  1036. value-format="yyyy-MM-dd HH:mm"
  1037. placeholder="选择时间"
  1038. v-model="userform.end_time"
  1039. style="width:185px"
  1040. ></el-date-picker>
  1041. </el-form-item>
  1042. </el-col>
  1043. </el-row>
  1044. <el-row>
  1045. <el-col :span="8">
  1046. <el-form-item label="透析时长:">
  1047. <el-input style="width:150px" v-model="userform.dialysis_time"></el-input>
  1048. </el-form-item>
  1049. </el-col>
  1050. <el-col :span="8">
  1051. <el-form-item label="实际超滤量(L)">
  1052. <el-input style="width:150px" v-model="userform.hyperfiltratio"></el-input>
  1053. </el-form-item>
  1054. </el-col>
  1055. <el-col :span="8">
  1056. <el-form-item label="体重减少(kg):">
  1057. <el-input style="width:150px" v-model="userform.weight_loss"></el-input>
  1058. </el-form-item>
  1059. </el-col>
  1060. </el-row>
  1061. <el-row>
  1062. <el-col :span="8">
  1063. <el-form-item label="预警值:">
  1064. <el-input style="width:150px" v-model="userform.warning_value"></el-input>
  1065. </el-form-item>
  1066. </el-col>
  1067. <el-col :span="8">
  1068. <el-form-item label="使用次数:">
  1069. <el-input style="width:150px" v-model="userform.user_total" :disabled="true"></el-input>
  1070. </el-form-item>
  1071. </el-col>
  1072. <el-col :span="8">
  1073. <el-form-item label="运行:">
  1074. <el-radio-group v-model="userform.run" @change="changeRun">
  1075. <el-radio :label="gender.id" :value="gender.id" v-for="(gender, index) in runOption" :key="gender.id">{{gender.name}}</el-radio>
  1076. </el-radio-group>
  1077. </el-form-item>
  1078. </el-col>
  1079. </el-row>
  1080. <el-row>
  1081. <el-col>
  1082. <el-form-item class="stoppage" label="故障发生阶段:">
  1083. <el-radio-group v-model="userform.failure_stage" :disabled ="runDisable">
  1084. <el-radio :label="gender.id" :value="gender.id" v-for="(gender, index) in faultPhase" :key="index">{{gender.name}}</el-radio>
  1085. </el-radio-group>
  1086. </el-form-item>
  1087. </el-col>
  1088. </el-row>
  1089. <el-row>
  1090. <el-col :span="24">
  1091. <el-form-item class="stoppage" label="故障描述:">
  1092. <el-input style="width:78%" v-model="userform.fault_description"></el-input>
  1093. </el-form-item>
  1094. </el-col>
  1095. </el-row>
  1096. <el-row>
  1097. <el-col :span="24">
  1098. <el-form-item class="stoppage" label="故障提示信息及代码:">
  1099. <el-input style="width:78%" v-model="userform.code_information"></el-input>
  1100. </el-form-item>
  1101. </el-col>
  1102. </el-row>
  1103. <el-row>
  1104. <el-form-item label="机器消毒:"></el-form-item>
  1105. </el-row>
  1106. <el-row>
  1107. <el-col :span="3">
  1108. <el-form-item label="①机表"></el-form-item>
  1109. </el-col>
  1110. <el-col :span="10">
  1111. <el-form-item label="消毒方式:" required prop="disinfect_type">
  1112. <el-select v-model="userform.disinfect_type" placeholder="请选择" >
  1113. <el-option
  1114. v-for="item in disinfectType"
  1115. :key="item.id"
  1116. :label="item.name"
  1117. :value="item.id"
  1118. style="width:150px">
  1119. </el-option>
  1120. </el-select>
  1121. </el-form-item>
  1122. </el-col>
  1123. <el-col :span="10">
  1124. <el-form-item label="消毒液:" required prop="disinfectant_type">
  1125. <el-select v-model="userform.disinfectant_type" placeholder="请选择" >
  1126. <el-option
  1127. v-for="item in disinfectantType"
  1128. :key="item.id"
  1129. :label="item.name"
  1130. :value="item.id"
  1131. style="width:200px">
  1132. </el-option>
  1133. </el-select>
  1134. </el-form-item>
  1135. </el-col>
  1136. </el-row>
  1137. <el-row>
  1138. <el-col :span="3">
  1139. <el-form-item style="visibility: hidden;" label="①机表"></el-form-item>
  1140. </el-col>
  1141. <el-col :span="10">
  1142. <el-form-item label="消毒状态:" required prop="disinfection">
  1143. <el-select v-model="userform.disinfection" placeholder="请选择" >
  1144. <el-option
  1145. v-for="item in disinfection"
  1146. :key="item.id"
  1147. :label="item.name"
  1148. :value="item.id"
  1149. style="width:200px">
  1150. </el-option>
  1151. </el-select>
  1152. </el-form-item>
  1153. </el-col>
  1154. <el-col :span="10">
  1155. <el-form-item label="运行:">
  1156. <el-radio-group v-model="userform.machine_run">
  1157. <el-radio :label="gender.id" :value="gender.id" v-for="(gender, index) in runOptions" :key="index">{{gender.name}}</el-radio>
  1158. </el-radio-group>
  1159. </el-form-item>
  1160. </el-col>
  1161. </el-row>
  1162. <el-row>
  1163. <el-col :span="3">
  1164. <el-form-item label="②液路"></el-form-item>
  1165. </el-col>
  1166. <el-col :span="10">
  1167. <el-form-item label="消毒方式:" required prop="fluid_path">
  1168. <el-select v-model="userform.fluid_path" placeholder="请选择" >
  1169. <el-option
  1170. v-for="item in sterilizeType"
  1171. :key="item.id"
  1172. :label="item.name"
  1173. :value="item.id"
  1174. style="width:200px">
  1175. </el-option>
  1176. </el-select>
  1177. </el-form-item>
  1178. </el-col>
  1179. <el-col :span="10">
  1180. <el-form-item label="消毒液:" required prop="disinfectant">
  1181. <el-select v-model="userform.disinfectant" placeholder="请选择" >
  1182. <el-option
  1183. v-for="item in fluidPathType"
  1184. :key="item.id"
  1185. :label="item.name"
  1186. :value="item.id"
  1187. style="width:260px">
  1188. </el-option>
  1189. </el-select>
  1190. </el-form-item>
  1191. </el-col>
  1192. </el-row>
  1193. <el-row>
  1194. <el-col :span="3">
  1195. <el-form-item style="visibility: hidden;" label="①机表"></el-form-item>
  1196. </el-col>
  1197. <el-col :span="10">
  1198. <el-form-item label="消毒状态:" required prop="disinfection_status">
  1199. <el-select v-model="userform.disinfection_status" placeholder="请选择" >
  1200. <el-option
  1201. v-for="item in disinfection"
  1202. :key="item.id"
  1203. :label="item.name"
  1204. :value="item.id"
  1205. style="width:200px">
  1206. </el-option>
  1207. </el-select>
  1208. </el-form-item>
  1209. </el-col>
  1210. <el-col :span="10">
  1211. <el-form-item label="消毒液残留:">
  1212. <el-radio-group v-model="userform.disinfection_residue">
  1213. <el-radio :label="gender.id" :value="gender.id" v-for="(gender, index) in Disinfectant" :key="index">{{gender.name}}</el-radio>
  1214. </el-radio-group>
  1215. </el-form-item>
  1216. </el-col>
  1217. </el-row>
  1218. <el-row>
  1219. <el-col :span="8">
  1220. <el-form-item label="消毒时长:">
  1221. <el-input style="width:135px" v-model="userform.longtime"></el-input><span style="color:#606266;">分钟</span>
  1222. </el-form-item>
  1223. </el-col>
  1224. <el-col :span="8">
  1225. <el-form-item label="开始消毒时间:">
  1226. <el-date-picker
  1227. type="datetime"
  1228. format="yyyy-MM-dd HH:mm"
  1229. value-format="yyyy-MM-dd HH:mm"
  1230. placeholder="选择时间"
  1231. v-model="userform.starttime"
  1232. style="width:185px;"
  1233. ></el-date-picker>
  1234. </el-form-item>
  1235. </el-col>
  1236. <el-col :span="8">
  1237. <el-form-item label="结束消毒时间:">
  1238. <el-date-picker
  1239. type="datetime"
  1240. format="yyyy-MM-dd HH:mm"
  1241. value-format="yyyy-MM-dd HH:mm"
  1242. placeholder="选择时间"
  1243. v-model="userform.endtime"
  1244. style="width:185px;"
  1245. ></el-date-picker>
  1246. </el-form-item>
  1247. </el-col>
  1248. </el-row>
  1249. <el-row>
  1250. <el-col :span="3" style="height: 36px;line-height: 36px;">
  1251. <el-form-item label="透析机消毒液:"></el-form-item>
  1252. </el-col>
  1253. <el-col :span="5" style="display:flex;align-items: center">
  1254. <el-form-item>
  1255. <el-checkbox v-model="userform.dialysis_checked">更换</el-checkbox>
  1256. </el-form-item>
  1257. </el-col>
  1258. <el-col :span="8">
  1259. <el-form-item label="名称:">
  1260. <el-select v-model="userform.dialysis_name" placeholder="请选择" style="width:150px">
  1261. <el-option
  1262. v-for="item in names"
  1263. :key="item.id"
  1264. :label="item.name"
  1265. :value="item.id"
  1266. >
  1267. </el-option>
  1268. </el-select>
  1269. </el-form-item>
  1270. </el-col>
  1271. <el-col :span="8">
  1272. <el-form-item label="规格:">
  1273. <el-input style="width:100px" v-model="userform.norms"></el-input><span style="color:#606266;">桶</span>
  1274. </el-form-item>
  1275. <span class="warn" v-show="warnShow">您已一个月未更换,请注意检测</span>
  1276. </el-col>
  1277. </el-row>
  1278. <el-row>
  1279. <el-col>
  1280. <el-form-item label="浓度:">
  1281. <el-radio-group v-model="userform.dialysis_concentration">
  1282. <el-radio :label="gender.id" :value="gender.id" v-for="(gender, index) in potency" :key="index">{{gender.name}}</el-radio>
  1283. </el-radio-group>
  1284. </el-form-item>
  1285. </el-col>
  1286. </el-row>
  1287. <el-row>
  1288. <el-col :span="8">
  1289. <el-form-item label="细菌过滤器:">
  1290. <el-checkbox v-model="userform.germ_checked">更换</el-checkbox>
  1291. <span class="warn" v-show="warnShowTwo">您已一个月未更换,请注意检测</span>
  1292. </el-form-item>
  1293. </el-col>
  1294. <el-col :span="8">
  1295. <el-form-item class="newname" label="名称:">
  1296. <el-select v-model="userform.germ_name" placeholder="请选择" style="width:150px">
  1297. <el-option
  1298. v-for="item in germs"
  1299. :key="item.id"
  1300. :label="item.name"
  1301. :value="item.id"
  1302. >
  1303. </el-option>
  1304. </el-select>
  1305. </el-form-item>
  1306. </el-col>
  1307. <el-col :span="8">
  1308. <el-form-item class="newname" label="数量:">
  1309. <el-input style="width:100px" v-model="userform.germ_number"></el-input><span style="color:#606266;">支</span>
  1310. </el-form-item>
  1311. </el-col>
  1312. </el-row>
  1313. <el-row>
  1314. <el-col :span="8">
  1315. <el-form-item label="空气滤网清洁:">
  1316. <el-checkbox v-model="userform.clean">清洁</el-checkbox>
  1317. <span class="warn" v-show="warnShowThree">您已一个月未清洁,请检查</span>
  1318. </el-form-item>
  1319. </el-col>
  1320. <el-col :span="8">
  1321. <el-form-item class="newname" label="签名:" required prop="sign_name">
  1322. <el-select v-model="userform.sign_name" placeholder="请选择" >
  1323. <el-option
  1324. v-for="item in autograph"
  1325. :key="item.admin_user_id"
  1326. :label="item.user_name"
  1327. :value="item.admin_user_id"
  1328. style="width:185px">
  1329. </el-option>
  1330. </el-select>
  1331. </el-form-item>
  1332. </el-col>
  1333. </el-row>
  1334. <el-row>
  1335. <div class="elbutton">
  1336. <el-col :span="6">
  1337. <el-button>取消</el-button>
  1338. </el-col>
  1339. <el-col :span="2">
  1340. <el-button type="primary" @click="SaveInformation('userform')">保存</el-button>
  1341. </el-col>
  1342. </div>
  1343. </el-row>
  1344. </el-form>
  1345. </el-tab-pane>
  1346. <el-tab-pane label="使用登记列表" name="second">
  1347. <user-form ref="userForm" :userdata="userdata"></user-form>
  1348. </el-tab-pane>
  1349. </el-tabs>
  1350. </div>
  1351. <div v-show="Ushow" class="zClass">
  1352. 暂无数据
  1353. </div>
  1354. </el-tab-pane>
  1355. <el-tab-pane label="质量控制" name="fourth">
  1356. <div v-show="zhiShow">
  1357. <el-tabs type="border-card" v-model="activeNameSix" @tab-click="handleClick">
  1358. <el-tab-pane label="新增质量控制" name="first">
  1359. <span style="margin-bottom: 20px;display: block;">细菌培养</span>
  1360. <el-form :model="qualityForm" ref="qualityForm" :rules="qualitRules">
  1361. <el-row>
  1362. <el-col :span="8">
  1363. <el-form-item label="取样日期:">
  1364. <el-date-picker
  1365. v-model="qualityForm.date"
  1366. prefix-icon="none"
  1367. type="date"
  1368. placeholder="请选择"
  1369. format="yyyy-MM-dd"
  1370. value-format="yyyy-MM-dd"
  1371. style="width:150px">
  1372. </el-date-picker>
  1373. </el-form-item>
  1374. </el-col>
  1375. <el-col :span="8">
  1376. <el-form-item label="取样标本:">
  1377. <el-select style="width:150px" v-model="qualityForm.specimen" @change="changeSpecimen">
  1378. <el-option v-for="item in samplingSpecimen" :key="item.id" :label="item.name" :value="item.id"></el-option>
  1379. </el-select>
  1380. </el-form-item>
  1381. </el-col>
  1382. <el-col :span="8">
  1383. <el-form-item label="A浓缩液批号:">
  1384. <el-input style="width:150px" v-model="qualityForm.concentrate_noa" :disabled="disable"></el-input>
  1385. </el-form-item>
  1386. </el-col>
  1387. </el-row>
  1388. <el-row>
  1389. <el-col :span="8">
  1390. <el-form-item label="B浓缩液批号">
  1391. <el-input style="width:150px" v-model="qualityForm.concentrate_nob" :disabled="diableTwo"></el-input>
  1392. </el-form-item>
  1393. </el-col>
  1394. <el-col :span="8">
  1395. <el-form-item label="采样部位:">
  1396. <el-select style="width:150px" v-model="qualityForm.sampling_locationa">
  1397. <el-option v-for="item in samplingLocation" :key="item.id" :label="item.name" :value="item.id"></el-option>
  1398. </el-select>
  1399. </el-form-item>
  1400. </el-col>
  1401. <el-col :span="8">
  1402. <el-form-item label="检测单位:" required prop="detection_unit">
  1403. <el-input style="width:150px" v-model="qualityForm.detection_unit"></el-input>
  1404. </el-form-item>
  1405. </el-col>
  1406. </el-row>
  1407. <el-row>
  1408. <el-col :span="8">
  1409. <el-form-item label="取样者:" required prop="sampler">
  1410. <el-select style="width:150px" v-model="qualityForm.sampler">
  1411. <el-option v-for="item in sampling" :key="item.addmin_user_id" :label="item.user_name" :value="item.admin_user_id"></el-option>
  1412. </el-select>
  1413. </el-form-item>
  1414. </el-col>
  1415. <el-col :span="8">
  1416. <el-form-item label="出报告日期:">
  1417. <el-date-picker
  1418. v-model="qualityForm.reporting_date"
  1419. prefix-icon="none"
  1420. type="date"
  1421. placeholder="请选择"
  1422. format="yyyy-MM-dd"
  1423. value-format="yyyy-MM-dd"
  1424. style="width:150px">
  1425. </el-date-picker>
  1426. </el-form-item>
  1427. </el-col>
  1428. </el-row>
  1429. <el-row>
  1430. <el-col :span="24">
  1431. <el-form-item label="检测结果:(cfu/ml)">
  1432. <el-input
  1433. type="textarea"
  1434. :rows="2"
  1435. placeholder="请输入内容"
  1436. style="width:84%"
  1437. v-model="qualityForm.detection_result"
  1438. >
  1439. </el-input>
  1440. </el-form-item>
  1441. </el-col>
  1442. </el-row>
  1443. <el-row>
  1444. <el-col :span="24">
  1445. <span style="color:#FF9900">注:细菌检测应每个月一次,要求细菌数<100cfu/ml</span>
  1446. </el-col>
  1447. </el-row>
  1448. <el-row>
  1449. <div class="clearn">
  1450. <el-col :span="4">
  1451. <el-button @click="cleanSaveBacteria">取消</el-button>
  1452. </el-col>
  1453. <el-col :span="4">
  1454. <el-button type="primary" @click="SaveBacteria('qualityForm')">保存</el-button>
  1455. </el-col>
  1456. </div>
  1457. </el-row>
  1458. </el-form>
  1459. <el-divider></el-divider>
  1460. <span style="margin-bottom: 20px;display: block;">内毒素检测</span>
  1461. <el-form ref="qualityFormTwo" :model="qualityFormTwo" :rules="diaRules">
  1462. <el-row>
  1463. <el-col :span="8">
  1464. <el-form-item label="取样日期:">
  1465. <el-date-picker
  1466. v-model="qualityFormTwo.sampling_date"
  1467. prefix-icon="none"
  1468. type="date"
  1469. placeholder="请选择"
  1470. format="yyyy-MM-dd"
  1471. value-format="yyyy-MM-dd"
  1472. style="width:150px">
  1473. </el-date-picker>
  1474. </el-form-item>
  1475. </el-col>
  1476. <el-col :span="8">
  1477. <el-form-item label="取样标本:">
  1478. <el-select style="width:150px" v-model="qualityFormTwo.specimenb" @change="changeSpecimen">
  1479. <el-option v-for="item in samplingSpecimen" :key="item.id" :label="item.name" :value="item.id"></el-option>
  1480. </el-select>
  1481. </el-form-item>
  1482. </el-col>
  1483. <el-col :span="8">
  1484. <el-form-item label="A浓缩液批号:">
  1485. <el-input style="width:150px" v-model="qualityFormTwo.concentrate_noc" :disabled="disable"></el-input>
  1486. </el-form-item>
  1487. </el-col>
  1488. </el-row>
  1489. <el-row>
  1490. <el-col :span="8">
  1491. <el-form-item label="B浓缩液批号:">
  1492. <el-input style="width:150px" v-model ="qualityFormTwo.concentrateb_nod" :disabled="diableTwo"></el-input>
  1493. </el-form-item>
  1494. </el-col>
  1495. <el-col :span="8">
  1496. <el-form-item label="采样部位:">
  1497. <el-select style="width:150px" v-model="qualityFormTwo.sampling_locationb">
  1498. <el-option v-for="item in samplingLocation" :key="item.id" :label="item.name" :value="item.id"></el-option>
  1499. </el-select>
  1500. </el-form-item>
  1501. </el-col>
  1502. <el-col :span="8">
  1503. <el-form-item label="检测单位:" required prop="detection_unit">
  1504. <el-input style="width:150px" v-model ="qualityFormTwo.detection_unit"></el-input>
  1505. </el-form-item>
  1506. </el-col>
  1507. </el-row>
  1508. <el-row>
  1509. <el-col :span="8">
  1510. <el-form-item label="取样者:" required prop="samplerb">
  1511. <el-select style="width:150px" v-model="qualityFormTwo.samplerb">
  1512. <el-option v-for="item in sampling" :key="item.addmin_user_id" :label="item.user_name" :value="item.admin_user_id"></el-option>
  1513. </el-select>
  1514. </el-form-item>
  1515. </el-col>
  1516. <el-col :span="8">
  1517. <el-form-item label="出报告日期:">
  1518. <el-date-picker
  1519. v-model="qualityFormTwo.reporting_dateb"
  1520. prefix-icon="none"
  1521. type="date"
  1522. placeholder="请选择"
  1523. format="yyyy-MM-dd"
  1524. value-format="yyyy-MM-dd"
  1525. style="width:150px">
  1526. </el-date-picker>
  1527. </el-form-item>
  1528. </el-col>
  1529. </el-row>
  1530. <el-row>
  1531. <el-col :span="24">
  1532. <el-form-item label="检测结果:(EU/ml)">
  1533. <el-input
  1534. type="textarea"
  1535. :rows="2"
  1536. placeholder="请输入内容"
  1537. style="width:800px"
  1538. v-model="qualityFormTwo.detection_resultb"
  1539. >
  1540. </el-input>
  1541. </el-form-item>
  1542. </el-col>
  1543. </el-row>
  1544. <el-row>
  1545. <el-col :span="24">
  1546. <span style="color:#FF9900">注:内毒素检测应至少每3个月1次,要求内毒素<0.25EU/ml,每台透析机每年至少检测一次</span>
  1547. </el-col>
  1548. </el-row>
  1549. <el-row>
  1550. <div class="clearn">
  1551. <el-col :span="4">
  1552. <el-button @click="cleanLincomycin">取消</el-button>
  1553. </el-col>
  1554. <el-col :span="4">
  1555. <el-button type="primary" @click="SaveLincomycin('qualityFormTwo')">保存</el-button>
  1556. </el-col>
  1557. </div>
  1558. </el-row>
  1559. </el-form>
  1560. <el-divider></el-divider>
  1561. <span style="margin-bottom: 20px;display: block;">透析液离子浓度检测</span>
  1562. <el-form ref="qualityFormThree" :model="qualityFormThree" :rules="ruleThree">
  1563. <el-row>
  1564. <el-col :span="8">
  1565. <el-form-item label="取样日期:">
  1566. <el-date-picker
  1567. v-model="qualityFormThree.dateb"
  1568. prefix-icon="none"
  1569. type="date"
  1570. placeholder="请选择"
  1571. format="yyyy-MM-dd"
  1572. value-format="yyyy-MM-dd"
  1573. style="width:150px">
  1574. </el-date-picker>
  1575. </el-form-item>
  1576. </el-col>
  1577. <el-col :span="8">
  1578. <el-form-item label="取样者:" required prop="samplerc">
  1579. <el-select style="width:150px" v-model="qualityFormThree.samplerc">
  1580. <el-option v-for="item in sampling" :key="item.addmin_user_id" :label="item.user_name" :value="item.admin_user_id"></el-option>
  1581. </el-select>
  1582. </el-form-item>
  1583. </el-col>
  1584. <el-col :span="8">
  1585. <el-form-item label="检测单位:" required prop="detection_unit">
  1586. <el-input style="width:150px" v-model ="qualityFormThree.detection_unit"></el-input>
  1587. </el-form-item>
  1588. </el-col>
  1589. </el-row>
  1590. <el-row>
  1591. <el-col :span="8">
  1592. <el-form-item label="A浓缩液批号:">
  1593. <el-input style="width:150px" v-model="qualityFormThree.concentrate_nof"></el-input>
  1594. </el-form-item>
  1595. </el-col>
  1596. <el-col :span="8">
  1597. <el-form-item label="B浓缩液批号:">
  1598. <el-input style="width:150px" v-model="qualityFormThree.concentrate_nog"></el-input>
  1599. </el-form-item>
  1600. </el-col>
  1601. <el-col :span="8">
  1602. <el-form-item label="出报告日期:">
  1603. <el-date-picker
  1604. v-model="qualityFormThree.date_reportc"
  1605. prefix-icon="none"
  1606. type="date"
  1607. placeholder="请选择"
  1608. format="yyyy-MM-dd"
  1609. value-format="yyyy-MM-dd"
  1610. style="width:150px">
  1611. </el-date-picker>
  1612. </el-form-item>
  1613. </el-col>
  1614. </el-row>
  1615. <el-row>
  1616. <el-col :span="8">
  1617. <!-- <span>Na<sup>+</sup></span> -->
  1618. <el-form-item class="newItem" label="实际Na⁺(mmol/L):">
  1619. <el-input style="width:123px" v-model="qualityFormThree.actual_na"></el-input>
  1620. </el-form-item>
  1621. </el-col>
  1622. <el-col :span="8">
  1623. <el-form-item class="newItem" label="配方Na⁺(mmol/L):">
  1624. <el-input style="width:123px" v-model="qualityFormThree.actual_pna"></el-input>
  1625. </el-form-item>
  1626. </el-col>
  1627. <el-col :span="8">
  1628. <el-form-item label="K⁺(mmol/L):">
  1629. <el-input style="width:150px" v-model="qualityFormThree.actual_k"></el-input>
  1630. </el-form-item>
  1631. </el-col>
  1632. </el-row>
  1633. <el-row>
  1634. <el-col :span="8">
  1635. <el-form-item label="Ca2⁺(mmol/L):">
  1636. <el-input style="width:150px" v-model="qualityFormThree.actual_ca"></el-input>
  1637. </el-form-item>
  1638. </el-col>
  1639. <el-col :span="8">
  1640. <el-form-item label="CI¯(mmol/L):">
  1641. <el-input style="width:150px" v-model="qualityFormThree.actual_ci"></el-input>
  1642. </el-form-item>
  1643. </el-col>
  1644. <el-col :span="8">
  1645. <el-form-item label="HCO3¯(mmol/L):">
  1646. <el-input style="width:150px" v-model="qualityFormThree.actual_hco"></el-input>
  1647. </el-form-item>
  1648. </el-col>
  1649. </el-row>
  1650. <el-row>
  1651. <el-col :span="8">
  1652. <el-form-item label="Mg2⁺(mmol/L):">
  1653. <el-input style="width:150px" v-model="qualityFormThree.actual_mg"></el-input>
  1654. </el-form-item>
  1655. </el-col>
  1656. <el-col :span="8">
  1657. <el-form-item label="PH:">
  1658. <el-input style="width:150px" v-model="qualityFormThree.actual_ph"></el-input>
  1659. </el-form-item>
  1660. </el-col>
  1661. </el-row>
  1662. <el-row>
  1663. <div></div>
  1664. </el-row>
  1665. <el-row>
  1666. <el-col :span="24">
  1667. <el-form-item label="备注:">
  1668. <el-input
  1669. type="textarea"
  1670. :rows="2"
  1671. placeholder="请输入内容"
  1672. style="width:500px"
  1673. v-model="qualityFormThree.remakes"
  1674. >
  1675. </el-input>
  1676. </el-form-item>
  1677. </el-col>
  1678. </el-row>
  1679. <el-row>
  1680. <div class="clearn">
  1681. <el-col :span="4">
  1682. <el-button @click="cleanQuality">取消</el-button>
  1683. </el-col>
  1684. <el-col :span="4">
  1685. <el-button type="primary" @click="SaveQualityControl('qualityFormThree')">保存</el-button>
  1686. </el-col>
  1687. </div>
  1688. </el-row>
  1689. </el-form>
  1690. </el-tab-pane>
  1691. <el-tab-pane label="质量控制列表" name="second">
  1692. <quality-form ref="child"></quality-form>
  1693. </el-tab-pane>
  1694. </el-tabs>
  1695. </div>
  1696. <div v-show="zhShow" class="zClass">
  1697. 暂无数据
  1698. </div>
  1699. </el-tab-pane>
  1700. <el-tab-pane label="维修维护" name="five">
  1701. <el-tabs type="border-card" v-model="activeNameFive" @tab-click="handleClick">
  1702. <el-tab-pane label="新增维修维护" name="first">
  1703. <el-form :model="guaForm" ref="guaForm" :rules="repirRules">
  1704. <el-row>
  1705. <el-col :span="8">
  1706. <el-form-item label="保修日期:" required prop="guarantee_date">
  1707. <el-date-picker
  1708. v-model="guaForm.guarantee_date"
  1709. prefix-icon="none"
  1710. type="date"
  1711. placeholder="请选择"
  1712. format="yyyy-MM-dd"
  1713. value-format="yyyy-MM-dd"
  1714. style="width:150px">
  1715. </el-date-picker>
  1716. </el-form-item>
  1717. </el-col>
  1718. <el-col :span="8">
  1719. <el-form-item label="出发时间:">
  1720. <el-date-picker
  1721. type="datetime"
  1722. format="yyyy-MM-dd HH:mm"
  1723. value-format="yyyy-MM-dd HH:mm"
  1724. placeholder="选择时间"
  1725. v-model="guaForm.start_time"
  1726. style="width:185px;">
  1727. </el-date-picker>
  1728. </el-form-item>
  1729. </el-col>
  1730. </el-row>
  1731. <el-row>
  1732. <el-col :span="8">
  1733. <el-form-item label="到达时间:">
  1734. <!-- <el-date-picker
  1735. v-model="guaForm.arrive_time"
  1736. prefix-icon="none"
  1737. type="date"
  1738. placeholder="请选择"
  1739. format="yyyy-MM-dd"
  1740. value-format="yyyy-MM-dd"
  1741. style="width:185px">
  1742. </el-date-picker> -->
  1743. <el-date-picker
  1744. type="datetime"
  1745. format="yyyy-MM-dd HH:mm"
  1746. value-format="yyyy-MM-dd HH:mm"
  1747. placeholder="选择时间"
  1748. v-model="guaForm.arrive_time"
  1749. style="width:185px;">
  1750. </el-date-picker>
  1751. </el-form-item>
  1752. </el-col>
  1753. <el-col :span="8">
  1754. <el-form-item label="完成时间:">
  1755. <el-date-picker
  1756. type="datetime"
  1757. format="yyyy-MM-dd HH:mm"
  1758. value-format="yyyy-MM-dd HH:mm"
  1759. placeholder="选择时间"
  1760. v-model="guaForm.finish_time"
  1761. style="width:185px;">
  1762. </el-date-picker>
  1763. </el-form-item>
  1764. </el-col>
  1765. <el-col :span="8">
  1766. <el-form-item label="总路程:(公里)">
  1767. <el-input style="width:150px" v-model = "guaForm.total_distance"></el-input>
  1768. </el-form-item>
  1769. </el-col>
  1770. </el-row>
  1771. <el-row>
  1772. <el-col :span="24">
  1773. <el-form-item label="故障发生阶段">
  1774. <el-radio-group v-model="guaForm.failure_stage">
  1775. <el-radio :label="gender.id" :value="gender.id" v-for="(gender, index) in faultPhase" :key="index">{{gender.name}}</el-radio>
  1776. </el-radio-group>
  1777. </el-form-item>
  1778. </el-col>
  1779. </el-row>
  1780. <el-row>
  1781. <el-col :span="24">
  1782. <el-form-item class="formItem" label="故障提示信息及代码">
  1783. <el-input
  1784. type="textarea"
  1785. :rows="2"
  1786. placeholder="请输入内容"
  1787. v-model="guaForm.code_information"
  1788. style="width:85%">
  1789. </el-input>
  1790. </el-form-item>
  1791. </el-col>
  1792. </el-row>
  1793. <el-row>
  1794. <el-col :span="8">
  1795. <el-form-item label="故障描述:" required prop="fault_description">
  1796. <el-input
  1797. type="textarea"
  1798. :rows="2"
  1799. placeholder="请输入内容"
  1800. v-model="guaForm.fault_description"
  1801. style="width:86%;margin-left: 10%;">
  1802. </el-input>
  1803. </el-form-item>
  1804. </el-col>
  1805. <el-col :span="8">
  1806. <el-form-item label="原因分析:">
  1807. <el-input
  1808. type="textarea"
  1809. :rows="2"
  1810. placeholder="请输入内容"
  1811. v-model="guaForm.cause_analysis"
  1812. style="width:86%;margin-left: 10%;">
  1813. </el-input>
  1814. </el-form-item>
  1815. </el-col>
  1816. <el-col :span="8">
  1817. <el-form-item label="处理过程:">
  1818. <el-input
  1819. type="textarea"
  1820. :rows="2"
  1821. placeholder="请输入内容"
  1822. v-model="guaForm.treatment_process"
  1823. style="width:86%;margin-left: 10%;">
  1824. </el-input>
  1825. </el-form-item>
  1826. </el-col>
  1827. </el-row>
  1828. <el-row>
  1829. <el-col :span="24">
  1830. <el-form-item label="上传图片:">
  1831. <el-upload
  1832. :data="uploadFileData"
  1833. action="https://upload.qiniup.com"
  1834. :on-success="handleSuccess"
  1835. :before-upload="beforeUploadFile"
  1836. :limit="1"
  1837. ref='upload'
  1838. accept=".jpg,.png,.gif"
  1839. >
  1840. <el-button size="small" type="primary">上传图片</el-button>
  1841. </el-upload>
  1842. <a class="el-upload-list__item-name" v-show="classShow">
  1843. <i style="color:#0000EE"><a :href="guaForm.images" target="_blank">{{filename}}</a><span @click="hiddenShow"><li class="el-icon-circle-close"></li></span></i>
  1844. </a>
  1845. </el-form-item>
  1846. </el-col>
  1847. </el-row>
  1848. <el-row>
  1849. <el-col :span="20">
  1850. <el-form-item label="故障是否排除:">
  1851. <el-radio-group v-model="guaForm.exclude">
  1852. <el-radio :label="gender.id" :value="gender.id" v-for="(gender, index) in breakDown" :key="index">{{gender.name}}</el-radio>
  1853. </el-radio-group>
  1854. </el-form-item>
  1855. </el-col>
  1856. </el-row>
  1857. <el-row>
  1858. <el-col :span="20">
  1859. <el-form-item label="原因:">
  1860. <el-input
  1861. type="textarea"
  1862. :rows="2"
  1863. placeholder="请输入内容"
  1864. v-model="guaForm.reason"
  1865. style="width:300px">
  1866. </el-input>
  1867. </el-form-item>
  1868. </el-col>
  1869. </el-row>
  1870. <el-row>
  1871. <div class="clearn">
  1872. <el-col :span="4">
  1873. <el-button>取消</el-button>
  1874. </el-col>
  1875. <el-col :span="4">
  1876. <el-button type="primary" @click="SaveRepair('guaForm')">保存</el-button>
  1877. </el-col>
  1878. </div>
  1879. </el-row>
  1880. </el-form>
  1881. </el-tab-pane>
  1882. <el-tab-pane label="维修维护列表" name="second">
  1883. <repair-form ref="child"></repair-form>
  1884. </el-tab-pane>
  1885. </el-tabs>
  1886. </el-tab-pane>
  1887. </el-tabs>
  1888. </div>
  1889. <!-- <el-autocomplete
  1890. popper-class="my-autocomplete"
  1891. v-model="state"
  1892. :fetch-suggestions="querySearch"
  1893. placeholder="请输入内容"
  1894. @select="handleSelect"
  1895. >
  1896. <i
  1897. class="el-icon-edit el-input__icon"
  1898. slot="suffix"
  1899. @click="handleIconClick">
  1900. </i>
  1901. <template slot-scope="{ item }">
  1902. <div class="name">{{ item.value }}</div>
  1903. <span class="addr">{{ item.address }}</span>
  1904. </template>
  1905. </el-autocomplete> -->
  1906. </el-main>
  1907. </el-container>
  1908. </el-container>
  1909. </el-container>
  1910. <!-- 新增计划 -->
  1911. <plan-form ref="planForm" :equimentid="equimentid" v-on:getAllPlan="getAllPlan" v-on:getAllPlanDetail="getAllPlanDetail" @func="getPlanData"></plan-form>
  1912. <!-- <edit-machine-form ref="editmachineform" :planid="planid" ></edit-machine-form> -->
  1913. <!-- 综合查询 -->
  1914. <multiple-form ref="multipleform" :equimentid="equimentid"></multiple-form>
  1915. <!-- 使用登记提醒配置 -->
  1916. <remander-form ref="remanderform"> </remander-form>
  1917. <!-- 编辑消毒计划 -->
  1918. <el-dialog title="编辑消毒计划" :visible.sync="dialogVisible" width="50%" center>
  1919. <el-form :model="machineform" ref="machineform" :rules="planRules">
  1920. <el-row>
  1921. <el-col :span="10">
  1922. <el-form-item label="设备型号:" required prop = "device_type">
  1923. <el-select style="width:135px" v-model="machineform.device_type">
  1924. <el-option
  1925. v-for="item in this.DeviceType"
  1926. :key="item.id"
  1927. :label="item.device_mode"
  1928. :value="item.id"
  1929. ></el-option>
  1930. </el-select>
  1931. </el-form-item>
  1932. </el-col>
  1933. <el-col :span="10">
  1934. <el-form-item label="消毒时长:" required prop="disinfec_time">
  1935. <el-input style="width:135px" v-model="machineform.disinfec_time"></el-input>
  1936. <span>分钟</span>
  1937. </el-form-item>
  1938. </el-col>
  1939. </el-row>
  1940. <el-row>
  1941. <el-col :span="10">
  1942. <el-form-item label="时间:" required prop="time">
  1943. <el-select
  1944. v-model="machineform.time"
  1945. placeholder="请选择时间"
  1946. style="width: 140px;"
  1947. >
  1948. <el-option
  1949. v-for="item in this.timeType"
  1950. :key="item.id"
  1951. :label="item.name"
  1952. :value="item.id"
  1953. ></el-option>
  1954. </el-select>
  1955. </el-form-item>
  1956. </el-col>
  1957. <el-col :span="10">
  1958. <el-form-item label="班次:" required prop="class_time">
  1959. <el-select
  1960. v-model="machineform.class_time"
  1961. placeholder="请选择时间"
  1962. style="width: 140px;"
  1963. >
  1964. <el-option
  1965. v-for="item in this.classType"
  1966. :key="item.id"
  1967. :label="item.name"
  1968. :value="item.id"
  1969. ></el-option>
  1970. </el-select>
  1971. </el-form-item>
  1972. </el-col>
  1973. </el-row>
  1974. <el-row>
  1975. <el-col :span="10">
  1976. <el-form-item label="机表消毒方式:">
  1977. <el-select style="width:135px" v-model="machineform.way">
  1978. <el-option
  1979. v-for="item in this.disinfectType"
  1980. :key="item.id"
  1981. :label="item.name"
  1982. :value="item.id"
  1983. ></el-option>
  1984. </el-select>
  1985. </el-form-item>
  1986. </el-col>
  1987. <el-col :span="10">
  1988. <el-form-item label="机表消毒液:">
  1989. <el-select
  1990. style="width:135px"
  1991. v-model="machineform.machine_disinfectant"
  1992. >
  1993. <el-option
  1994. v-for="item in this.disinfectantType"
  1995. :key="item.id"
  1996. :label="item.name"
  1997. :value="item.id"
  1998. ></el-option>
  1999. </el-select>
  2000. </el-form-item>
  2001. </el-col>
  2002. </el-row>
  2003. <el-row>
  2004. <el-col :span="10">
  2005. <el-form-item label="液路消毒方式:">
  2006. <el-select style="width:135px" v-model="machineform.disinfectant_way">
  2007. <el-option
  2008. v-for="item in this.sterilizeType"
  2009. :key="item.id"
  2010. :label="item.name"
  2011. :value="item.id"
  2012. ></el-option>
  2013. </el-select>
  2014. </el-form-item>
  2015. </el-col>
  2016. <el-col :span="10">
  2017. <el-form-item label="液路消毒液:">
  2018. <el-select style="width:135px" v-model="machineform.disinfectant">
  2019. <el-option
  2020. v-for="item in this.fluidPathType"
  2021. :key="item.id"
  2022. :label="item.name"
  2023. :value="item.id"
  2024. ></el-option>
  2025. </el-select>
  2026. </el-form-item>
  2027. </el-col>
  2028. </el-row>
  2029. </el-form>
  2030. <span slot="footer" class="dialog-footer">
  2031. <el-button @click="dialogVisible = false">取 消</el-button>
  2032. <el-button type="primary" @click="UpdatePlanInfo('machineform')">保存</el-button>
  2033. </span>
  2034. </el-dialog>
  2035. </div>
  2036. </div>
  2037. </template>
  2038. <script>
  2039. import BreadCrumb from '../components/bread-crumb'
  2040. import { getAllSubregion, getAllMachine, getMachineDetailById,
  2041. UpdateMachineInfo, getAllPlan, getAllPlanDetail, DeletePlans,
  2042. getAllEquimentName, EditPlanDetail, UpdatePlanInfo, SaveInformation, getPatientInfo,
  2043. ChangeClass, getAllOrganization, getUserRegister, SaveQualityControl, getOrgName, SaveRepair, SaveBacteria, SaveLincomycin, getAutoData, getAllEquitType, UpdateMacheineTwo, getTotalNumber, getTimeWarning, getTimeBeteen, getAllpatient, UpdateMachineInfoTwo, getPatientDetail, openDelete, getAllMode, selectChange, selectBed } from '@/api/manage'
  2044. import { uParseTime } from '@/utils/tools'
  2045. import { getToken } from '@/api/qiniu'
  2046. import PlanForm from './components/PlanForm'
  2047. import EditMachineForm from './components/EditMachineForm'
  2048. import MultipleForm from './components/MultipleForm'
  2049. import UserForm from './components/UserForm'
  2050. import QualityForm from './components/QualityForm'
  2051. import RepairForm from './components/RepairForm'
  2052. import RemanderForm from './components/RemanderForm'
  2053. import { parseTime } from '@/utils'
  2054. import { getFileExtension } from '@/utils/tools'
  2055. import { PostSearch } from '@/api/patient'
  2056. const cityOptions = ['HD', 'HDF', 'HD+HP', 'HP', 'HF', 'SCUF', 'IUF', 'HFHD', 'HFHD+HP', 'PHF', 'HFR', 'HDF+HP', 'CRRT', '腹水回输']
  2057. const moment = require('moment')
  2058. export default {
  2059. name: 'home',
  2060. components: {
  2061. BreadCrumb,
  2062. PlanForm,
  2063. EditMachineForm,
  2064. MultipleForm,
  2065. UserForm,
  2066. QualityForm,
  2067. RepairForm,
  2068. RemanderForm
  2069. },
  2070. data() {
  2071. return {
  2072. crumbs: [
  2073. { path: false, name: '设备管理详情页' }
  2074. ],
  2075. tableData: [],
  2076. tableDatatwo: [],
  2077. planData: [],
  2078. DeviceTypeType: [
  2079. { id: 0, name: '全部' },
  2080. { id: 1, name: '透析机' },
  2081. { id: 2, name: '水处理机' },
  2082. { id: 3, name: '其他' }
  2083. ],
  2084. bedNumber: [],
  2085. zoneNumber: [],
  2086. Number: [],
  2087. form: {
  2088. id: '',
  2089. serial_number: '',
  2090. devicetype: '',
  2091. bed_number: '',
  2092. device_name: '',
  2093. manufacture_factory: '',
  2094. service_manufacturer: '',
  2095. unit_type: '',
  2096. use_section: '',
  2097. section_number: '',
  2098. buy_date: '',
  2099. install_date: '',
  2100. start_date: '',
  2101. maintenance_engineer: '',
  2102. telephone: '',
  2103. guarantee_date: '',
  2104. machine_status: '',
  2105. user_total: '',
  2106. remarks: '',
  2107. rubbish_date: '',
  2108. rubbish_reason: '',
  2109. user_year: '',
  2110. work_time: '',
  2111. treat_mode: [],
  2112. treat_type: [],
  2113. bed: '', // 治疗模式
  2114. Disinfection_mode: '',
  2115. revers_mode: '',
  2116. beds: '',
  2117. bed_numbers: ''
  2118. },
  2119. activeName: 'first',
  2120. activeNameTwo: 'first',
  2121. activeNameThree: 'first',
  2122. activeNameSix: 'first',
  2123. activeNameFive: 'first',
  2124. machineStatus: [
  2125. { id: 1, name: '使用机' },
  2126. { id: 2, name: '备用机' },
  2127. { id: 3, name: '急诊机' },
  2128. { id: 4, name: '报废机' }
  2129. ],
  2130. DisCardResion: [
  2131. { id: 0, name: '请选择' },
  2132. { id: 1, name: '超期限报废' },
  2133. { id: 2, name: '故障报废' },
  2134. { id: 3, name: '核定报废' }
  2135. ],
  2136. DeviceTypes: [
  2137. { id: 1, name: '透析机' },
  2138. { id: 2, name: '水处理机' },
  2139. { id: 3, name: '其他' }
  2140. ],
  2141. Classes: [
  2142. { id: 0, name: '全部' },
  2143. { id: 1, name: '上午' },
  2144. { id: 2, name: '下午' },
  2145. { id: 3, name: '晚上' }
  2146. ],
  2147. names: [
  2148. { id: 0, name: '请选择' },
  2149. { id: 1, name: '20%柠檬酸' },
  2150. { id: 2, name: '50%柠檬酸' },
  2151. { id: 3, name: '次氯酸钠' }
  2152. ],
  2153. germs: [
  2154. { id: 0, name: '请选择' },
  2155. { id: 1, name: '费森细菌过滤器' },
  2156. { id: 2, name: '日机装细菌过滤器' },
  2157. { id: 3, name: '贝朗机细菌过滤器' },
  2158. { id: 4, name: '东丽机细菌过滤器' }
  2159. ],
  2160. DisinfectionMode: [
  2161. { id: 0, name: '请选择' },
  2162. { id: 1, name: '化学消毒' },
  2163. { id: 2, name: '热消毒' },
  2164. { id: 3, name: '化学消毒+热消毒' }
  2165. ],
  2166. autograph: [],
  2167. bedZone: [],
  2168. bedZoneTwo: [],
  2169. forms: {
  2170. zone_id: 0, // 分区号
  2171. class_id: '', // 班次
  2172. device_type: 0, // 设备类型
  2173. date: ''
  2174. },
  2175. currentRow: null,
  2176. cancelShow: false,
  2177. confirmShow: false,
  2178. isIndeterminate: true,
  2179. checkAll: false,
  2180. cities: cityOptions,
  2181. rules: {
  2182. serial_number: [{ required: true, message: '请填写序列号' }],
  2183. device_name: [{ required: true, message: '请填写序列号' }],
  2184. devicetype: [{ required: true, message: '请填写设备类型' }],
  2185. unit_type: [{ required: true, message: '请填写设备型号' }]
  2186. },
  2187. qualitRules: {
  2188. detection_unit: [{ required: true, message: '请填写检测单位' }],
  2189. sampler: [{ required: true, message: '请填写取样者' }]
  2190. },
  2191. diaRules: {
  2192. detection_unit: [{ required: true, message: '请填写检测单位' }],
  2193. samplerb: [{ required: true, message: '请填写取样者' }]
  2194. },
  2195. repirRules: {
  2196. guarantee_date: [{ required: true, message: '请填写保修日期' }],
  2197. fault_description: [{ required: true, message: '请填写故障描述' }]
  2198. },
  2199. ruleThree: {
  2200. detection_unit: [{ required: true, message: '请填写检测单位' }],
  2201. samplerc: [{ required: true, message: '请填写取样者' }]
  2202. },
  2203. userRules: {
  2204. date: [{ required: true, message: '请填写日期' }],
  2205. zone: [{ required: true, message: '请填写分区' }],
  2206. bed_number: [{ required: true, message: '请填写机位号' }],
  2207. patient_name: [{ required: true, message: '请填写患者', trigger: ['blur', 'change'] }],
  2208. disinfect_type: [{ required: true, message: '请填写消毒方式' }],
  2209. disinfectant_type: [{ required: true, message: '请填写消毒液' }],
  2210. disinfection: [{ required: true, message: '请填写消毒状态' }],
  2211. fluid_path: [{ required: true, message: '请填写消毒方式' }],
  2212. disinfectant: [{ required: true, message: '请填写消毒液' }],
  2213. disinfection_status: [{ required: true, message: '消毒状态' }],
  2214. sign_name: [{ required: true, message: '请填写签名', trigger: ['change'] }],
  2215. classtype: [{ required: true, message: '请填写班次' }]
  2216. },
  2217. planRules: {
  2218. device_type: [{ required: true, message: '请输入设备型号' }],
  2219. disinfec_time: [{ required: true, message: '请输入消毒时长' }],
  2220. time: [{ required: true, message: '请输入时间' }],
  2221. class_time: [{ required: true, message: '请输入班次' }]
  2222. },
  2223. runOption: [
  2224. { id: 1, name: '正常' },
  2225. { id: 2, name: '故障' }
  2226. ],
  2227. runOptions: [
  2228. { id: 1, name: '达标' },
  2229. { id: 2, name: '未达标' }
  2230. ],
  2231. faultPhase: [
  2232. { id: 1, name: '开机启动' },
  2233. { id: 2, name: '自检' },
  2234. { id: 3, name: '准备' },
  2235. { id: 4, name: '治疗' },
  2236. { id: 5, name: '消毒' }
  2237. ],
  2238. Disinfectant: [
  2239. { id: 1, name: '有' },
  2240. { id: 2, name: '无' }
  2241. ],
  2242. potency: [
  2243. { id: 1, name: '达标' },
  2244. { id: 2, name: '未达标' }
  2245. ],
  2246. sampling: [],
  2247. DeviceType: [],
  2248. equimentid: 0,
  2249. checkAllStatus: false,
  2250. checkAllStatusOne: false,
  2251. selectMachines: [],
  2252. selectMachinesOne: [],
  2253. machineIndex: -1,
  2254. planid: 0,
  2255. machineform: {
  2256. id: '',
  2257. device_type: '',
  2258. disinfec_time: '',
  2259. time: '',
  2260. class_time: '',
  2261. way: '',
  2262. machine_disinfectant: '',
  2263. disinfectant_way: '',
  2264. disinfectant: ''
  2265. },
  2266. dialogVisible: false,
  2267. timeType: [
  2268. { id: 1, name: '周一' },
  2269. { id: 2, name: '周二' },
  2270. { id: 3, name: '周三' },
  2271. { id: 4, name: '周四' },
  2272. { id: 5, name: '周五' },
  2273. { id: 6, name: '周六' },
  2274. { id: 7, name: '周日' }
  2275. ],
  2276. classType: [
  2277. { id: 0, name: '请选择' },
  2278. { id: 1, name: '上午' },
  2279. { id: 2, name: '下午' },
  2280. { id: 3, name: '晚上' }
  2281. ],
  2282. // 基表消毒方式
  2283. disinfectType:
  2284. [
  2285. { id: 0, name: '/' },
  2286. { id: 1, name: '擦拭' },
  2287. { id: 2, name: '化学消毒' }
  2288. ],
  2289. // 基表消毒液
  2290. disinfectantType: [
  2291. { id: 0, name: '/' },
  2292. { id: 1, name: '0.22%季铵盐' },
  2293. { id: 2, name: '500mg/l含氯消毒剂' },
  2294. { id: 3, name: '1000mg/l含氯消毒剂' },
  2295. { id: 4, name: '1500mg/l含氯消毒剂' }
  2296. ],
  2297. // 夜路消毒方式
  2298. sterilizeType: [
  2299. { id: 0, name: '/' },
  2300. { id: 1, name: '热化学消毒' },
  2301. { id: 2, name: '化学消毒 + 除钙' },
  2302. { id: 3, name: '热化学消毒 + 除钙' },
  2303. { id: 4, name: '热消毒' },
  2304. { id: 5, name: '化学消毒' },
  2305. { id: 6, name: '除钙' },
  2306. { id: 7, name: '清洗' }
  2307. ],
  2308. // 夜路消毒液
  2309. fluidPathType: [
  2310. { id: 0, name: '/' },
  2311. { id: 1, name: '20%柠檬酸' },
  2312. { id: 2, name: '25%柠檬酸' },
  2313. { id: 3, name: '50%柠檬酸' },
  2314. { id: 4, name: '50%柠檬酸 + 5%次氯酸钠' },
  2315. { id: 5, name: '20%柠檬酸 + 10%冰醋酸' },
  2316. { id: 6, name: '0.2%过氧化乙酸' },
  2317. { id: 7, name: '10%冰醋酸' },
  2318. { id: 8, name: '50%冰醋酸' },
  2319. { id: 9, name: '5%次氯酸钠' }
  2320. ],
  2321. userform: {
  2322. id: 0,
  2323. date: moment(new Date()).format('YYYY-MM-DD'), // 日期
  2324. classtype: '', // 班次
  2325. zone: '', // 分区
  2326. bed_number: '', // 床位号
  2327. patient_name: '', // 患者
  2328. contagion: '', // 传染病
  2329. dialysis_mode: '', // 透析方式
  2330. start_time: '', // 上机时间
  2331. end_time: '', // 下机时间
  2332. dialysis_time: '', // 透析时长
  2333. hyperfiltratio: '', // 实际超滤量
  2334. weight_loss: '', // 体重减少
  2335. warning_value: '', // 预警值
  2336. user_total: '', // 使用次数
  2337. run: 1, // 运行
  2338. failure_stage: '', // 故事发生阶段
  2339. fault_description: '', // 故障描述
  2340. code_information: '', // 故障提示及代码
  2341. // 机器消毒
  2342. disinfect_type: 1, // 消毒方式
  2343. disinfectant_type: 2, // 消毒液
  2344. disinfection: 1, // 消毒状态
  2345. machine_run: 1, // 运行
  2346. // 液路
  2347. fluid_path: 3, // 消毒方式
  2348. disinfectant: 3, // 消毒液
  2349. disinfection_status: 1, // 消毒状态
  2350. disinfection_residue: 1, // 消毒液残留
  2351. longtime: '', // 消毒时长
  2352. starttime: '', // 开始消毒时间
  2353. endtime: '', // 结束消毒时间
  2354. dialysis_checked: '', // 更换
  2355. dialysis_name: '', // 名称
  2356. norms: '', // 规格
  2357. dialysis_concentration: 1, // 浓度
  2358. germ_checked: '', // 更换
  2359. germ_name: '', // 名称
  2360. germ_number: '', // 数量
  2361. clean: '', // 清洁
  2362. sign_name: '', // 签名
  2363. patient_id: ''
  2364. },
  2365. treatmentmodes: [
  2366. { id: 1, name: 'HD' },
  2367. { id: 2, name: 'HDF' },
  2368. { id: 3, name: 'HD+HP' },
  2369. { id: 4, name: 'HP' },
  2370. { id: 5, name: 'HF' },
  2371. { id: 6, name: 'SCUF' },
  2372. { id: 7, name: 'IUF' },
  2373. { id: 8, name: 'HFHD+HP' },
  2374. { id: 9, name: 'HFR' },
  2375. { id: 10, name: 'HDF+HP' },
  2376. { id: 11, name: 'GRRT' },
  2377. { id: 12, name: '腹水回输' }
  2378. ],
  2379. treatmode: [
  2380. { id: 0, name: '请选择' },
  2381. { id: 1, name: 'HD' },
  2382. { id: 2, name: 'HDF' },
  2383. { id: 3, name: 'HD + HP' },
  2384. { id: 4, name: 'HP' },
  2385. { id: 5, name: 'HF' },
  2386. { id: 6, name: 'SCUF' },
  2387. { id: 7, name: 'IUF' },
  2388. { id: 8, name: 'HFHD' },
  2389. { id: 9, name: 'HFHD+HP' },
  2390. { id: 10, name: 'PHF' },
  2391. { id: 11, name: 'HFR' },
  2392. { id: 12, name: 'HDF+HP' },
  2393. { id: 13, name: 'CRRT' },
  2394. { id: 14, name: '腹水回输' },
  2395. { id: 15, name: 'HD前置换' },
  2396. { id: 16, name: 'HD后置换' },
  2397. { id: 17, name: 'HDF前置换' },
  2398. { id: 18, name: 'HDF后置换' }
  2399. ],
  2400. disinfection: [
  2401. { id: 0, name: '请选择' },
  2402. { id: 1, name: '已消毒' },
  2403. { id: 2, name: '未消毒' },
  2404. { id: 3, name: '消毒未完成' }
  2405. ],
  2406. patientName: [],
  2407. start: '',
  2408. end: '',
  2409. // 细菌培养
  2410. qualityForm: {
  2411. date: moment(new Date()).format('YYYY-MM-DD'), // 取样日期
  2412. specimen: '', // 取样标本
  2413. concentrate_noa: '', // 浓A
  2414. concentrate_nob: '', // 浓B,
  2415. sampling_locationa: '', // 采样部位
  2416. detection_unit: '', // 检测单位
  2417. sampler: '', // 取样者
  2418. reporting_date: '', // 报告日期
  2419. detection_result: '' // 检测结果
  2420. },
  2421. qualityFormTwo: {
  2422. // 内毒素检测
  2423. detection_unit: '', // 检测单位
  2424. sampling_date: moment(new Date()).format('YYYY-MM-DD'), // 取样日期
  2425. specimenb: '', // 取样标本
  2426. concentrate_noc: '', // A浓缩液批号
  2427. concentrateb_nod: '', // B浓
  2428. sampling_locationb: '', // 采样部位
  2429. samplerb: '', // 取样者
  2430. reporting_dateb: '', // 出报告日期
  2431. detection_resultb: '' // 检测结果
  2432. },
  2433. qualityFormThree: {
  2434. detection_unit: '', // 检测单位
  2435. // 透析液离子浓度检测
  2436. dateb: moment(new Date()).format('YYYY-MM-DD'), // 取样日期
  2437. samplerc: '', // 取样者
  2438. concentrate_nof: '', // A浓
  2439. concentrate_nog: '', // B浓
  2440. date_reportc: '', // 出报告日期
  2441. actual_na: '',
  2442. actual_pna: '',
  2443. actual_k: '',
  2444. actual_ca: '',
  2445. actual_ci: '',
  2446. actual_hco: '',
  2447. actual_mg: '',
  2448. actual_ph: '',
  2449. remakes: ''
  2450. },
  2451. disable: false,
  2452. diableTwo: false,
  2453. samplingSpecimen: [
  2454. { id: 0, name: '请选择' },
  2455. { id: 1, name: '透析液' },
  2456. { id: 2, name: 'A浓缩液' },
  2457. { id: 3, name: 'B浓缩液' },
  2458. { id: 4, name: '置换液' },
  2459. { id: 5, name: '透析用水' }
  2460. ],
  2461. samplingLocation: [
  2462. { id: 0, name: '请选择' },
  2463. { id: 1, name: '透析液入口' },
  2464. { id: 2, name: '透析液取样口' },
  2465. { id: 3, name: '置换液出口' },
  2466. { id: 4, name: '透析机反渗水入口' }
  2467. ],
  2468. breakDown: [
  2469. { id: 1, name: '是' },
  2470. { id: 2, name: '待观察' },
  2471. { id: 3, name: '未解决' }
  2472. ],
  2473. guaForm: {
  2474. guarantee_date: moment(new Date()).format('YYYY-MM-DD'),
  2475. start_time: '',
  2476. arrive_time: '',
  2477. finish_time: '',
  2478. total_distance: '',
  2479. failure_stage: '',
  2480. fault_description: '',
  2481. cause_analysis: '',
  2482. treatment_process: '',
  2483. images: '',
  2484. exclude: '',
  2485. reason: '',
  2486. code_information: '',
  2487. imageName: ''
  2488. },
  2489. filename: '',
  2490. qiniuDomain: 'https://images.shengws.com/',
  2491. uploadFileData: { token: '', key: '' },
  2492. tShow: false,
  2493. sShow: false,
  2494. qShow: false,
  2495. readisable: true,
  2496. fileList: [],
  2497. DisShow: true,
  2498. DioShow: false,
  2499. zhiShow: true,
  2500. zhShow: false,
  2501. UserShow: true,
  2502. Ushow: false,
  2503. restaurants: [],
  2504. state: '',
  2505. userdata: 0,
  2506. disableThree: true,
  2507. disableFour: true,
  2508. disableFive: true,
  2509. runDisable: true,
  2510. warnShow: false,
  2511. warnShowTwo: false,
  2512. warnShowThree: false,
  2513. bedZoneThree: [],
  2514. bedNumberTwo: [],
  2515. reverseMode: [
  2516. { id: 0, name: '请选择' },
  2517. { id: 1, name: '单级反渗' },
  2518. { id: 2, name: '双级反渗' }
  2519. ],
  2520. tabIndex: '',
  2521. deviceMode: [],
  2522. zoneDisabled: false,
  2523. bedid: '',
  2524. unitType: '',
  2525. classShow: false
  2526. }
  2527. },
  2528. methods: {
  2529. changeRun(val) {
  2530. if (val === 1) {
  2531. this.runDisable = true
  2532. this.userform.failure_stage = ''
  2533. }
  2534. if (val === 2) {
  2535. this.runDisable = false
  2536. }
  2537. },
  2538. handleClick(tab, event) {
  2539. // console.log(tab, event)
  2540. },
  2541. handleExceed(file) {
  2542. // console.log(file)
  2543. },
  2544. handleRemove(file, fileList) {
  2545. },
  2546. beforeRemove(file, fileList) {
  2547. // console.log(file, fileList)
  2548. },
  2549. handlePreview(file) {
  2550. // console.log(file)
  2551. },
  2552. changetreatmentmode(val) {
  2553. const checkedCount = val.length
  2554. this.checkAll = checkedCount === this.treatmentmode.length
  2555. this.isIndeterminate = checkedCount > 0 && checkedCount < this.treatmentmode.length
  2556. },
  2557. handleCheckAllChange(val) {
  2558. this.form.treat_mode = val ? cityOptions : []
  2559. this.isIndeterminate = false
  2560. },
  2561. handleCheckedCitiesChange(value) {
  2562. const checkedCount = value.length
  2563. this.checkAll = checkedCount === this.cities.length
  2564. this.isIndeterminate = checkedCount > 0 && checkedCount < this.cities.length
  2565. },
  2566. // 获取所有分区
  2567. getAllSubregion() {
  2568. getAllSubregion().then(response => {
  2569. var zones = response.data.data.zones
  2570. this.deviceType = zones
  2571. var numbers = response.data.data.numbers
  2572. var zone = [{ id: 0, name: '全部' }]
  2573. for (let i = 0; i < zones.length; i++) {
  2574. const item = zones[i]
  2575. zone.push({ id: item.id, name: item.name })
  2576. }
  2577. var devicenumber = response.data.data.devicenumber
  2578. // console.log('devicenumber', devicenumber)
  2579. this.bedZone = zone
  2580. var zoness = [{ id: 0, name: '请选择' }]
  2581. for (let i = 0; i < zones.length; i++) {
  2582. const item = zones[i]
  2583. zoness.push({ id: item.id, name: item.name })
  2584. }
  2585. var bed = [{ id: 0, number: '请选择' }]
  2586. for (let i = 0; i < numbers.length; i++) {
  2587. const item = numbers[i]
  2588. // console.log(item)
  2589. bed.push({ id: item.id, number: item.number })
  2590. }
  2591. this.bedNumberTwo = bed
  2592. this.bedZoneTwo = zones
  2593. this.bedZoneThree = zoness
  2594. this.bedNumber = numbers
  2595. // this.Number = devicenumber
  2596. })
  2597. },
  2598. changeBedNumber(val) {
  2599. this.forms.zone_id = val
  2600. this.getAllMachine()
  2601. },
  2602. changeClassId(val) {
  2603. this.forms.class_id = val
  2604. this.getAllMachine()
  2605. },
  2606. changeDeviceId(val) {
  2607. if (val === 1) {
  2608. this.zoneDisabled = false
  2609. } else {
  2610. this.zoneDisabled = true
  2611. }
  2612. this.forms.device_type = val
  2613. this.getAllMachine()
  2614. },
  2615. getAllMachine() {
  2616. getAllMachine(this.forms.zone_id, this.forms.device_type).then(response => {
  2617. if (response.data.state === 1) {
  2618. var addmahcer = response.data.data.addmahcer
  2619. console.log('查找的数据', addmahcer)
  2620. this.tableDatatwo = addmahcer
  2621. this.tabIndex = this.$route.query.index
  2622. var id = this.$route.query.id
  2623. for (let i = 0; i < this.tableDatatwo.length; i++) {
  2624. if (this.tableDatatwo[i].id == id) {
  2625. this.$refs.singleTable.setCurrentRow(this.tableDatatwo[i])
  2626. break
  2627. }
  2628. }
  2629. // this.$refs.singleTable.setCurrentRow(this.tableDatatwo[this.tabIndex])
  2630. }
  2631. })
  2632. },
  2633. handleIndex(index) {
  2634. this.tabIndex = index
  2635. },
  2636. handleCurrentChange(val) {
  2637. this.unitType = val.unit_type
  2638. // console.log('val是什么', val)
  2639. this.currentRow = val
  2640. this.$forceUpdate()
  2641. this.getMachineDetailById(val.id)
  2642. this.equimentid = val.id
  2643. this.userdata = val.id
  2644. this.getAllPlanDetail(val.unit_type)
  2645. this.getPatientInfo(val.id)
  2646. // 获取基本信息
  2647. this.getUserRegister(val.id)
  2648. // 病人下机后插入数据
  2649. this.getAutoData(val.id)
  2650. this.getTotalNumber(val.id)
  2651. // this.getTimeWarning(val.id)
  2652. this.getTimeBeteen(val.id)
  2653. this.getData(val.bed_id)
  2654. },
  2655. getAutoData(id) {
  2656. getAutoData(id).then(response => {
  2657. if (response.data.state === 1) {
  2658. var dialysis = response.data.data.dialysis
  2659. }
  2660. })
  2661. },
  2662. getMachineDetailById(id) {
  2663. getMachineDetailById(id).then(response => {
  2664. if (response.data.state === 1) {
  2665. var addmacher = response.data.data.addmacher
  2666. console.log('设备详情', addmacher)
  2667. var warning = response.data.data.warning
  2668. // console.log('warning', warning)
  2669. var time = this.getTimestamp(this.userform.date) - warning.stime
  2670. // console.log('时间', time)
  2671. // if (time < 2678400 && warning.dialysis_checked === 1) {
  2672. // this.warnShow = false
  2673. // } else {
  2674. // this.warnShow = true
  2675. // }
  2676. var germ = response.data.data.germ
  2677. // console.log('germ', germ)
  2678. var timetwo = this.getTimestamp(this.userform.date) - germ.stime
  2679. // console.log('时间', timetwo)
  2680. // if (timetwo < 2678400 && germ.germ_checked === 1) {
  2681. // this.warnShowTwo = false
  2682. // } else {
  2683. // this.warnShowTwo = true
  2684. // }
  2685. var clean = response.data.data.clean
  2686. var timethree = this.getTimestamp(this.userform.date) - clean.stime
  2687. // console.log('时间', timethree)
  2688. // if (timethree < 2678400 && clean.clean === 1) {
  2689. // this.warnShowThree = false
  2690. // } else {
  2691. // this.warnShowThree = true
  2692. // }
  2693. var number = response.data.data.number
  2694. // console.log('number', number)
  2695. this.Number = number
  2696. if (addmacher.device_type === 1) {
  2697. this.sShow = false
  2698. this.qShow = false
  2699. this.tShow = true
  2700. this.DisShow = true
  2701. this.DioShow = false
  2702. this.zhiShow = true
  2703. this.zhShow = false
  2704. this.UserShow = true
  2705. this.Ushow = false
  2706. }
  2707. if (addmacher.device_type === 2) {
  2708. this.tShow = false
  2709. this.qShow = false
  2710. this.sShow = true
  2711. this.DisShow = false
  2712. this.DioShow = true
  2713. this.zhiShow = true
  2714. this.zhShow = false
  2715. this.UserShow = true
  2716. this.Ushow = false
  2717. }
  2718. if (addmacher.device_type === 3) {
  2719. this.tShow = false
  2720. this.sShow = false
  2721. this.qShow = true
  2722. this.DisShow = false
  2723. this.DioShow = true
  2724. this.zhiShow = false
  2725. this.zhShow = true
  2726. this.UserShow = false
  2727. this.Ushow = true
  2728. }
  2729. var mode = response.data.data.mode
  2730. var zone = response.data.data.zone
  2731. const arr1 = []
  2732. // const cityOptions = ['HD', 'HDF', 'HD+HP', 'HP', 'HF', 'SCUF', 'IUF', 'HFHD+HP', 'HFR', 'HDF+HP', 'GRRT', '腹水回收']
  2733. for (let index = 0; index < mode.length; index++) {
  2734. if (mode[index].treate_mode === 1) {
  2735. mode[index] = 'HD'
  2736. }
  2737. if (mode[index].treate_mode === 2) {
  2738. mode[index] = 'HDF'
  2739. }
  2740. if (mode[index].treate_mode === 3) {
  2741. mode[index] = 'HD+HP'
  2742. }
  2743. if (mode[index].treate_mode === 4) {
  2744. mode[index] = 'HP'
  2745. }
  2746. if (mode[index].treate_mode === 5) {
  2747. mode[index] = 'HF'
  2748. }
  2749. if (mode[index].treate_mode === 6) {
  2750. mode[index] = 'SCUF'
  2751. }
  2752. if (mode[index].treate_mode === 7) {
  2753. mode[index] = 'IUF'
  2754. }
  2755. if (mode[index].treate_mode === 8) {
  2756. mode[index] = 'HFHD'
  2757. }
  2758. if (mode[index].treate_mode === 9) {
  2759. mode[index] = 'HFHD+HP'
  2760. }
  2761. if (mode[index].treate_mode === 10) {
  2762. mode[index] = 'PHF'
  2763. }
  2764. if (mode[index].treate_mode === 11) {
  2765. mode[index] = 'HFR'
  2766. }
  2767. if (mode[index].treate_mode === 12) {
  2768. mode[index] = 'HDF+HP'
  2769. }
  2770. if (mode[index].treate_mode === 13) {
  2771. mode[index] = 'CRRT'
  2772. }
  2773. if (mode[index].treate_mode === 14) {
  2774. mode[index] = '腹水回输'
  2775. }
  2776. arr1.push(mode[index])
  2777. }
  2778. this.form.treat_mode = arr1
  2779. this.form.id = addmacher.id
  2780. this.form.serial_number = addmacher.serial_number
  2781. this.form.devicetype = addmacher.device_type
  2782. this.form.bed_number = addmacher.bed_id
  2783. this.form.bed_numbers = addmacher.bed_number
  2784. this.form.beds = addmacher.bed_number
  2785. this.form.device_name = addmacher.device_name
  2786. this.form.manufacture_factory = addmacher.manufacture_factory
  2787. this.form.service_manufacturer = addmacher.service_manufacturer
  2788. // this.form.unit_type = addmacher.unit_type
  2789. this.form.unit_type = parseInt(addmacher.device_mode)
  2790. this.form.use_section = addmacher.use_section
  2791. this.form.section_number = addmacher.section_number
  2792. if (addmacher.buy_date !== 0) {
  2793. this.form.buy_date = uParseTime(addmacher.buy_date, '{y}-{m}-{d}')
  2794. }
  2795. if (addmacher.install_date !== 0) {
  2796. this.form.install_date = uParseTime(addmacher.install_date, '{y}-{m}-{d}')
  2797. }
  2798. if (addmacher.start_date !== 0) {
  2799. this.form.start_date = uParseTime(addmacher.start_date, '{y}-{m}-{d}')
  2800. }
  2801. this.form.maintenance_engineer = addmacher.maintenace_engineer
  2802. this.form.telephone = addmacher.telephone
  2803. this.form.guarantee_date = addmacher.guarantee_date
  2804. this.form.machine_status = addmacher.machine_status
  2805. this.form.user_total = addmacher.user_total
  2806. this.form.remarks = addmacher.remarks
  2807. // this.form.device_mode = addmacher.device_mode
  2808. if (addmacher.rubbish_date !== 0) {
  2809. this.form.rubbish_date = uParseTime(addmacher.rubbish_date, '{y}-{m}-{d}')
  2810. }
  2811. this.form.rubbish_reason = addmacher.rubbish_reason
  2812. this.form.user_year = addmacher.user_year
  2813. this.form.work_time = addmacher.work_time
  2814. // eslint-disable-next-line eqeqeq
  2815. if (addmacher.disinfection_mode == 0) {
  2816. this.form.Disinfection_mode = 0
  2817. } else {
  2818. this.form.Disinfection_mode = addmacher.disinfection_mode
  2819. }
  2820. // eslint-disable-next-line eqeqeq
  2821. if (addmacher.revers_mode == 0) {
  2822. this.form.revers_mode = 0
  2823. } else {
  2824. this.form.revers_mode = addmacher.revers_mode
  2825. }
  2826. this.getAllSubregion()
  2827. }
  2828. })
  2829. },
  2830. UpdateMachine() {
  2831. this.cancelShow = true
  2832. this.confirmShow = true
  2833. this.disableThree = false
  2834. this.disableFour = false
  2835. this.disableFive = false
  2836. },
  2837. UpdateMachineInfo(formName) {
  2838. const arr2 = []
  2839. this.form.treat_mode.map((item, index) => {
  2840. const obj = {}
  2841. if (item === 'HD') {
  2842. obj.id = 1
  2843. }
  2844. if (item === 'HDF') {
  2845. obj.id = 2
  2846. }
  2847. if (item === 'HD+HP') {
  2848. obj.id = 3
  2849. }
  2850. if (item === 'HP') {
  2851. obj.id = 4
  2852. }
  2853. if (item === 'HF') {
  2854. obj.id = 5
  2855. }
  2856. if (item === 'SCUF') {
  2857. obj.id = 6
  2858. }
  2859. if (item === 'IUF') {
  2860. obj.id = 7
  2861. }
  2862. if (item === 'HFHD') {
  2863. obj.id = 8
  2864. }
  2865. if (item === 'HFHD+HP') {
  2866. obj.id = 9
  2867. }
  2868. if (item === 'PHF') {
  2869. obj.id = 10
  2870. }
  2871. if (item === 'HFR') {
  2872. obj.id = 11
  2873. }
  2874. if (item === 'HDF+HP') {
  2875. obj.id = 12
  2876. }
  2877. if (item === 'CRRT') {
  2878. obj.id = 13
  2879. }
  2880. if (item === '腹水回输') {
  2881. obj.id = 14
  2882. }
  2883. arr2.push(obj.id)
  2884. })
  2885. this.form.treat_type = arr2
  2886. var device_type = this.form.devicetype
  2887. var device_types = parseInt(device_type)
  2888. this.form.devicetype = device_types
  2889. if (this.form.rubbish_reason === '') {
  2890. this.form.rubbish_reason = 0
  2891. }
  2892. var rubbish_reason = this.form.rubbish_reason
  2893. var rubbish_reasons = parseInt(rubbish_reason)
  2894. this.form.rubbish_reason = rubbish_reasons
  2895. var machine_status = this.form.machine_status
  2896. var machine_statuss = parseInt(machine_status)
  2897. this.form.machine_status = machine_statuss
  2898. // if (this.form.bed_number === '') {
  2899. // this.form.bed_number = 0
  2900. // }
  2901. var bed_numbers = this.form.bed_number
  2902. var bed_numberss = parseInt(bed_numbers)
  2903. this.form.bed_number = bed_numberss
  2904. this.$refs[formName].validate(valid => {
  2905. UpdateMachineInfo(this.form).then(response => {
  2906. // console.log('form', this.form)
  2907. if (response.data.state === 1) {
  2908. var addmacher = response.data.data.addmacher
  2909. // console.log('addmacher----', addmacher)
  2910. this.$message.success('修改成功')
  2911. // this.$router.push({ path: '/device/home?index=' + this.tabIndex })
  2912. for (let i = 0; i < this.tableDatatwo.length; i++) {
  2913. if (this.tableDatatwo[i].id == addmacher.id) {
  2914. for (let j = 0; j < this.deviceMode.length; j++) {
  2915. if (this.deviceMode[j].id === parseInt(addmacher.unit_type)) {
  2916. addmacher.device_mode = this.deviceMode[j].device_mode
  2917. // this.$forceUpdate()
  2918. }
  2919. }
  2920. this.tableDatatwo[i] = addmacher
  2921. // this.$refs.singleTable.setCurrentRow(this.tableDatatwo[i])
  2922. }
  2923. }
  2924. // this.getAllMachine()
  2925. // this.getAllSubregion()
  2926. this.$refs.singleTable.setCurrentRow(addmacher)
  2927. this.$forceUpdate()
  2928. }
  2929. })
  2930. })
  2931. },
  2932. // eslint-disable-next-line no-irregular-whitespace
  2933. // 更新水处理机
  2934. UpdateMachineInfoTwo(formName) {
  2935. var device_type = this.form.devicetype
  2936. var device_types = parseInt(device_type)
  2937. this.form.devicetype = device_types
  2938. if (this.form.rubbish_reason === '') {
  2939. this.form.rubbish_reason = 0
  2940. }
  2941. var rubbish_reason = this.form.rubbish_reason
  2942. var rubbish_reasons = parseInt(rubbish_reason)
  2943. this.form.rubbish_reason = rubbish_reasons
  2944. var machine_status = this.form.machine_status
  2945. var machine_statuss = parseInt(machine_status)
  2946. this.form.machine_status = machine_statuss
  2947. var revers_mode = this.form.revers_mode
  2948. var revers_modes = parseInt(revers_mode)
  2949. this.form.revers_mode = revers_modes
  2950. var disinfecction_modes = this.form.Disinfection_mode
  2951. var disinfecction_modess = parseInt(disinfecction_modes)
  2952. this.form.Disinfection_mode = disinfecction_modess
  2953. this.$refs[formName].validate(valid => {
  2954. if (valid) {
  2955. UpdateMachineInfoTwo(this.form).then(response => {
  2956. if (response.data.state === 1) {
  2957. // eslint-disable-next-line no-unused-vars
  2958. var addmacher = response.data.data.addmacher
  2959. this.$message.success('修改成功')
  2960. for (let i = 0; i < this.tableDatatwo.length; i++) {
  2961. if (this.tableDatatwo[i].id == addmacher.id) {
  2962. for (let j = 0; j < this.deviceMode.length; j++) {
  2963. if (this.deviceMode[j].id === parseInt(addmacher.unit_type)) {
  2964. addmacher.device_mode = this.deviceMode[j].device_mode
  2965. // this.$forceUpdate()
  2966. }
  2967. }
  2968. this.tableDatatwo[i] = addmacher
  2969. // this.$refs.singleTable.setCurrentRow(this.tableDatatwo[i])
  2970. }
  2971. }
  2972. // this.getAllMachine()
  2973. this.getAllSubregion()
  2974. this.$refs.singleTable.setCurrentRow(addmacher)
  2975. this.$forceUpdate()
  2976. }
  2977. })
  2978. }
  2979. })
  2980. },
  2981. UpdateMacheineTwo(formName) {
  2982. var device_type = this.form.devicetype
  2983. var device_types = parseInt(device_type)
  2984. this.form.devicetype = device_types
  2985. if (this.form.rubbish_reason === '') {
  2986. this.form.rubbish_reason = 0
  2987. }
  2988. var rubbish_reason = this.form.rubbish_reason
  2989. var rubbish_reasons = parseInt(rubbish_reason)
  2990. this.form.rubbish_reason = rubbish_reasons
  2991. var machine_status = this.form.machine_status
  2992. var machine_statuss = parseInt(machine_status)
  2993. this.form.machine_status = machine_statuss
  2994. this.$refs[formName].validate(valid => {
  2995. UpdateMacheineTwo(this.form).then(response => {
  2996. if (response.data.state === 1) {
  2997. var addmacher = response.data.data.addmacher
  2998. this.$message.success('修改成功')
  2999. for (let i = 0; i < this.tableDatatwo.length; i++) {
  3000. if (this.tableDatatwo[i].id == addmacher.id) {
  3001. for (let j = 0; j < this.deviceMode.length; j++) {
  3002. if (this.deviceMode[j].id === parseInt(addmacher.unit_type)) {
  3003. addmacher.device_mode = this.deviceMode[j].device_mode
  3004. // this.$forceUpdate()
  3005. }
  3006. }
  3007. this.tableDatatwo[i] = addmacher
  3008. // this.$refs.singleTable.setCurrentRow(this.tableDatatwo[i])
  3009. }
  3010. }
  3011. // this.getAllMachine()
  3012. this.getAllSubregion()
  3013. this.$refs.singleTable.setCurrentRow(addmacher)
  3014. this.$forceUpdate()
  3015. }
  3016. })
  3017. })
  3018. },
  3019. cleanMainchine() {
  3020. this.confirmShow = false
  3021. this.cancelShow = false
  3022. // this.form.manufacture_factory = ""
  3023. // this.form.service_manufacturer= ""
  3024. // this.form.use_section= ""
  3025. // this.form.buy_date= ""
  3026. // this.form.install_date= ""
  3027. // this.form.start_date= ""
  3028. // this.form.maintenance_engineer= ""
  3029. // this.form.telephone= ""
  3030. // this.form.guarantee_date= ""
  3031. // this.form.user_total= ""
  3032. // this.form.rubbish_date= ""
  3033. // this.form.user_year = ""
  3034. // this.form.work_time = ""
  3035. // this.form.treat_mode = ""
  3036. },
  3037. addPlan() {
  3038. this.$refs.planForm.open()
  3039. },
  3040. ToReminders() {
  3041. this.$refs.remanderform.open()
  3042. },
  3043. changeCheck() {
  3044. this.$refs.multipleTableOne.clearSelection()
  3045. if (this.checkAllStatusOne) {
  3046. this.$refs.multipleTableOne.toggleAllSelection()
  3047. }
  3048. },
  3049. handleSelectionChange(val) {
  3050. this.selectMachinesOne = val
  3051. },
  3052. changeCheckOne() {
  3053. this.$refs.multipleTable.clearSelection()
  3054. if (this.checkAllStatus) {
  3055. this.$refs.multipleTable.toggleAllSelection()
  3056. }
  3057. },
  3058. handleSelectionChangeOne(val) {
  3059. this.selectMachines = val
  3060. },
  3061. changeMachineStatus(val) {
  3062. if (val === 4) {
  3063. this.readisable = false
  3064. } else {
  3065. this.readisable = true
  3066. this.form.rubbish_date = ''
  3067. this.form.rubbish_reason = ''
  3068. }
  3069. },
  3070. getAllPlan() {
  3071. getAllPlan().then(response => {
  3072. if (response.data.state === 1) {
  3073. var plan = response.data.data.plan
  3074. for (let index = 0; index < plan.length; index++) {
  3075. if (plan[index].time === 1) {
  3076. plan[index].time = '周一'
  3077. }
  3078. if (plan[index].time === 2) {
  3079. plan[index].time = '周二'
  3080. }
  3081. if (plan[index].time === 3) {
  3082. plan[index].time = '周三'
  3083. }
  3084. if (plan[index].time === 4) {
  3085. plan[index].time = '周四'
  3086. }
  3087. if (plan[index].time === 5) {
  3088. plan[index].time = '周五'
  3089. }
  3090. if (plan[index].time === 6) {
  3091. plan[index].time = '周六'
  3092. }
  3093. if (plan[index].time === 7) {
  3094. plan[index].time = '周日'
  3095. }
  3096. if (plan[index].classtime === 1) {
  3097. plan[index].classtime = '上午'
  3098. }
  3099. if (plan[index].classtime === 2) {
  3100. plan[index].classtime = '下午'
  3101. }
  3102. if (plan[index].classtime === 3) {
  3103. plan[index].classtime = '晚上'
  3104. }
  3105. if (plan[index].way === 0) {
  3106. plan[index].way = '/'
  3107. }
  3108. if (plan[index].way === 1) {
  3109. plan[index].way = '擦拭'
  3110. }
  3111. if (plan[index].way === 2) {
  3112. plan[index].way = '化学消毒'
  3113. }
  3114. if (plan[index].machine_disinfectant === 0) {
  3115. plan[index].machine_disinfectant = '/'
  3116. }
  3117. if (plan[index].machine_disinfectant === 1) {
  3118. plan[index].machine_disinfectant = '0.22%季铵盐'
  3119. }
  3120. if (plan[index].machine_disinfectant === 2) {
  3121. plan[index].machine_disinfectant = '500mg/l含氯消毒剂'
  3122. }
  3123. if (plan[index].machine_disinfectantant === 3) {
  3124. plan[index].machine_disinfectant = '1000mg/l含氯消毒剂'
  3125. }
  3126. if (plan[index].machine_disinfectant === 4) {
  3127. plan[index].machine_disinfectant = '1500mg/l含氯消毒剂'
  3128. }
  3129. if (plan[index].disinfectan_way === 0) {
  3130. plan[index].disinfectan_way = '/'
  3131. }
  3132. if (plan[index].disinfectan_way === 1) {
  3133. plan[index].disinfectan_way = '热化学消毒'
  3134. }
  3135. if (plan[index].disinfectan_way === 2) {
  3136. plan[index].disinfectan_way = '化学消毒 + 除钙'
  3137. }
  3138. if (plan[index].disinfectan_way === 3) {
  3139. plan[index].disinfectan_way = '热化学消毒 + 除钙'
  3140. }
  3141. if (plan[index].disinfectan_way === 4) {
  3142. plan[index].disinfectan_way = '热消毒'
  3143. }
  3144. if (plan[index].disinfectan_way === 5) {
  3145. plan[index].disinfectan_way = '化学消毒'
  3146. }
  3147. if (plan[index].disinfectan_way === 6) {
  3148. plan[index].disinfectan_way = '除钙'
  3149. }
  3150. if (plan[index].disinfectan_way === 7) {
  3151. plan[index].disinfectan_way = '清洗'
  3152. }
  3153. if (plan[index].disinfectant === 0) {
  3154. plan[index].disinfectant = '/'
  3155. }
  3156. if (plan[index].disinfectant === 1) {
  3157. plan[index].disinfectant = '20%柠檬酸'
  3158. }
  3159. if (plan[index].disinfectant === 2) {
  3160. plan[index].disinfectant = '25%柠檬酸'
  3161. }
  3162. if (plan[index].disinfectant === 3) {
  3163. plan[index].disinfectant = '50%柠檬酸'
  3164. }
  3165. if (plan[index].disinfectant === 4) {
  3166. plan[index].disinfectant = '50%柠檬酸 + 5%次氯酸钠'
  3167. }
  3168. if (plan[index].disinfectant === 5) {
  3169. plan[index].disinfectant = '20%柠檬酸 + 10%冰醋酸'
  3170. }
  3171. if (plan[index].disinfectant === 6) {
  3172. plan[index].disinfectant = '0.2%过氧化乙酸'
  3173. }
  3174. if (plan[index].disinfectant === 7) {
  3175. plan[index].disinfectant = '10%冰醋酸'
  3176. }
  3177. if (plan[index].disinfectant === 8) {
  3178. plan[index].disinfectant = '50%冰醋酸'
  3179. }
  3180. if (plan[index].disinfectant === 9) {
  3181. plan[index].disinfectant = '5%次氯酸钠'
  3182. }
  3183. }
  3184. this.tableData = plan
  3185. }
  3186. })
  3187. },
  3188. getAllPlanDetail(unit_type) {
  3189. getAllPlanDetail(unit_type).then(response => {
  3190. if (response.data.state === 1) {
  3191. var plandetail = response.data.data.plandetail
  3192. // console.log('plandetail', plandetail)
  3193. for (let index = 0; index < plandetail.length; index++) {
  3194. if (plandetail[index].time === 1) {
  3195. plandetail[index].time = '周一'
  3196. }
  3197. if (plandetail[index].time === 2) {
  3198. plandetail[index].time = '周二'
  3199. }
  3200. if (plandetail[index].time === 3) {
  3201. plandetail[index].time = '周三'
  3202. }
  3203. if (plandetail[index].time === 4) {
  3204. plandetail[index].time = '周四'
  3205. }
  3206. if (plandetail[index].time === 5) {
  3207. plandetail[index].time = '周五'
  3208. }
  3209. if (plandetail[index].time === 6) {
  3210. plandetail[index].time = '周六'
  3211. }
  3212. if (plandetail[index].time === 7) {
  3213. plandetail[index].time = '周日'
  3214. }
  3215. if (plandetail[index].classtime === 1) {
  3216. plandetail[index].classtime = '上午'
  3217. }
  3218. if (plandetail[index].classtime === 2) {
  3219. plandetail[index].classtime = '下午'
  3220. }
  3221. if (plandetail[index].classtime === 3) {
  3222. plandetail[index].classtime = '晚上'
  3223. }
  3224. if (plandetail[index].way === 0) {
  3225. plandetail[index].way = '/'
  3226. }
  3227. if (plandetail[index].way === 1) {
  3228. plandetail[index].way = '擦拭'
  3229. }
  3230. if (plandetail[index].way === 2) {
  3231. plandetail[index].way = '化学消毒'
  3232. }
  3233. if (plandetail[index].machine_disinfectant === 0) {
  3234. plandetail[index].machine_disinfectant = '/'
  3235. }
  3236. if (plandetail[index].machine_disinfectant === 1) {
  3237. plandetail[index].machine_disinfectant = '0.22%季铵盐'
  3238. }
  3239. if (plandetail[index].machine_disinfectant === 2) {
  3240. plandetail[index].machine_disinfectant = '500mg/l含氯消毒剂'
  3241. }
  3242. if (plandetail[index].machine_disinfectantant === 3) {
  3243. plandetail[index].machine_disinfectant = '1000mg/l含氯消毒剂'
  3244. }
  3245. if (plandetail[index].machine_disinfectant === 4) {
  3246. plandetail[index].machine_disinfectant = '1500mg/l含氯消毒剂'
  3247. }
  3248. if (plandetail[index].disinfectan_way === 0) {
  3249. plandetail[index].disinfectan_way = '/'
  3250. }
  3251. if (plandetail[index].disinfectan_way === 1) {
  3252. plandetail[index].disinfectan_way = '热化学消毒'
  3253. }
  3254. if (plandetail[index].disinfectan_way === 2) {
  3255. plandetail[index].disinfectan_way = '化学消毒 + 除钙'
  3256. }
  3257. if (plandetail[index].disinfectan_way === 3) {
  3258. plandetail[index].disinfectan_way = '热化学消毒 + 除钙'
  3259. }
  3260. if (plandetail[index].disinfectan_way === 4) {
  3261. plandetail[index].disinfectan_way = '热消毒'
  3262. }
  3263. if (plandetail[index].disinfectan_way === 5) {
  3264. plandetail[index].disinfectan_way = '化学消毒'
  3265. }
  3266. if (plandetail[index].disinfectan_way === 6) {
  3267. plandetail[index].disinfectan_way = '除钙'
  3268. }
  3269. if (plandetail[index].disinfectan_way === 7) {
  3270. plandetail[index].disinfectan_way = '清洗'
  3271. }
  3272. if (plandetail[index].disinfectant === 0) {
  3273. plandetail[index].disinfectant = '/'
  3274. }
  3275. if (plandetail[index].disinfectant === 1) {
  3276. plandetail[index].disinfectant = '20%柠檬酸'
  3277. }
  3278. if (plandetail[index].disinfectant === 2) {
  3279. plandetail[index].disinfectant = '25%柠檬酸'
  3280. }
  3281. if (plandetail[index].disinfectant === 3) {
  3282. plandetail[index].disinfectant = '50%柠檬酸'
  3283. }
  3284. if (plandetail[index].disinfectant === 4) {
  3285. plandetail[index].disinfectant = '50%柠檬酸 + 5%次氯酸钠'
  3286. }
  3287. if (plandetail[index].disinfectant === 5) {
  3288. plandetail[index].disinfectant = '20%柠檬酸 + 10%冰醋酸'
  3289. }
  3290. if (plandetail[index].disinfectant === 6) {
  3291. plandetail[index].disinfectant = '0.2%过氧化乙酸'
  3292. }
  3293. if (plandetail[index].disinfectant === 7) {
  3294. plandetail[index].disinfectant = '10%冰醋酸'
  3295. }
  3296. if (plandetail[index].disinfectant === 8) {
  3297. plandetail[index].disinfectant = '50%冰醋酸'
  3298. }
  3299. if (plandetail[index].disinfectant === 9) {
  3300. plandetail[index].disinfectant = '5%次氯酸钠'
  3301. }
  3302. }
  3303. this.planData = plandetail
  3304. }
  3305. })
  3306. },
  3307. EditMachine(id, index) {
  3308. this.dialogVisible = true
  3309. EditPlanDetail(id).then(response => {
  3310. if (response.data.state === 1) {
  3311. var plan = response.data.data.plan
  3312. this.machineform.id = plan.id
  3313. this.machineform.device_type = plan.device_type
  3314. this.machineform.disinfec_time = plan.disinfec_time
  3315. this.machineform.time = plan.time
  3316. this.machineform.class_time = plan.classtime
  3317. this.machineform.way = plan.way
  3318. this.machineform.machine_disinfectant = plan.machine_disinfectant
  3319. this.machineform.disinfectant_way = plan.disinfectan_way
  3320. this.machineform.disinfectant = plan.disinfectant
  3321. this.getPatientDetail(this.unitType, this.$route.query.bedid)
  3322. }
  3323. })
  3324. },
  3325. UpdatePlanInfo(formName) {
  3326. var devicetype = this.machineform.device_type
  3327. var devicetypes = parseInt(devicetype)
  3328. this.machineform.device_type = devicetypes
  3329. if (this.machineform.disinfec_time === '') {
  3330. this.machineform.disinfec_time = ''
  3331. }
  3332. if (this.machineform.disinfec_time !== '') {
  3333. var disinfectimes = this.machineform.disinfec_time
  3334. var disinfectime = parseInt(disinfectimes)
  3335. this.machineform.disinfec_time = disinfectime
  3336. }
  3337. var times = this.machineform.time
  3338. var time = parseInt(times)
  3339. this.machineform.time = time
  3340. var classtimes = this.machineform.class_time
  3341. var classtime = parseInt(classtimes)
  3342. this.machineform.class_time = classtime
  3343. var ways = this.machineform.way
  3344. var way = parseInt(ways)
  3345. this.machineform.way = way
  3346. var machinedisinfectant = this.machineform.machine_disinfectant
  3347. var machinedisinfectants = parseInt(machinedisinfectant)
  3348. this.machineform.machine_disinfectant = machinedisinfectants
  3349. var disinfectantways = this.machineform.disinfectant_way
  3350. var disinfectantway = parseInt(disinfectantways)
  3351. this.machineform.disinfectant_way = disinfectantway
  3352. var disinfectants = this.machineform.disinfectant
  3353. var disinfectant = parseInt(disinfectants)
  3354. this.machineform.disinfectant = disinfectant
  3355. UpdatePlanInfo(this.machineform).then(response => {
  3356. if (response.data.state === 1) {
  3357. var plan = response.data.data.plan
  3358. this.dialogVisible = false
  3359. this.$message.success('修改成功')
  3360. this.getAllPlanDetail(this.unitType)
  3361. this.getAllPlan()
  3362. }
  3363. })
  3364. },
  3365. openDeleteMahcine() {
  3366. if (this.selectMachines.length == 0) {
  3367. this.$message.error('请选择要删除的信息')
  3368. return false
  3369. }
  3370. this.$confirm(
  3371. '确认要删除所选记录吗? <br>删除后,信息将无法恢复',
  3372. '删除提示',
  3373. {
  3374. dangerouslyUseHTMLString: true,
  3375. confirmButtonText: '确定',
  3376. cancelButtonText: '取消',
  3377. type: 'warning'
  3378. }
  3379. )
  3380. .then(() => {
  3381. var ids = []
  3382. var idMap = {}
  3383. for (const index in this.selectMachines) {
  3384. ids.push(this.selectMachines[index].id)
  3385. idMap[this.selectMachines[index].id] = this.selectMachines[
  3386. index
  3387. ].id
  3388. }
  3389. DeletePlans({ ids: ids }).then(response => {
  3390. // eslint-disable-next-line eqeqeq
  3391. if (response.data.state == 1) {
  3392. // eslint-disable-next-line no-unused-vars
  3393. var msg = response.data.data.msg
  3394. var planDataLength = this.planData.length
  3395. for (let index = planDataLength - 1; index >= 0; index--) {
  3396. if (this.planData[index].id in idMap) {
  3397. this.planData.splice(index, 1)
  3398. }
  3399. }
  3400. var planDataLengths = this.tableData.length
  3401. for (let index = planDataLengths - 1; index >= 0; index--) {
  3402. if (this.tableData[index].id in idMap) {
  3403. this.tableData.splice(index, 1)
  3404. }
  3405. }
  3406. this.$message.success('删除消毒计划成功')
  3407. } else {
  3408. this.$message.error('删除消毒计划失败')
  3409. }
  3410. })
  3411. .catch(e => {})
  3412. })
  3413. .catch(() => {
  3414. return false
  3415. })
  3416. },
  3417. openDelete(id, index) {
  3418. // eslint-disable-next-line no-undef
  3419. this.$confirm(
  3420. '确认要删除所选记录吗? <br>删除后,信息将无法恢复',
  3421. '删除提示',
  3422. {
  3423. dangerouslyUseHTMLString: true,
  3424. confirmButtonText: '确定',
  3425. cancelButtonText: '取消',
  3426. type: 'warning'
  3427. }
  3428. ).then(() => {
  3429. openDelete(id, index).then(response => {
  3430. if (response.data.state === 1) {
  3431. var msg = response.data.data.msg
  3432. this.tableData.splice(index, 1)
  3433. this.planData.splice(index, 1)
  3434. }
  3435. })
  3436. })
  3437. },
  3438. openDeleteMahcineOne() {
  3439. if (this.selectMachinesOne.length == 0) {
  3440. this.$message.error('请选择要删除的信息')
  3441. return false
  3442. }
  3443. this.$confirm(
  3444. '确认要删除所选记录吗? <br>删除后,信息将无法恢复',
  3445. '删除提示',
  3446. {
  3447. dangerouslyUseHTMLString: true,
  3448. confirmButtonText: '确定',
  3449. cancelButtonText: '取消',
  3450. type: 'warning'
  3451. }
  3452. )
  3453. .then(() => {
  3454. var ids = []
  3455. var idMap = {}
  3456. for (const index in this.selectMachinesOne) {
  3457. ids.push(this.selectMachinesOne[index].id)
  3458. idMap[this.selectMachinesOne[index].id] = this.selectMachinesOne[
  3459. index
  3460. ].id
  3461. }
  3462. DeletePlans({ ids: ids })
  3463. .then(response => {
  3464. if (response.data.state == 1) {
  3465. var msg = response.data.data.msg
  3466. var planDataLength = this.tableData.length
  3467. for (let index = planDataLength - 1; index >= 0; index--) {
  3468. if (this.tableData[index].id in idMap) {
  3469. this.tableData.splice(index, 1)
  3470. }
  3471. }
  3472. var planDataLengths = this.planData.length
  3473. for (let index = planDataLengths - 1; index >= 0; index--) {
  3474. if (this.planData[index].id in idMap) {
  3475. this.planData.splice(index, 1)
  3476. }
  3477. }
  3478. this.$message.success('删除消毒计划成功')
  3479. } else {
  3480. this.$message.error('删除消毒计划失败')
  3481. }
  3482. })
  3483. .catch(e => {})
  3484. })
  3485. .catch(() => {
  3486. return false
  3487. })
  3488. },
  3489. getAllEquimentName() {
  3490. getAllEquimentName().then(response => {
  3491. if (response.data.state === 1) {
  3492. var equit = response.data.data.equit
  3493. // this.DeviceType = equit
  3494. }
  3495. })
  3496. },
  3497. clickQuery() {
  3498. this.$refs.multipleform.open()
  3499. },
  3500. getPatientInfo(bedid) {
  3501. getPatientInfo(bedid).then(response => {
  3502. if (response.data.state === 1) {
  3503. var schedules = response.data.data.schedules
  3504. // this.patientName = schedules
  3505. }
  3506. })
  3507. },
  3508. ChangeClass(id) {
  3509. ChangeClass(this.equimentid, id).then(response => {
  3510. if (response.data.state === 1) {
  3511. var patients = response.data.data.patients
  3512. if (patients.is_infectious === 0) {
  3513. this.userform.contagion = ''
  3514. }
  3515. if (patients.is_infectious === 1) {
  3516. this.userform.contagion = '无'
  3517. }
  3518. if (patients.is_infectious === 2) {
  3519. this.userform.contagion = '有'
  3520. }
  3521. this.userform.date = uParseTime(patients.schedule_date, '{y}-{m}-{d}')
  3522. this.userform.patient_name = patients.name
  3523. this.userform.patient_id = patients.patient_id
  3524. // this.userform.patient_name = patients.name
  3525. var zone = response.data.data.zone
  3526. // console.log('zone==========', zone)
  3527. this.userform.zone = zone.id
  3528. var number = response.data.data.number
  3529. // console.log('nubmer', number)
  3530. this.userform.bed_number = number.id
  3531. // this.userform.bed_number = number.number
  3532. var order = response.data.data.order
  3533. this.userform.start_time = uParseTime(order.start_time, '{y}-{m}-{d} {h}:{i}')
  3534. this.userform.end_time = uParseTime(order.end_time, '{y}-{m}-{d} {h}:{i}')
  3535. var prescription = response.data.data.prescription
  3536. this.userform.dialysis_mode = prescription.mode_id
  3537. var dislysis = response.data.data.dislysis
  3538. this.userform.dialysis_time = dislysis.actual_treatment_hour + 'h' + dislysis.actual_treatment_minute + 'min'
  3539. this.userform.hyperfiltratio = dislysis.actual_ultrafiltration
  3540. this.userform.weight_loss = dislysis.weight_loss
  3541. }
  3542. })
  3543. },
  3544. updateTimes(time) {
  3545. if (time < 0) {
  3546. return ''
  3547. } else {
  3548. return uParseTime(time, '{y}-{m}-{d} {h}:{i}')
  3549. }
  3550. },
  3551. getTimes(time) {
  3552. return uParseTime(time, '{y}-{m}-{d} {h}:{i}')
  3553. },
  3554. getTime(time) {
  3555. return uParseTime(time, '{y}-{m}-{d}')
  3556. },
  3557. SaveInformation(formName) {
  3558. if (this.userform.classtype === '') {
  3559. this.userform.classtype = 0
  3560. }
  3561. var classtypes = this.userform.classtype
  3562. var classtype = parseInt(classtypes)
  3563. this.userform.classtype = classtype
  3564. var zone = this.userform.zone
  3565. var zones = parseInt(zone)
  3566. this.userform.zone = zones
  3567. var bednumber = this.userform.bed_number
  3568. var bednumbers = parseInt(bednumber)
  3569. this.userform.bed_number = bednumbers
  3570. // var patientName = this.userform.patient_name
  3571. // var patient_name = parseInt(patientName)
  3572. // this.userform.patient_name = patient_name
  3573. var dialysismode = this.userform.dialysis_mode
  3574. var dialysis_mode = parseInt(dialysismode)
  3575. this.userform.dialysis_mode = dialysis_mode
  3576. if (this.userform.failure_stage === '') {
  3577. this.userform.failure_stage = 0
  3578. }
  3579. if (this.userform.dialysis_checked === '') {
  3580. this.userform.dialysis_checked = 0
  3581. }
  3582. if (this.userform.dialysis_checked === true) {
  3583. this.userform.dialysis_checked = 1
  3584. }
  3585. if (this.userform.dialysis_checked === false) {
  3586. this.userform.dialysis_checked = 2
  3587. }
  3588. if (this.userform.germ_checked === '') {
  3589. this.userform.germ_checked = 0
  3590. }
  3591. if (this.userform.germ_checked === true) {
  3592. this.userform.germ_checked = 1
  3593. }
  3594. if (this.userform.germ_checked === false) {
  3595. this.userform.germ_checked = 2
  3596. }
  3597. if (this.userform.dialysis_name === '') {
  3598. this.userform.dialysis_name = 0
  3599. }
  3600. var dialysis_name = this.userform.dialysis_name
  3601. var dialysis = parseInt(dialysis_name)
  3602. this.userform.dialysis_name = dialysis
  3603. if (this.userform.germ_name === '') {
  3604. this.userform.germ_name = 0
  3605. }
  3606. var germname = this.userform.germ_name
  3607. var germames = parseInt(germname)
  3608. this.userform.germ_name = germames
  3609. if (this.userform.clean === '') {
  3610. this.userform.clean = 0
  3611. }
  3612. if (this.userform.clean === true) {
  3613. this.userform.clean = 1
  3614. }
  3615. if (this.userform.clean === false) {
  3616. this.userform.clean = 2
  3617. }
  3618. // eslint-disable-next-line eqeqeq
  3619. if (this.userform.start_time == '') {
  3620. this.userform.start_time = '0'
  3621. }
  3622. // eslint-disable-next-line eqeqeq
  3623. if (this.userform.end_time == '') {
  3624. this.userform.end_time = '0'
  3625. }
  3626. // eslint-disable-next-line eqeqeq
  3627. if (this.userform.starttime == '') {
  3628. this.userform.starttime = '0'
  3629. }
  3630. // eslint-disable-next-line eqeqeq
  3631. if (this.userform.endtime == '') {
  3632. this.userform.endtime = '0'
  3633. }
  3634. if (this.userform.hyperfiltratio === '') {
  3635. this.userform.hyperfiltratio = 0
  3636. }
  3637. var hyperfiltratio = this.userform.hyperfiltratio
  3638. var hyperfiltratios = parseInt(hyperfiltratio)
  3639. this.userform.hyperfiltratio = hyperfiltratios
  3640. if (this.userform.weight_loss === '') {
  3641. this.userform.weight_loss = 0
  3642. }
  3643. var weightloss = this.userform.weight_loss
  3644. var weidht = parseInt(weightloss)
  3645. this.userform.weight_loss = weidht
  3646. if (this.userform.user_total === '0') {
  3647. this.userform.user_total = 0
  3648. }
  3649. // console.log('上机时间', this.userform.start_time)
  3650. // console.log('下机时间', this.userform.end_time)
  3651. this.$refs[formName].validate((valid) => {
  3652. if (valid) {
  3653. SaveInformation(this.equimentid, this.userform).then(response => {
  3654. if (response.data.state === 1) {
  3655. // eslint-disable-next-line no-unused-vars
  3656. var information = response.data.data.information
  3657. var infor = response.data.data.infor
  3658. this.userform.start_time = ''
  3659. this.userform.end_time = ''
  3660. this.userform.starttime = ''
  3661. this.userform.endtime = ''
  3662. this.userform.date = ''
  3663. this.userform.classtype = ''
  3664. this.userform.zone = ''
  3665. this.userform.patient_name = ''
  3666. this.userform.sign_name = ''
  3667. this.userform.bed_number = ''
  3668. this.userform.hyperfiltratio = ''
  3669. this.userform.weight_loss = ''
  3670. this.userform.dialysis_time = ''
  3671. this.$message.success('添加成功')
  3672. // this.$refs.child.getInformationData()
  3673. }
  3674. })
  3675. }
  3676. })
  3677. },
  3678. toLink() {
  3679. window.location.href = this.guaForm.images
  3680. },
  3681. // changStartTime(val) {
  3682. // this.userform.starttime = val
  3683. // },
  3684. // changeEndTime(val) {
  3685. // this.userform.endtime = val
  3686. // console.log('val', val)
  3687. // console.log('开始时间', this.userform.starttime)
  3688. // console.log('呵呵', this.formatDuring(val))
  3689. // },
  3690. // formatDuring(mss) {
  3691. // const days = parseInt(mss / (1000 * 60 * 60 * 24)) // 得到天数
  3692. // const hours = parseInt((mss % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60)) // 得到小时
  3693. // const minutes = parseInt((mss % (1000 * 60 * 60)) / (1000 * 60)) // 得到分钟数
  3694. // const seconds = (mss % (1000 * 60)) / 1000 // 得到秒数
  3695. // const str1 = hours < 10 ? ('0' + hours) : hours
  3696. // console.log('str1', str1)
  3697. // const str2 = minutes < 10 ? ('0' + minutes) : minutes
  3698. // return str1 + ':' + str2
  3699. // },
  3700. // 获取签名
  3701. getAllOrganization() {
  3702. getAllOrganization().then(response => {
  3703. if (response.data.state === 1) {
  3704. var approle = response.data.data.approle
  3705. // console.log('approle签名',approle)
  3706. this.autograph = approle
  3707. this.sampling = approle
  3708. }
  3709. })
  3710. },
  3711. getUserRegister(id) {
  3712. getUserRegister(id).then(response => {
  3713. if (response.data.state === 1) {
  3714. var information = response.data.data.information
  3715. // console.log('产讯使用登记', information)
  3716. // eslint-disable-next-line no-unused-vars
  3717. var role = response.data.data.role
  3718. // console.log('role', role)
  3719. // eslint-disable-next-line eqeqeq
  3720. var dislysis = response.data.data.dislysis
  3721. this.userform.id = information.id
  3722. if (information.date === 0) {
  3723. this.userform.date = moment(new Date()).format('YYYY-MM-DD')
  3724. } else {
  3725. this.userform.date = uParseTime(information.date, '{y}-{m}-{d}')
  3726. }
  3727. this.userform.classtype = information.class
  3728. this.userform.zone = information.zone
  3729. this.userform.bed_number = information.bed_number
  3730. this.userform.patient_name = information.name
  3731. this.userform.patient_id = information.patient_id
  3732. this.userform.contagion = information.contagion
  3733. this.userform.dialysis_mode = information.dialysis_mode
  3734. this.userform.start_time = this.updateTimes(information.start_time)
  3735. // this.userform.start_time = uParseTime(information.start_time, '{y}-{m}-{d} {h}:{i}')
  3736. this.userform.end_time = this.updateTimes(information.end_time)
  3737. // this.userform.end_time = uParseTime(information.end_time, '{y}-{m}-{d} {h}:{i}')
  3738. // this.userform.dialysis_time = information.dialysis_hour
  3739. // this.userform.hyperfiltratio = information.hyperfiltratio
  3740. // this.userform.weight_loss = information.weight_loss
  3741. if (information.hyperfiltratio === '') {
  3742. this.userform.hyperfiltratio = dislysis.actual_ultrafiltration
  3743. } else {
  3744. this.userform.hyperfiltratio = information.hyperfiltratio
  3745. }
  3746. if (information.dialysis_hour === '') {
  3747. this.userform.dialysis_time = dislysis.actual_treatment_hour + 'h' + dislysis.actual_treatment_minute + 'min'
  3748. } else {
  3749. this.userform.dialysis_time = information.dialysis_hour
  3750. }
  3751. // this.userform.dialysis_time = dislysis.actual_treatment_hour + 'h' + dislysis.actual_treatment_minute + 'min'
  3752. // this.userform.hyperfiltratio = dislysis.actual_ultrafiltration
  3753. if (information.weight_loss === '') {
  3754. this.userform.weight_loss = dislysis.weight_loss
  3755. } else {
  3756. this.userform.weight_loss = information.weight_loss
  3757. }
  3758. // this.userform.weight_loss = dislysis.weight_loss
  3759. this.userform.warning_value = information.warning_value
  3760. this.userform.user_total = information.user_total
  3761. if (information.move === 0) {
  3762. this.userform.run = 1
  3763. } else {
  3764. this.userform.run = information.move
  3765. }
  3766. this.userform.failure_stage = information.failure_stage
  3767. this.userform.fault_description = information.fault_description
  3768. this.userform.code_information = information.code_information
  3769. this.userform.disinfect_type = information.disinfect_type
  3770. this.userform.disinfection = information.disinfection
  3771. this.userform.machine_run = information.machine_run
  3772. this.userform.fluid_path = information.fluid_path
  3773. this.userform.disinfectant = information.disinfectant
  3774. this.userform.disinfectant = information.disinfection_status
  3775. this.userform.disinfection_residue = information.disinfection_residue
  3776. this.userform.longtime = information.long_time
  3777. this.userform.starttime = this.updateTimes(information.disinfec_startime)
  3778. this.userform.endtime = this.updateTimes(information.disinfec_endtime)
  3779. // this.userform.starttime = uParseTime(information.disinfec_startime, '{y}-{m}-{d} {h}:{i}')
  3780. // this.userform.endtime = uParseTime(information.disinfec_endtime, '{y}-{m}-{d} {h}:{i}')
  3781. if (information.dialysis_checked === 1) {
  3782. this.userform.dialysis_checked = true
  3783. }
  3784. if (information.dialysis_checked === 0) {
  3785. this.userform.dialysis_checked = false
  3786. }
  3787. if (information.dialysis_checked === 2) {
  3788. this.userform.dialysis_checked = false
  3789. }
  3790. this.userform.dialysis_name = information.dialysis_name
  3791. this.userform.norms = information.norms
  3792. this.userform.dialysis_concentration = information.dialysis_concentration
  3793. if (information.germ_checked === 0) {
  3794. this.userform.germ_checked = false
  3795. }
  3796. if (information.germ_checked === 2) {
  3797. this.userform.germ_checked = false
  3798. }
  3799. if (information.germ_checked === 1) {
  3800. this.userform.germ_checked = true
  3801. }
  3802. this.userform.germ_name = information.germ_name
  3803. this.userform.germ_number = information.germ_number
  3804. if (information.clean === 1) {
  3805. this.userform.clean = true
  3806. }
  3807. if (information.clean === 0) {
  3808. this.userform.clean = false
  3809. }
  3810. if (information.clean === 2) {
  3811. this.userform.clean = false
  3812. }
  3813. // eslint-disable-next-line eqeqeq
  3814. if (information.admin_user_id == 0) {
  3815. this.userform.sign_name = ''
  3816. } else {
  3817. this.userform.sign_name = information.admin_user_id
  3818. }
  3819. this.$forceUpdate()
  3820. }
  3821. })
  3822. },
  3823. getOrgName() {
  3824. getOrgName().then(response => {
  3825. if (response.data.state === 1) {
  3826. var org = response.data.data.org
  3827. this.qualityForm.detection_unit = org.org_name
  3828. this.qualityFormTwo.detection_unit = org.org_name
  3829. this.qualityFormThree.detection_unit = org.org_name
  3830. }
  3831. })
  3832. },
  3833. SaveBacteria(formName) {
  3834. if (this.qualityForm.specimen === '') {
  3835. this.qualityForm.specimen = 0
  3836. }
  3837. var specimen = this.qualityForm.specimen
  3838. var specimens = parseInt(specimen)
  3839. this.qualityForm.specimen = specimens
  3840. if (this.qualityForm.sampling_locationa === '') {
  3841. this.qualityForm.sampling_locationa = 0
  3842. }
  3843. var samplinglocationa = this.qualityForm.sampling_locationa
  3844. var samplinglocationas = parseInt(samplinglocationa)
  3845. this.qualityForm.sampling_locationa = samplinglocationas
  3846. this.$refs[formName].validate(response => {
  3847. SaveBacteria(this.equimentid, this.qualityForm).then(response => {
  3848. if (response.data.state === 1) {
  3849. var culture = response.data.data.culture
  3850. this.$message.success('保存成功')
  3851. this.qualityForm.specimen = '',
  3852. this.qualityForm.concentrate_noa = '',
  3853. this.qualityForm.concentrate_nob = '',
  3854. this.qualityForm.sampling_locationa = '',
  3855. this.qualityForm.sampler = ''
  3856. this.qualityForm.reporting_date = ''
  3857. this.qualityForm.detection_result = ''
  3858. this.$refs.child.getAllQulityInfo()
  3859. }
  3860. })
  3861. })
  3862. },
  3863. cleanSaveBacteria() {
  3864. this.qualityForm.specimen = '',
  3865. this.qualityForm.concentrate_noa = '',
  3866. this.qualityForm.concentrate_nob = '',
  3867. this.qualityForm.sampling_locationa = '',
  3868. this.qualityForm.sampler = ''
  3869. this.qualityForm.reporting_date = ''
  3870. this.qualityForm.detection_result = ''
  3871. },
  3872. SaveLincomycin(formName) {
  3873. this.$refs[formName].validate((valid) => {
  3874. if (this.qualityFormTwo.specimenb === '') {
  3875. this.qualityFormTwo.specimenb = 0
  3876. }
  3877. var specimen = this.qualityFormTwo.specimenb
  3878. var specimenb = parseInt(specimen)
  3879. this.qualityFormTwo.specimenb = specimenb
  3880. if (this.qualityFormTwo.sampling_locationb === '') {
  3881. this.qualityFormTwo.sampling_locationb = 0
  3882. }
  3883. var sampling = this.qualityFormTwo.sampling_locationb
  3884. var samplings = parseInt(sampling)
  3885. this.qualityFormTwo.sampling_locationb = samplings
  3886. if (valid) {
  3887. SaveLincomycin(this.equimentid, this.qualityFormTwo).then(response => {
  3888. if (response.data.state === 1) {
  3889. var dialysate = response.data.data.dialysate
  3890. this.$message.success('保存成功')
  3891. this.qualityFormTwo.specimenb = ''
  3892. this.qualityFormTwo.concentrate_noc = ''
  3893. this.qualityFormTwo.concentrateb_nod = ''
  3894. this.qualityFormTwo.sampling_locationb = ''
  3895. this.qualityFormTwo.samplerb = ''
  3896. this.qualityFormTwo.reporting_dateb = ''
  3897. this.qualityFormTwo.detection_resultb = ''
  3898. this.$refs.child.getAllQulityInfo()
  3899. }
  3900. })
  3901. }
  3902. })
  3903. },
  3904. cleanLincomycin() {
  3905. this.qualityFormTwo.specimenb = ''
  3906. this.qualityFormTwo.concentrate_noc = ''
  3907. this.qualityFormTwo.concentrateb_nod = ''
  3908. this.qualityFormTwo.sampling_locationb = ''
  3909. this.qualityFormTwo.samplerb = ''
  3910. this.qualityFormTwo.reporting_dateb = ''
  3911. this.qualityFormTwo.detection_resultb = ''
  3912. },
  3913. SaveQualityControl(formName) {
  3914. this.$refs[formName].validate((valid) => {
  3915. if (valid) {
  3916. SaveQualityControl(this.equimentid, this.qualityFormThree).then(response => {
  3917. if (response.data.state === 1) {
  3918. var ion = response.data.data.ion
  3919. // console.log('ion', ion)
  3920. this.$message.success('保存成功')
  3921. this.$refs.child.getAllQulityInfo()
  3922. this.qualityFormThree.samplerc = ''
  3923. this.qualityFormThree.concentrate_nof = ''
  3924. this.qualityFormThree.concentrate_nog = ''
  3925. this.qualityFormThree.date_reportc = ''
  3926. this.qualityFormThree.actual_na = ''
  3927. this.qualityFormThree.actual_pna = ''
  3928. this.qualityFormThree.actual_k = ''
  3929. this.qualityFormThree.actual_ca = ''
  3930. this.qualityFormThree.actual_ci = ''
  3931. this.qualityFormThree.actual_hco = ''
  3932. this.qualityFormThree.actual_mg = ''
  3933. this.qualityFormThree.actual_ph = ''
  3934. this.qualityFormThree.remakes = ''
  3935. }
  3936. })
  3937. }
  3938. })
  3939. },
  3940. cleanQuality() {
  3941. this.qualityFormThree.samplerc = ''
  3942. this.qualityFormThree.concentrate_nof = ''
  3943. this.qualityFormThree.concentrate_nog = ''
  3944. this.qualityFormThree.date_reportc = ''
  3945. this.qualityFormThree.actual_na = ''
  3946. this.qualityFormThree.actual_pna = ''
  3947. this.qualityFormThree.actual_k = ''
  3948. this.qualityFormThree.actual_ca = ''
  3949. this.qualityFormThree.actual_ci = ''
  3950. this.qualityFormThree.actual_hco = ''
  3951. this.qualityFormThree.actual_mg = ''
  3952. this.qualityFormThree.actual_ph = ''
  3953. this.qualityFormThree.remakes = ''
  3954. },
  3955. changeSpecimen(val) {
  3956. if (val === 0) {
  3957. this.disable = false
  3958. this.diableTwo = false
  3959. }
  3960. if (val === 1) {
  3961. this.disable = false
  3962. this.diableTwo = false
  3963. }
  3964. if (val === 2) {
  3965. this.qualityForm.concentrate_nob = ''
  3966. this.qualityFormTwo.concentrateb_nod = ''
  3967. this.diableTwo = true
  3968. this.disable = false
  3969. }
  3970. if (val === 3) {
  3971. this.qualityForm.concentrate_noa = ''
  3972. this.qualityFormTwo.concentrate_noc = ''
  3973. this.disable = true
  3974. this.diableTwo = false
  3975. }
  3976. if (val === 4) {
  3977. this.disable = false
  3978. this.diableTwo = false
  3979. }
  3980. if (val === 5) {
  3981. this.disable = false
  3982. this.diableTwo = false
  3983. }
  3984. },
  3985. beforeUploadFile(file) {
  3986. var testmsg = file.name.substring(file.name.lastIndexOf('.') + 1)
  3987. const extension = testmsg === 'jpg' || testmsg === 'JPG' || testmsg === 'png' || testmsg === 'PNG' || testmsg === 'gif' || testmsg === 'GIF'
  3988. if (!extension) {
  3989. // eslint-disable-next-line no-mixed-spaces-and-tabs
  3990. this.$message({
  3991. // eslint-disable-next-line no-mixed-spaces-and-tabs
  3992. message: '上传文件只能是jpg或者png或者gif格式!',
  3993. type: 'error'
  3994. })
  3995. return false// 必须加上return false; 才能阻止
  3996. }
  3997. this.filename = file.name
  3998. this.classShow = true
  3999. this.guaForm.imageName = file.name
  4000. const isLt2M = file.size / 1024 / 1024 <= 2048
  4001. var date = new Date()
  4002. var ext = getFileExtension(file.name)
  4003. var key = date.getFullYear() + (date.getMonth() + 1) + date.getDate() + date.getHours() + date.getMinutes() + date.getSeconds() + '_o_' + file.uid + '.' + ext
  4004. const _self = this
  4005. return new Promise((resolve, reject) => {
  4006. getToken().then(response => {
  4007. const token = response.data.data.uptoken
  4008. console.log('token', token)
  4009. _self._data.uploadFileData.token = token
  4010. _self._data.uploadFileData.key = key
  4011. resolve(true)
  4012. // eslint-disable-next-line handle-callback-err
  4013. }).catch(err => {
  4014. reject(false)
  4015. })
  4016. })
  4017. },
  4018. handleSuccess(res, file, fileList) {
  4019. this.guaForm.images = this.qiniuDomain + res.url
  4020. console.log('图片路径', this.guaForm.images)
  4021. this.$refs.upload.clearFiles()
  4022. this.filename = file.name
  4023. this.guaForm.imageName = file.name
  4024. },
  4025. // eslint-disable-next-line no-dupe-keys
  4026. getTime(value, temp) {
  4027. // eslint-disable-next-line eqeqeq
  4028. if (value != undefined) {
  4029. return parseTime(value, temp)
  4030. }
  4031. return ''
  4032. },
  4033. SaveRepair(formName) {
  4034. if (this.guaForm.start_time === '') {
  4035. this.guaForm.start_time = '0'
  4036. }
  4037. if (this.guaForm.arrive_time === '') {
  4038. this.guaForm.arrive_time = '0'
  4039. }
  4040. if (this.guaForm.finish_time === '') {
  4041. this.guaForm.finish_time = '0'
  4042. }
  4043. if (this.guaForm.failure_stage === '') {
  4044. this.guaForm.failure_stage = '0'
  4045. }
  4046. var failurestages = this.guaForm.failure_stage
  4047. var falur = parseInt(failurestages)
  4048. this.guaForm.failure_stage = falur
  4049. if (this.guaForm.exclude === '') {
  4050. this.guaForm.exclude = 0
  4051. }
  4052. var excludes = this.guaForm.exclude
  4053. var exclude = parseInt(excludes)
  4054. this.guaForm.exclude = exclude
  4055. this.$refs[formName].validate((valid) => {
  4056. if (valid) {
  4057. SaveRepair(this.equimentid, this.guaForm).then(response => {
  4058. if (response.data.state === 1) {
  4059. var repair = response.data.data.repair
  4060. // console.log('reqair', repair)
  4061. this.$message.success('保存成功')
  4062. this.$refs.child.getAllRepair()
  4063. this.guaForm.start_time = ''
  4064. this.guaForm.arrive_time = ''
  4065. this.guaForm.finish_time = ''
  4066. this.guaForm.total_distance = ''
  4067. this.guaForm.code_information = ''
  4068. this.guaForm.fault_description = ''
  4069. this.guaForm.cause_analysis = ''
  4070. this.guaForm.reason = ''
  4071. this.guaForm.failure_stage = 0
  4072. this.guaForm.exclude = 0
  4073. this.guaForm.images = ''
  4074. this.guaForm.treatment_process = ''
  4075. this.classShow = false
  4076. this.guaForm.imageName = ''
  4077. }
  4078. })
  4079. }
  4080. })
  4081. },
  4082. querySearchAsync(keyword, cb) {
  4083. let key = ''
  4084. if (keyword != undefined) {
  4085. key = keyword
  4086. }
  4087. let searchArray = []
  4088. PostSearch(key).then(response => {
  4089. if (response.data.state == 1) {
  4090. searchArray = response.data.data.patient
  4091. // console.log("ser",searchArray)
  4092. cb(searchArray)
  4093. }
  4094. })
  4095. return searchArray
  4096. },
  4097. createFilter(queryString) {
  4098. return (searchArray) => {
  4099. return (searchArray.id.toLowerCase().indexOf(queryString.toLowerCase()) === 0)
  4100. }
  4101. },
  4102. handleSelect(item) {
  4103. this.userform.patient_id = item.id
  4104. this.userform.patient_name = item.name
  4105. // eslint-disable-next-line no-undef
  4106. getPatientDetail(item.id).then(response => {
  4107. // eslint-disable-next-line eqeqeq
  4108. if (response.data.state == 1) {
  4109. var patient = response.data.data.patient
  4110. // console.log('patient', patient)
  4111. // eslint-disable-next-line no-undef
  4112. if (patient.is_infectious === 0) {
  4113. this.userform.contagion = ''
  4114. }
  4115. // eslint-disable-next-line no-undef
  4116. if (patient.is_infectious === 1) {
  4117. this.userform.contagion = '无'
  4118. }
  4119. // eslint-disable-next-line no-undef
  4120. if (patient.is_infectious === 2) {
  4121. this.userform.contagion = '有'
  4122. }
  4123. }
  4124. })
  4125. },
  4126. getAllEquitType() {
  4127. getAllEquitType().then(response => {
  4128. if (response.data.state === 1) {
  4129. var equitname = response.data.data.mode
  4130. this.DeviceType = equitname
  4131. }
  4132. })
  4133. },
  4134. getTotalNumber() {
  4135. getTotalNumber(this.equimentid).then(response => {
  4136. if (response.data.state === 1) {
  4137. var total = response.data.data.total
  4138. if (total === '') {
  4139. this.userform.user_total = ''
  4140. }
  4141. this.userform.user_total = total
  4142. } else {
  4143. this.$message.error('数据返回失败')
  4144. }
  4145. })
  4146. },
  4147. getAllpatient() {
  4148. getAllpatient().then(response => {
  4149. if (response.data.state === 1) {
  4150. var allpatient = response.data.data.allpatient
  4151. this.patientName = allpatient
  4152. }
  4153. })
  4154. },
  4155. getTimeWarning(id) {
  4156. getTimeWarning(id).then(response => {
  4157. if (response.data.state === 1) {
  4158. var information = response.data.data.information
  4159. var time = this.getTimestamp(this.userform.date) - information.stime
  4160. // console.log('时间', time)
  4161. // if (time < 2678400) {
  4162. // this.warnShow = false
  4163. // }
  4164. var deviceInformation = response.data.data.deviceInformation
  4165. var timetwo = this.getTimestamp(this.userform.date) - deviceInformation.stime
  4166. // if (timetwo < 2678400) {
  4167. // this.warnShowTwo = false
  4168. // }
  4169. var clean = response.data.data.clean
  4170. // var timethree = this.getTimestamp(this.userform.date) - clean.stime
  4171. // if (timethree < 2678400) {
  4172. // this.warnShowThree = false
  4173. // }
  4174. }
  4175. })
  4176. },
  4177. getTimeBeteen(id) {
  4178. var todayTime = moment(new Date()).format('YYYY-MM-DD')
  4179. // console.log('todayTime', todayTime)
  4180. getTimeBeteen(id, todayTime).then(response => {
  4181. if (response.data.state === 1) {
  4182. var timedata = response.data.data.timeData
  4183. if (timedata.length === 0) {
  4184. this.warnShow = true
  4185. }
  4186. if (timedata.length !== 0) {
  4187. this.warnShow = false
  4188. }
  4189. var todayTimeTwo = response.data.data.timeDataTwo
  4190. // console.log('todayTimeTwo', todayTimeTwo)
  4191. if (todayTimeTwo.length === 0) {
  4192. this.warnShowTwo = true
  4193. }
  4194. if (todayTimeTwo.length !== 0) {
  4195. this.warnShowTwo = false
  4196. }
  4197. var timeDataThree = response.data.data.timeDataThree
  4198. console.log('timeDataThree', timeDataThree)
  4199. if (timeDataThree.length === 0) {
  4200. this.warnShowThree = true
  4201. }
  4202. if (timeDataThree.length !== 0) {
  4203. this.warnShowThree = false
  4204. }
  4205. }
  4206. })
  4207. },
  4208. getTimestamp(time) { // 把时间日期转成时间戳
  4209. return (new Date(time)).getTime() / 1000
  4210. },
  4211. // eslint-disable-next-line no-irregular-whitespace
  4212. // 通过自组建传值改变表格数据
  4213. getPlanData(data) {
  4214. if (data === 1) {
  4215. this.getAllPlanDetail(this.unitType)
  4216. }
  4217. },
  4218. getAllMode() {
  4219. getAllMode().then(response => {
  4220. var mode = response.data.data.mode
  4221. this.deviceMode = mode
  4222. })
  4223. },
  4224. selectChange(id) {
  4225. selectChange(id).then(response => {
  4226. if (response.data.state === 1) {
  4227. this.userform.bed_number = ''
  4228. var change = response.data.data.change
  4229. this.bedNumberTwo = change
  4230. // console.log('change', change)
  4231. }
  4232. })
  4233. },
  4234. selectBed(id) {
  4235. selectBed(id).then(response => {
  4236. if (response.data.state === 1) {
  4237. var zone = response.data.data.zone
  4238. }
  4239. })
  4240. },
  4241. getData(id) {
  4242. selectBed(id).then(response => {
  4243. if (response.data.state === 1) {
  4244. var zone = response.data.data.zone
  4245. this.$forceUpdate()
  4246. this.userform.bed_number = zone.id
  4247. this.userform.zone = zone.zone_id
  4248. // console.log('zone', zone)
  4249. }
  4250. })
  4251. },
  4252. hiddenShow() {
  4253. this.$confirm(
  4254. '确认要删除所选图片吗? <br>删除后,信息将无法恢复',
  4255. '删除提示',
  4256. {
  4257. dangerouslyUseHTMLString: true,
  4258. confirmButtonText: '确定',
  4259. cancelButtonText: '取消',
  4260. type: 'warning'
  4261. }
  4262. ).then(() => {
  4263. this.filename = ''
  4264. this.guaForm.imageName = ''
  4265. this.guaForm.images = ''
  4266. this.classShow = false
  4267. })
  4268. }
  4269. },
  4270. created() {
  4271. this.getAllSubregion()
  4272. this.getAllMachine()
  4273. var index = this.$route.query.index
  4274. var bedid = this.$route.query.bedid
  4275. // var id = this.$route.query.id
  4276. // this.equimentid = id
  4277. this.bedid = bedid
  4278. this.getAllPlan()
  4279. this.getAllEquimentName()
  4280. this.getAllOrganization()
  4281. this.getOrgName()
  4282. this.getAllEquitType()
  4283. this.getAllpatient()
  4284. this.getAllMode()
  4285. }
  4286. }
  4287. </script>
  4288. <style lang="scss" scoped>
  4289. .zone{
  4290. // margin-left: 30px;
  4291. // text-align: left;
  4292. width: 70px;
  4293. display: inline-block;
  4294. color:#606266;
  4295. }
  4296. .disinfect{
  4297. position: relative;
  4298. .newButton{
  4299. // position: absolute;
  4300. // right: 2%;
  4301. // top:4px;
  4302. // z-index: 9;
  4303. margin-bottom: 10px;
  4304. margin-left: 90%;
  4305. }
  4306. }
  4307. .disinfectOne{
  4308. position: relative;
  4309. .newButtonOne{
  4310. position: absolute;
  4311. right: 0;
  4312. top: -10;
  4313. z-index: 18;
  4314. }
  4315. }
  4316. .but{
  4317. width: 200px;
  4318. height: 50px;
  4319. // border: solid 1px red;
  4320. margin-left: 77%;
  4321. }
  4322. .clearn{
  4323. width: 460px;
  4324. height: 50px;
  4325. // border:solid 1px red;
  4326. margin-left:650px;
  4327. }
  4328. .zClass{
  4329. width: 200px;
  4330. height: 200px;
  4331. // border:solid 1px red;
  4332. margin-left: 450px;
  4333. margin-top: 200px;
  4334. }
  4335. .warn{
  4336. color: red;
  4337. font-size: 14px;
  4338. width: 100%;
  4339. display: inline-block;
  4340. margin-left: 96px;
  4341. }
  4342. .userbutton{
  4343. margin-bottom: 10px;
  4344. margin-left: 82%
  4345. }
  4346. </style>
  4347. <style lang="scss">
  4348. .a{
  4349. margin-bottom: 10px;
  4350. margin-top: 6px;
  4351. }
  4352. .b{
  4353. .el-button{
  4354. margin-left: 90%;
  4355. margin-bottom: 10px;
  4356. }
  4357. }
  4358. .stoppage{
  4359. .el-form-item__label{
  4360. width:190px;
  4361. }
  4362. }
  4363. .st{
  4364. .el-form-item__label{
  4365. width:-10px;
  4366. }
  4367. }
  4368. .main{
  4369. position: relative;
  4370. .newButtonOne{
  4371. position:absolute;
  4372. right: 0;
  4373. z-index: 2;
  4374. }
  4375. }
  4376. .elbutton{
  4377. // border: solid 1px red;
  4378. height: 50px;
  4379. width: 400px;
  4380. margin-left: 650px;
  4381. }
  4382. // .el-form-item__label {
  4383. // width: 130px;
  4384. // font-size: 14px;
  4385. // }
  4386. .el-form-item__error {
  4387. margin-left: 130px;
  4388. }
  4389. .el-upload-list__item-name {
  4390. color: #606266;
  4391. display: block;
  4392. margin-right: 40px;
  4393. overflow: hidden;
  4394. padding-left: 4px;
  4395. text-overflow: ellipsis;
  4396. transition: color .3s;
  4397. white-space: nowrap;
  4398. }
  4399. .el-main{
  4400. padding-top: 0px;
  4401. }
  4402. .newMain{
  4403. .el-form-item__label{
  4404. width: 104px;
  4405. }
  4406. }
  4407. .newDisinfectOne{
  4408. .el-input--prefix .el-input__inner{
  4409. padding-left: 15px
  4410. }
  4411. }
  4412. .stoppage{
  4413. .el-form-item__label{
  4414. width: 18%;
  4415. }
  4416. }
  4417. .newItem{
  4418. .el-form-item__label{
  4419. width: 130px;
  4420. }
  4421. }
  4422. .formItem{
  4423. .el-form-item__label{
  4424. width: 104px;
  4425. line-height: 30px;
  4426. }
  4427. }
  4428. .newname{
  4429. .el-form-item__label{
  4430. width: 60px;
  4431. }
  4432. }
  4433. ::-webkit-scrollbar{
  4434. height: 20px;
  4435. }
  4436. </style>