血透系统PC前端

home.vue 210KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386338733883389339033913392339333943395339633973398339934003401340234033404340534063407340834093410341134123413341434153416341734183419342034213422342334243425342634273428342934303431343234333434343534363437343834393440344134423443344434453446344734483449345034513452345334543455345634573458345934603461346234633464346534663467346834693470347134723473347434753476347734783479348034813482348334843485348634873488348934903491349234933494349534963497349834993500350135023503350435053506350735083509351035113512351335143515351635173518351935203521352235233524352535263527352835293530353135323533353435353536353735383539354035413542354335443545354635473548354935503551355235533554355535563557355835593560356135623563356435653566356735683569357035713572357335743575357635773578357935803581358235833584358535863587358835893590359135923593359435953596359735983599360036013602360336043605360636073608360936103611361236133614361536163617361836193620362136223623362436253626362736283629363036313632363336343635363636373638363936403641364236433644364536463647364836493650365136523653365436553656365736583659366036613662366336643665366636673668366936703671367236733674367536763677367836793680368136823683368436853686368736883689369036913692369336943695369636973698369937003701370237033704370537063707370837093710371137123713371437153716371737183719372037213722372337243725372637273728372937303731373237333734373537363737373837393740374137423743374437453746374737483749375037513752375337543755375637573758375937603761376237633764376537663767376837693770377137723773377437753776377737783779378037813782378337843785378637873788378937903791379237933794379537963797379837993800380138023803380438053806380738083809381038113812381338143815381638173818381938203821382238233824382538263827382838293830383138323833383438353836383738383839384038413842384338443845384638473848384938503851385238533854385538563857385838593860386138623863386438653866386738683869387038713872387338743875387638773878387938803881388238833884388538863887388838893890389138923893389438953896389738983899390039013902390339043905390639073908390939103911391239133914391539163917391839193920392139223923392439253926392739283929393039313932393339343935393639373938393939403941394239433944394539463947394839493950395139523953395439553956395739583959396039613962396339643965396639673968396939703971397239733974397539763977397839793980398139823983398439853986398739883989399039913992399339943995399639973998399940004001400240034004400540064007400840094010401140124013401440154016401740184019402040214022402340244025402640274028402940304031403240334034403540364037403840394040404140424043404440454046404740484049405040514052405340544055405640574058405940604061406240634064406540664067406840694070407140724073407440754076407740784079408040814082408340844085408640874088408940904091409240934094409540964097409840994100410141024103410441054106410741084109411041114112411341144115411641174118411941204121412241234124412541264127412841294130413141324133413441354136413741384139414041414142414341444145414641474148414941504151415241534154415541564157415841594160416141624163416441654166416741684169417041714172417341744175417641774178417941804181418241834184418541864187418841894190419141924193419441954196419741984199420042014202420342044205420642074208420942104211421242134214421542164217421842194220422142224223422442254226422742284229423042314232423342344235423642374238423942404241424242434244424542464247424842494250425142524253425442554256425742584259426042614262426342644265426642674268426942704271427242734274427542764277427842794280428142824283428442854286428742884289429042914292429342944295429642974298429943004301430243034304430543064307430843094310431143124313431443154316431743184319432043214322432343244325432643274328432943304331433243334334433543364337433843394340434143424343434443454346434743484349435043514352435343544355435643574358435943604361436243634364436543664367436843694370437143724373437443754376437743784379438043814382438343844385438643874388438943904391439243934394439543964397439843994400440144024403440444054406440744084409441044114412441344144415441644174418441944204421442244234424442544264427442844294430443144324433443444354436443744384439444044414442444344444445444644474448444944504451445244534454445544564457445844594460446144624463446444654466446744684469447044714472447344744475447644774478447944804481448244834484448544864487448844894490449144924493449444954496449744984499450045014502450345044505450645074508450945104511451245134514451545164517451845194520452145224523452445254526452745284529453045314532453345344535453645374538453945404541454245434544454545464547454845494550455145524553455445554556455745584559456045614562456345644565456645674568456945704571457245734574457545764577457845794580458145824583458445854586458745884589459045914592459345944595459645974598459946004601460246034604460546064607460846094610461146124613461446154616461746184619462046214622462346244625462646274628462946304631463246334634463546364637463846394640
  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. for(let j=0;j<addmahcer.length;j++){
  2621. if(addmahcer[j].device_type == 1){
  2622. addmahcer[j].bed_number = addmahcer[j].number
  2623. }
  2624. if(addmahcer[j].device_type == 2){
  2625. addmahcer[j].bed_number = addmahcer[j].bed_number
  2626. }
  2627. if(addmahcer[j].device_type == 3){
  2628. addmahcer[j].bed_number = addmahcer[j].bed_number
  2629. }
  2630. }
  2631. this.tableDatatwo = addmahcer
  2632. this.tabIndex = this.$route.query.index
  2633. var id = this.$route.query.id
  2634. for (let i = 0; i < this.tableDatatwo.length; i++) {
  2635. if (this.tableDatatwo[i].id == id) {
  2636. this.$refs.singleTable.setCurrentRow(this.tableDatatwo[i])
  2637. break
  2638. }
  2639. }
  2640. // this.$refs.singleTable.setCurrentRow(this.tableDatatwo[this.tabIndex])
  2641. }
  2642. })
  2643. },
  2644. handleIndex(index) {
  2645. this.tabIndex = index
  2646. },
  2647. handleCurrentChange(val) {
  2648. this.unitType = val.unit_type
  2649. // console.log('val是什么', val)
  2650. this.currentRow = val
  2651. this.$forceUpdate()
  2652. this.getMachineDetailById(val.id)
  2653. this.equimentid = val.id
  2654. this.userdata = val.id
  2655. this.getAllPlanDetail(val.unit_type)
  2656. this.getPatientInfo(val.id)
  2657. // 获取基本信息
  2658. this.getUserRegister(val.id)
  2659. // 病人下机后插入数据
  2660. this.getAutoData(val.id)
  2661. this.getTotalNumber(val.id)
  2662. // this.getTimeWarning(val.id)
  2663. this.getTimeBeteen(val.id)
  2664. this.getData(val.bed_id)
  2665. },
  2666. getAutoData(id) {
  2667. getAutoData(id).then(response => {
  2668. if (response.data.state === 1) {
  2669. var dialysis = response.data.data.dialysis
  2670. }
  2671. })
  2672. },
  2673. getMachineDetailById(id) {
  2674. getMachineDetailById(id).then(response => {
  2675. if (response.data.state === 1) {
  2676. var addmacher = response.data.data.addmacher
  2677. console.log('设备详情', addmacher)
  2678. var warning = response.data.data.warning
  2679. // console.log('warning', warning)
  2680. var time = this.getTimestamp(this.userform.date) - warning.stime
  2681. // console.log('时间', time)
  2682. // if (time < 2678400 && warning.dialysis_checked === 1) {
  2683. // this.warnShow = false
  2684. // } else {
  2685. // this.warnShow = true
  2686. // }
  2687. var germ = response.data.data.germ
  2688. // console.log('germ', germ)
  2689. var timetwo = this.getTimestamp(this.userform.date) - germ.stime
  2690. // console.log('时间', timetwo)
  2691. // if (timetwo < 2678400 && germ.germ_checked === 1) {
  2692. // this.warnShowTwo = false
  2693. // } else {
  2694. // this.warnShowTwo = true
  2695. // }
  2696. var clean = response.data.data.clean
  2697. var timethree = this.getTimestamp(this.userform.date) - clean.stime
  2698. // console.log('时间', timethree)
  2699. // if (timethree < 2678400 && clean.clean === 1) {
  2700. // this.warnShowThree = false
  2701. // } else {
  2702. // this.warnShowThree = true
  2703. // }
  2704. var number = response.data.data.number
  2705. // console.log('number', number)
  2706. this.Number = number
  2707. if (addmacher.device_type === 1) {
  2708. this.sShow = false
  2709. this.qShow = false
  2710. this.tShow = true
  2711. this.DisShow = true
  2712. this.DioShow = false
  2713. this.zhiShow = true
  2714. this.zhShow = false
  2715. this.UserShow = true
  2716. this.Ushow = false
  2717. }
  2718. if (addmacher.device_type === 2) {
  2719. this.tShow = false
  2720. this.qShow = false
  2721. this.sShow = true
  2722. this.DisShow = false
  2723. this.DioShow = true
  2724. this.zhiShow = true
  2725. this.zhShow = false
  2726. this.UserShow = true
  2727. this.Ushow = false
  2728. }
  2729. if (addmacher.device_type === 3) {
  2730. this.tShow = false
  2731. this.sShow = false
  2732. this.qShow = true
  2733. this.DisShow = false
  2734. this.DioShow = true
  2735. this.zhiShow = false
  2736. this.zhShow = true
  2737. this.UserShow = false
  2738. this.Ushow = true
  2739. }
  2740. var mode = response.data.data.mode
  2741. var zone = response.data.data.zone
  2742. const arr1 = []
  2743. // const cityOptions = ['HD', 'HDF', 'HD+HP', 'HP', 'HF', 'SCUF', 'IUF', 'HFHD+HP', 'HFR', 'HDF+HP', 'GRRT', '腹水回收']
  2744. for (let index = 0; index < mode.length; index++) {
  2745. if (mode[index].treate_mode === 1) {
  2746. mode[index] = 'HD'
  2747. }
  2748. if (mode[index].treate_mode === 2) {
  2749. mode[index] = 'HDF'
  2750. }
  2751. if (mode[index].treate_mode === 3) {
  2752. mode[index] = 'HD+HP'
  2753. }
  2754. if (mode[index].treate_mode === 4) {
  2755. mode[index] = 'HP'
  2756. }
  2757. if (mode[index].treate_mode === 5) {
  2758. mode[index] = 'HF'
  2759. }
  2760. if (mode[index].treate_mode === 6) {
  2761. mode[index] = 'SCUF'
  2762. }
  2763. if (mode[index].treate_mode === 7) {
  2764. mode[index] = 'IUF'
  2765. }
  2766. if (mode[index].treate_mode === 8) {
  2767. mode[index] = 'HFHD'
  2768. }
  2769. if (mode[index].treate_mode === 9) {
  2770. mode[index] = 'HFHD+HP'
  2771. }
  2772. if (mode[index].treate_mode === 10) {
  2773. mode[index] = 'PHF'
  2774. }
  2775. if (mode[index].treate_mode === 11) {
  2776. mode[index] = 'HFR'
  2777. }
  2778. if (mode[index].treate_mode === 12) {
  2779. mode[index] = 'HDF+HP'
  2780. }
  2781. if (mode[index].treate_mode === 13) {
  2782. mode[index] = 'CRRT'
  2783. }
  2784. if (mode[index].treate_mode === 14) {
  2785. mode[index] = '腹水回输'
  2786. }
  2787. arr1.push(mode[index])
  2788. }
  2789. this.form.treat_mode = arr1
  2790. this.form.id = addmacher.id
  2791. this.form.serial_number = addmacher.serial_number
  2792. this.form.devicetype = addmacher.device_type
  2793. this.form.bed_number = addmacher.bed_id
  2794. this.form.bed_numbers = addmacher.bed_number
  2795. this.form.beds = addmacher.bed_number
  2796. this.form.device_name = addmacher.device_name
  2797. this.form.manufacture_factory = addmacher.manufacture_factory
  2798. this.form.service_manufacturer = addmacher.service_manufacturer
  2799. // this.form.unit_type = addmacher.unit_type
  2800. this.form.unit_type = parseInt(addmacher.device_mode)
  2801. this.form.use_section = addmacher.use_section
  2802. this.form.section_number = addmacher.section_number
  2803. if (addmacher.buy_date !== 0) {
  2804. this.form.buy_date = uParseTime(addmacher.buy_date, '{y}-{m}-{d}')
  2805. }
  2806. if (addmacher.install_date !== 0) {
  2807. this.form.install_date = uParseTime(addmacher.install_date, '{y}-{m}-{d}')
  2808. }
  2809. if (addmacher.start_date !== 0) {
  2810. this.form.start_date = uParseTime(addmacher.start_date, '{y}-{m}-{d}')
  2811. }
  2812. this.form.maintenance_engineer = addmacher.maintenace_engineer
  2813. this.form.telephone = addmacher.telephone
  2814. this.form.guarantee_date = addmacher.guarantee_date
  2815. this.form.machine_status = addmacher.machine_status
  2816. this.form.user_total = addmacher.user_total
  2817. this.form.remarks = addmacher.remarks
  2818. // this.form.device_mode = addmacher.device_mode
  2819. if (addmacher.rubbish_date !== 0) {
  2820. this.form.rubbish_date = uParseTime(addmacher.rubbish_date, '{y}-{m}-{d}')
  2821. }
  2822. this.form.rubbish_reason = addmacher.rubbish_reason
  2823. this.form.user_year = addmacher.user_year
  2824. this.form.work_time = addmacher.work_time
  2825. // eslint-disable-next-line eqeqeq
  2826. if (addmacher.disinfection_mode == 0) {
  2827. this.form.Disinfection_mode = 0
  2828. } else {
  2829. this.form.Disinfection_mode = addmacher.disinfection_mode
  2830. }
  2831. // eslint-disable-next-line eqeqeq
  2832. if (addmacher.revers_mode == 0) {
  2833. this.form.revers_mode = 0
  2834. } else {
  2835. this.form.revers_mode = addmacher.revers_mode
  2836. }
  2837. this.getAllSubregion()
  2838. }
  2839. })
  2840. },
  2841. UpdateMachine() {
  2842. this.cancelShow = true
  2843. this.confirmShow = true
  2844. this.disableThree = false
  2845. this.disableFour = false
  2846. this.disableFive = false
  2847. },
  2848. UpdateMachineInfo(formName) {
  2849. const arr2 = []
  2850. this.form.treat_mode.map((item, index) => {
  2851. const obj = {}
  2852. if (item === 'HD') {
  2853. obj.id = 1
  2854. }
  2855. if (item === 'HDF') {
  2856. obj.id = 2
  2857. }
  2858. if (item === 'HD+HP') {
  2859. obj.id = 3
  2860. }
  2861. if (item === 'HP') {
  2862. obj.id = 4
  2863. }
  2864. if (item === 'HF') {
  2865. obj.id = 5
  2866. }
  2867. if (item === 'SCUF') {
  2868. obj.id = 6
  2869. }
  2870. if (item === 'IUF') {
  2871. obj.id = 7
  2872. }
  2873. if (item === 'HFHD') {
  2874. obj.id = 8
  2875. }
  2876. if (item === 'HFHD+HP') {
  2877. obj.id = 9
  2878. }
  2879. if (item === 'PHF') {
  2880. obj.id = 10
  2881. }
  2882. if (item === 'HFR') {
  2883. obj.id = 11
  2884. }
  2885. if (item === 'HDF+HP') {
  2886. obj.id = 12
  2887. }
  2888. if (item === 'CRRT') {
  2889. obj.id = 13
  2890. }
  2891. if (item === '腹水回输') {
  2892. obj.id = 14
  2893. }
  2894. arr2.push(obj.id)
  2895. })
  2896. this.form.treat_type = arr2
  2897. var device_type = this.form.devicetype
  2898. var device_types = parseInt(device_type)
  2899. this.form.devicetype = device_types
  2900. if (this.form.rubbish_reason === '') {
  2901. this.form.rubbish_reason = 0
  2902. }
  2903. var rubbish_reason = this.form.rubbish_reason
  2904. var rubbish_reasons = parseInt(rubbish_reason)
  2905. this.form.rubbish_reason = rubbish_reasons
  2906. var machine_status = this.form.machine_status
  2907. var machine_statuss = parseInt(machine_status)
  2908. this.form.machine_status = machine_statuss
  2909. // if (this.form.bed_number === '') {
  2910. // this.form.bed_number = 0
  2911. // }
  2912. var bed_numbers = this.form.bed_number
  2913. var bed_numberss = parseInt(bed_numbers)
  2914. this.form.bed_number = bed_numberss
  2915. this.$refs[formName].validate(valid => {
  2916. UpdateMachineInfo(this.form).then(response => {
  2917. // console.log('form', this.form)
  2918. if (response.data.state === 1) {
  2919. var addmacher = response.data.data.addmacher
  2920. // console.log('addmacher----', addmacher)
  2921. this.$message.success('修改成功')
  2922. // this.$router.push({ path: '/device/home?index=' + this.tabIndex })
  2923. for (let i = 0; i < this.tableDatatwo.length; i++) {
  2924. if (this.tableDatatwo[i].id == addmacher.id) {
  2925. for (let j = 0; j < this.deviceMode.length; j++) {
  2926. if (this.deviceMode[j].id === parseInt(addmacher.unit_type)) {
  2927. addmacher.device_mode = this.deviceMode[j].device_mode
  2928. // this.$forceUpdate()
  2929. }
  2930. }
  2931. this.tableDatatwo[i] = addmacher
  2932. // this.$refs.singleTable.setCurrentRow(this.tableDatatwo[i])
  2933. }
  2934. }
  2935. // this.getAllMachine()
  2936. // this.getAllSubregion()
  2937. this.$refs.singleTable.setCurrentRow(addmacher)
  2938. this.$forceUpdate()
  2939. }else{
  2940. this.$message.error("修改失败");
  2941. }
  2942. })
  2943. })
  2944. },
  2945. // eslint-disable-next-line no-irregular-whitespace
  2946. // 更新水处理机
  2947. UpdateMachineInfoTwo(formName) {
  2948. var device_type = this.form.devicetype
  2949. var device_types = parseInt(device_type)
  2950. this.form.devicetype = device_types
  2951. if (this.form.rubbish_reason === '') {
  2952. this.form.rubbish_reason = 0
  2953. }
  2954. var rubbish_reason = this.form.rubbish_reason
  2955. var rubbish_reasons = parseInt(rubbish_reason)
  2956. this.form.rubbish_reason = rubbish_reasons
  2957. var machine_status = this.form.machine_status
  2958. var machine_statuss = parseInt(machine_status)
  2959. this.form.machine_status = machine_statuss
  2960. var revers_mode = this.form.revers_mode
  2961. var revers_modes = parseInt(revers_mode)
  2962. this.form.revers_mode = revers_modes
  2963. var disinfecction_modes = this.form.Disinfection_mode
  2964. var disinfecction_modess = parseInt(disinfecction_modes)
  2965. this.form.Disinfection_mode = disinfecction_modess
  2966. this.$refs[formName].validate(valid => {
  2967. if (valid) {
  2968. UpdateMachineInfoTwo(this.form).then(response => {
  2969. if (response.data.state === 1) {
  2970. // eslint-disable-next-line no-unused-vars
  2971. var addmacher = response.data.data.addmacher
  2972. this.$message.success('修改成功')
  2973. for (let i = 0; i < this.tableDatatwo.length; i++) {
  2974. if (this.tableDatatwo[i].id == addmacher.id) {
  2975. for (let j = 0; j < this.deviceMode.length; j++) {
  2976. if (this.deviceMode[j].id === parseInt(addmacher.unit_type)) {
  2977. addmacher.device_mode = this.deviceMode[j].device_mode
  2978. // this.$forceUpdate()
  2979. }
  2980. }
  2981. this.tableDatatwo[i] = addmacher
  2982. // this.$refs.singleTable.setCurrentRow(this.tableDatatwo[i])
  2983. }
  2984. }
  2985. // this.getAllMachine()
  2986. this.getAllSubregion()
  2987. this.$refs.singleTable.setCurrentRow(addmacher)
  2988. this.$forceUpdate()
  2989. }
  2990. })
  2991. }
  2992. })
  2993. },
  2994. UpdateMacheineTwo(formName) {
  2995. var device_type = this.form.devicetype
  2996. var device_types = parseInt(device_type)
  2997. this.form.devicetype = device_types
  2998. if (this.form.rubbish_reason === '') {
  2999. this.form.rubbish_reason = 0
  3000. }
  3001. var rubbish_reason = this.form.rubbish_reason
  3002. var rubbish_reasons = parseInt(rubbish_reason)
  3003. this.form.rubbish_reason = rubbish_reasons
  3004. var machine_status = this.form.machine_status
  3005. var machine_statuss = parseInt(machine_status)
  3006. this.form.machine_status = machine_statuss
  3007. this.$refs[formName].validate(valid => {
  3008. UpdateMacheineTwo(this.form).then(response => {
  3009. if (response.data.state === 1) {
  3010. var addmacher = response.data.data.addmacher
  3011. this.$message.success('修改成功')
  3012. for (let i = 0; i < this.tableDatatwo.length; i++) {
  3013. if (this.tableDatatwo[i].id == addmacher.id) {
  3014. for (let j = 0; j < this.deviceMode.length; j++) {
  3015. if (this.deviceMode[j].id === parseInt(addmacher.unit_type)) {
  3016. addmacher.device_mode = this.deviceMode[j].device_mode
  3017. // this.$forceUpdate()
  3018. }
  3019. }
  3020. this.tableDatatwo[i] = addmacher
  3021. // this.$refs.singleTable.setCurrentRow(this.tableDatatwo[i])
  3022. }
  3023. }
  3024. // this.getAllMachine()
  3025. this.getAllSubregion()
  3026. this.$refs.singleTable.setCurrentRow(addmacher)
  3027. this.$forceUpdate()
  3028. }
  3029. })
  3030. })
  3031. },
  3032. cleanMainchine() {
  3033. this.confirmShow = false
  3034. this.cancelShow = false
  3035. // this.form.manufacture_factory = ""
  3036. // this.form.service_manufacturer= ""
  3037. // this.form.use_section= ""
  3038. // this.form.buy_date= ""
  3039. // this.form.install_date= ""
  3040. // this.form.start_date= ""
  3041. // this.form.maintenance_engineer= ""
  3042. // this.form.telephone= ""
  3043. // this.form.guarantee_date= ""
  3044. // this.form.user_total= ""
  3045. // this.form.rubbish_date= ""
  3046. // this.form.user_year = ""
  3047. // this.form.work_time = ""
  3048. // this.form.treat_mode = ""
  3049. },
  3050. addPlan() {
  3051. this.$refs.planForm.open()
  3052. },
  3053. ToReminders() {
  3054. this.$refs.remanderform.open()
  3055. },
  3056. changeCheck() {
  3057. this.$refs.multipleTableOne.clearSelection()
  3058. if (this.checkAllStatusOne) {
  3059. this.$refs.multipleTableOne.toggleAllSelection()
  3060. }
  3061. },
  3062. handleSelectionChange(val) {
  3063. this.selectMachinesOne = val
  3064. },
  3065. changeCheckOne() {
  3066. this.$refs.multipleTable.clearSelection()
  3067. if (this.checkAllStatus) {
  3068. this.$refs.multipleTable.toggleAllSelection()
  3069. }
  3070. },
  3071. handleSelectionChangeOne(val) {
  3072. this.selectMachines = val
  3073. },
  3074. changeMachineStatus(val) {
  3075. if (val === 4) {
  3076. this.readisable = false
  3077. } else {
  3078. this.readisable = true
  3079. this.form.rubbish_date = ''
  3080. this.form.rubbish_reason = ''
  3081. }
  3082. },
  3083. getAllPlan() {
  3084. getAllPlan().then(response => {
  3085. if (response.data.state === 1) {
  3086. var plan = response.data.data.plan
  3087. for (let index = 0; index < plan.length; index++) {
  3088. if (plan[index].time === 1) {
  3089. plan[index].time = '周一'
  3090. }
  3091. if (plan[index].time === 2) {
  3092. plan[index].time = '周二'
  3093. }
  3094. if (plan[index].time === 3) {
  3095. plan[index].time = '周三'
  3096. }
  3097. if (plan[index].time === 4) {
  3098. plan[index].time = '周四'
  3099. }
  3100. if (plan[index].time === 5) {
  3101. plan[index].time = '周五'
  3102. }
  3103. if (plan[index].time === 6) {
  3104. plan[index].time = '周六'
  3105. }
  3106. if (plan[index].time === 7) {
  3107. plan[index].time = '周日'
  3108. }
  3109. if (plan[index].classtime === 1) {
  3110. plan[index].classtime = '上午'
  3111. }
  3112. if (plan[index].classtime === 2) {
  3113. plan[index].classtime = '下午'
  3114. }
  3115. if (plan[index].classtime === 3) {
  3116. plan[index].classtime = '晚上'
  3117. }
  3118. if (plan[index].way === 0) {
  3119. plan[index].way = '/'
  3120. }
  3121. if (plan[index].way === 1) {
  3122. plan[index].way = '擦拭'
  3123. }
  3124. if (plan[index].way === 2) {
  3125. plan[index].way = '化学消毒'
  3126. }
  3127. if (plan[index].machine_disinfectant === 0) {
  3128. plan[index].machine_disinfectant = '/'
  3129. }
  3130. if (plan[index].machine_disinfectant === 1) {
  3131. plan[index].machine_disinfectant = '0.22%季铵盐'
  3132. }
  3133. if (plan[index].machine_disinfectant === 2) {
  3134. plan[index].machine_disinfectant = '500mg/l含氯消毒剂'
  3135. }
  3136. if (plan[index].machine_disinfectantant === 3) {
  3137. plan[index].machine_disinfectant = '1000mg/l含氯消毒剂'
  3138. }
  3139. if (plan[index].machine_disinfectant === 4) {
  3140. plan[index].machine_disinfectant = '1500mg/l含氯消毒剂'
  3141. }
  3142. if (plan[index].disinfectan_way === 0) {
  3143. plan[index].disinfectan_way = '/'
  3144. }
  3145. if (plan[index].disinfectan_way === 1) {
  3146. plan[index].disinfectan_way = '热化学消毒'
  3147. }
  3148. if (plan[index].disinfectan_way === 2) {
  3149. plan[index].disinfectan_way = '化学消毒 + 除钙'
  3150. }
  3151. if (plan[index].disinfectan_way === 3) {
  3152. plan[index].disinfectan_way = '热化学消毒 + 除钙'
  3153. }
  3154. if (plan[index].disinfectan_way === 4) {
  3155. plan[index].disinfectan_way = '热消毒'
  3156. }
  3157. if (plan[index].disinfectan_way === 5) {
  3158. plan[index].disinfectan_way = '化学消毒'
  3159. }
  3160. if (plan[index].disinfectan_way === 6) {
  3161. plan[index].disinfectan_way = '除钙'
  3162. }
  3163. if (plan[index].disinfectan_way === 7) {
  3164. plan[index].disinfectan_way = '清洗'
  3165. }
  3166. if (plan[index].disinfectant === 0) {
  3167. plan[index].disinfectant = '/'
  3168. }
  3169. if (plan[index].disinfectant === 1) {
  3170. plan[index].disinfectant = '20%柠檬酸'
  3171. }
  3172. if (plan[index].disinfectant === 2) {
  3173. plan[index].disinfectant = '25%柠檬酸'
  3174. }
  3175. if (plan[index].disinfectant === 3) {
  3176. plan[index].disinfectant = '50%柠檬酸'
  3177. }
  3178. if (plan[index].disinfectant === 4) {
  3179. plan[index].disinfectant = '50%柠檬酸 + 5%次氯酸钠'
  3180. }
  3181. if (plan[index].disinfectant === 5) {
  3182. plan[index].disinfectant = '20%柠檬酸 + 10%冰醋酸'
  3183. }
  3184. if (plan[index].disinfectant === 6) {
  3185. plan[index].disinfectant = '0.2%过氧化乙酸'
  3186. }
  3187. if (plan[index].disinfectant === 7) {
  3188. plan[index].disinfectant = '10%冰醋酸'
  3189. }
  3190. if (plan[index].disinfectant === 8) {
  3191. plan[index].disinfectant = '50%冰醋酸'
  3192. }
  3193. if (plan[index].disinfectant === 9) {
  3194. plan[index].disinfectant = '5%次氯酸钠'
  3195. }
  3196. }
  3197. this.tableData = plan
  3198. }
  3199. })
  3200. },
  3201. getAllPlanDetail(unit_type) {
  3202. getAllPlanDetail(unit_type).then(response => {
  3203. if (response.data.state === 1) {
  3204. var plandetail = response.data.data.plandetail
  3205. // console.log('plandetail', plandetail)
  3206. for (let index = 0; index < plandetail.length; index++) {
  3207. if (plandetail[index].time === 1) {
  3208. plandetail[index].time = '周一'
  3209. }
  3210. if (plandetail[index].time === 2) {
  3211. plandetail[index].time = '周二'
  3212. }
  3213. if (plandetail[index].time === 3) {
  3214. plandetail[index].time = '周三'
  3215. }
  3216. if (plandetail[index].time === 4) {
  3217. plandetail[index].time = '周四'
  3218. }
  3219. if (plandetail[index].time === 5) {
  3220. plandetail[index].time = '周五'
  3221. }
  3222. if (plandetail[index].time === 6) {
  3223. plandetail[index].time = '周六'
  3224. }
  3225. if (plandetail[index].time === 7) {
  3226. plandetail[index].time = '周日'
  3227. }
  3228. if (plandetail[index].classtime === 1) {
  3229. plandetail[index].classtime = '上午'
  3230. }
  3231. if (plandetail[index].classtime === 2) {
  3232. plandetail[index].classtime = '下午'
  3233. }
  3234. if (plandetail[index].classtime === 3) {
  3235. plandetail[index].classtime = '晚上'
  3236. }
  3237. if (plandetail[index].way === 0) {
  3238. plandetail[index].way = '/'
  3239. }
  3240. if (plandetail[index].way === 1) {
  3241. plandetail[index].way = '擦拭'
  3242. }
  3243. if (plandetail[index].way === 2) {
  3244. plandetail[index].way = '化学消毒'
  3245. }
  3246. if (plandetail[index].machine_disinfectant === 0) {
  3247. plandetail[index].machine_disinfectant = '/'
  3248. }
  3249. if (plandetail[index].machine_disinfectant === 1) {
  3250. plandetail[index].machine_disinfectant = '0.22%季铵盐'
  3251. }
  3252. if (plandetail[index].machine_disinfectant === 2) {
  3253. plandetail[index].machine_disinfectant = '500mg/l含氯消毒剂'
  3254. }
  3255. if (plandetail[index].machine_disinfectantant === 3) {
  3256. plandetail[index].machine_disinfectant = '1000mg/l含氯消毒剂'
  3257. }
  3258. if (plandetail[index].machine_disinfectant === 4) {
  3259. plandetail[index].machine_disinfectant = '1500mg/l含氯消毒剂'
  3260. }
  3261. if (plandetail[index].disinfectan_way === 0) {
  3262. plandetail[index].disinfectan_way = '/'
  3263. }
  3264. if (plandetail[index].disinfectan_way === 1) {
  3265. plandetail[index].disinfectan_way = '热化学消毒'
  3266. }
  3267. if (plandetail[index].disinfectan_way === 2) {
  3268. plandetail[index].disinfectan_way = '化学消毒 + 除钙'
  3269. }
  3270. if (plandetail[index].disinfectan_way === 3) {
  3271. plandetail[index].disinfectan_way = '热化学消毒 + 除钙'
  3272. }
  3273. if (plandetail[index].disinfectan_way === 4) {
  3274. plandetail[index].disinfectan_way = '热消毒'
  3275. }
  3276. if (plandetail[index].disinfectan_way === 5) {
  3277. plandetail[index].disinfectan_way = '化学消毒'
  3278. }
  3279. if (plandetail[index].disinfectan_way === 6) {
  3280. plandetail[index].disinfectan_way = '除钙'
  3281. }
  3282. if (plandetail[index].disinfectan_way === 7) {
  3283. plandetail[index].disinfectan_way = '清洗'
  3284. }
  3285. if (plandetail[index].disinfectant === 0) {
  3286. plandetail[index].disinfectant = '/'
  3287. }
  3288. if (plandetail[index].disinfectant === 1) {
  3289. plandetail[index].disinfectant = '20%柠檬酸'
  3290. }
  3291. if (plandetail[index].disinfectant === 2) {
  3292. plandetail[index].disinfectant = '25%柠檬酸'
  3293. }
  3294. if (plandetail[index].disinfectant === 3) {
  3295. plandetail[index].disinfectant = '50%柠檬酸'
  3296. }
  3297. if (plandetail[index].disinfectant === 4) {
  3298. plandetail[index].disinfectant = '50%柠檬酸 + 5%次氯酸钠'
  3299. }
  3300. if (plandetail[index].disinfectant === 5) {
  3301. plandetail[index].disinfectant = '20%柠檬酸 + 10%冰醋酸'
  3302. }
  3303. if (plandetail[index].disinfectant === 6) {
  3304. plandetail[index].disinfectant = '0.2%过氧化乙酸'
  3305. }
  3306. if (plandetail[index].disinfectant === 7) {
  3307. plandetail[index].disinfectant = '10%冰醋酸'
  3308. }
  3309. if (plandetail[index].disinfectant === 8) {
  3310. plandetail[index].disinfectant = '50%冰醋酸'
  3311. }
  3312. if (plandetail[index].disinfectant === 9) {
  3313. plandetail[index].disinfectant = '5%次氯酸钠'
  3314. }
  3315. }
  3316. this.planData = plandetail
  3317. }
  3318. })
  3319. },
  3320. EditMachine(id, index) {
  3321. this.dialogVisible = true
  3322. EditPlanDetail(id).then(response => {
  3323. if (response.data.state === 1) {
  3324. var plan = response.data.data.plan
  3325. this.machineform.id = plan.id
  3326. this.machineform.device_type = plan.device_type
  3327. this.machineform.disinfec_time = plan.disinfec_time
  3328. this.machineform.time = plan.time
  3329. this.machineform.class_time = plan.classtime
  3330. this.machineform.way = plan.way
  3331. this.machineform.machine_disinfectant = plan.machine_disinfectant
  3332. this.machineform.disinfectant_way = plan.disinfectan_way
  3333. this.machineform.disinfectant = plan.disinfectant
  3334. // this.getPatientDetail(this.unitType, this.$route.query.bedid)
  3335. }
  3336. })
  3337. },
  3338. UpdatePlanInfo(formName) {
  3339. var devicetype = this.machineform.device_type
  3340. var devicetypes = parseInt(devicetype)
  3341. this.machineform.device_type = devicetypes
  3342. if (this.machineform.disinfec_time === '') {
  3343. this.machineform.disinfec_time = ''
  3344. }
  3345. if (this.machineform.disinfec_time !== '') {
  3346. var disinfectimes = this.machineform.disinfec_time
  3347. var disinfectime = parseInt(disinfectimes)
  3348. this.machineform.disinfec_time = disinfectime
  3349. }
  3350. var times = this.machineform.time
  3351. var time = parseInt(times)
  3352. this.machineform.time = time
  3353. var classtimes = this.machineform.class_time
  3354. var classtime = parseInt(classtimes)
  3355. this.machineform.class_time = classtime
  3356. var ways = this.machineform.way
  3357. var way = parseInt(ways)
  3358. this.machineform.way = way
  3359. var machinedisinfectant = this.machineform.machine_disinfectant
  3360. var machinedisinfectants = parseInt(machinedisinfectant)
  3361. this.machineform.machine_disinfectant = machinedisinfectants
  3362. var disinfectantways = this.machineform.disinfectant_way
  3363. var disinfectantway = parseInt(disinfectantways)
  3364. this.machineform.disinfectant_way = disinfectantway
  3365. var disinfectants = this.machineform.disinfectant
  3366. var disinfectant = parseInt(disinfectants)
  3367. this.machineform.disinfectant = disinfectant
  3368. UpdatePlanInfo(this.machineform).then(response => {
  3369. if (response.data.state === 1) {
  3370. var plan = response.data.data.plan
  3371. this.dialogVisible = false
  3372. this.$message.success('修改成功')
  3373. this.getAllPlanDetail(this.unitType)
  3374. this.getAllPlan()
  3375. }
  3376. })
  3377. },
  3378. openDeleteMahcine() {
  3379. if (this.selectMachines.length == 0) {
  3380. this.$message.error('请选择要删除的信息')
  3381. return false
  3382. }
  3383. this.$confirm(
  3384. '确认要删除所选记录吗? <br>删除后,信息将无法恢复',
  3385. '删除提示',
  3386. {
  3387. dangerouslyUseHTMLString: true,
  3388. confirmButtonText: '确定',
  3389. cancelButtonText: '取消',
  3390. type: 'warning'
  3391. }
  3392. )
  3393. .then(() => {
  3394. var ids = []
  3395. var idMap = {}
  3396. for (const index in this.selectMachines) {
  3397. ids.push(this.selectMachines[index].id)
  3398. idMap[this.selectMachines[index].id] = this.selectMachines[
  3399. index
  3400. ].id
  3401. }
  3402. DeletePlans({ ids: ids }).then(response => {
  3403. // eslint-disable-next-line eqeqeq
  3404. if (response.data.state == 1) {
  3405. // eslint-disable-next-line no-unused-vars
  3406. var msg = response.data.data.msg
  3407. var planDataLength = this.planData.length
  3408. for (let index = planDataLength - 1; index >= 0; index--) {
  3409. if (this.planData[index].id in idMap) {
  3410. this.planData.splice(index, 1)
  3411. }
  3412. }
  3413. var planDataLengths = this.tableData.length
  3414. for (let index = planDataLengths - 1; index >= 0; index--) {
  3415. if (this.tableData[index].id in idMap) {
  3416. this.tableData.splice(index, 1)
  3417. }
  3418. }
  3419. this.$message.success('删除消毒计划成功')
  3420. } else {
  3421. this.$message.error('删除消毒计划失败')
  3422. }
  3423. })
  3424. .catch(e => {})
  3425. })
  3426. .catch(() => {
  3427. return false
  3428. })
  3429. },
  3430. openDelete(id, index) {
  3431. // eslint-disable-next-line no-undef
  3432. this.$confirm(
  3433. '确认要删除所选记录吗? <br>删除后,信息将无法恢复',
  3434. '删除提示',
  3435. {
  3436. dangerouslyUseHTMLString: true,
  3437. confirmButtonText: '确定',
  3438. cancelButtonText: '取消',
  3439. type: 'warning'
  3440. }
  3441. ).then(() => {
  3442. openDelete(id, index).then(response => {
  3443. if (response.data.state === 1) {
  3444. var msg = response.data.data.msg
  3445. this.tableData.splice(index, 1)
  3446. this.planData.splice(index, 1)
  3447. }
  3448. })
  3449. })
  3450. },
  3451. openDeleteMahcineOne() {
  3452. if (this.selectMachinesOne.length == 0) {
  3453. this.$message.error('请选择要删除的信息')
  3454. return false
  3455. }
  3456. this.$confirm(
  3457. '确认要删除所选记录吗? <br>删除后,信息将无法恢复',
  3458. '删除提示',
  3459. {
  3460. dangerouslyUseHTMLString: true,
  3461. confirmButtonText: '确定',
  3462. cancelButtonText: '取消',
  3463. type: 'warning'
  3464. }
  3465. )
  3466. .then(() => {
  3467. var ids = []
  3468. var idMap = {}
  3469. for (const index in this.selectMachinesOne) {
  3470. ids.push(this.selectMachinesOne[index].id)
  3471. idMap[this.selectMachinesOne[index].id] = this.selectMachinesOne[
  3472. index
  3473. ].id
  3474. }
  3475. DeletePlans({ ids: ids })
  3476. .then(response => {
  3477. if (response.data.state == 1) {
  3478. var msg = response.data.data.msg
  3479. var planDataLength = this.tableData.length
  3480. for (let index = planDataLength - 1; index >= 0; index--) {
  3481. if (this.tableData[index].id in idMap) {
  3482. this.tableData.splice(index, 1)
  3483. }
  3484. }
  3485. var planDataLengths = this.planData.length
  3486. for (let index = planDataLengths - 1; index >= 0; index--) {
  3487. if (this.planData[index].id in idMap) {
  3488. this.planData.splice(index, 1)
  3489. }
  3490. }
  3491. this.$message.success('删除消毒计划成功')
  3492. } else {
  3493. this.$message.error('删除消毒计划失败')
  3494. }
  3495. })
  3496. .catch(e => {})
  3497. })
  3498. .catch(() => {
  3499. return false
  3500. })
  3501. },
  3502. getAllEquimentName() {
  3503. getAllEquimentName().then(response => {
  3504. if (response.data.state === 1) {
  3505. var equit = response.data.data.equit
  3506. // this.DeviceType = equit
  3507. }
  3508. })
  3509. },
  3510. clickQuery() {
  3511. this.$refs.multipleform.open()
  3512. },
  3513. getPatientInfo(bedid) {
  3514. getPatientInfo(bedid).then(response => {
  3515. if (response.data.state === 1) {
  3516. var schedules = response.data.data.schedules
  3517. // this.patientName = schedules
  3518. }
  3519. })
  3520. },
  3521. ChangeClass(id) {
  3522. ChangeClass(this.equimentid, id).then(response => {
  3523. if (response.data.state === 1) {
  3524. var patients = response.data.data.patients
  3525. if (patients.is_infectious === 0) {
  3526. this.userform.contagion = ''
  3527. }
  3528. if (patients.is_infectious === 1) {
  3529. this.userform.contagion = '无'
  3530. }
  3531. if (patients.is_infectious === 2) {
  3532. this.userform.contagion = '有'
  3533. }
  3534. this.userform.date = uParseTime(patients.schedule_date, '{y}-{m}-{d}')
  3535. this.userform.patient_name = patients.name
  3536. this.userform.patient_id = patients.patient_id
  3537. // this.userform.patient_name = patients.name
  3538. var zone = response.data.data.zone
  3539. // console.log('zone==========', zone)
  3540. this.userform.zone = zone.id
  3541. var number = response.data.data.number
  3542. // console.log('nubmer', number)
  3543. this.userform.bed_number = number.id
  3544. // this.userform.bed_number = number.number
  3545. var order = response.data.data.order
  3546. this.userform.start_time = uParseTime(order.start_time, '{y}-{m}-{d} {h}:{i}')
  3547. this.userform.end_time = uParseTime(order.end_time, '{y}-{m}-{d} {h}:{i}')
  3548. var prescription = response.data.data.prescription
  3549. this.userform.dialysis_mode = prescription.mode_id
  3550. var dislysis = response.data.data.dislysis
  3551. this.userform.dialysis_time = dislysis.actual_treatment_hour + 'h' + dislysis.actual_treatment_minute + 'min'
  3552. this.userform.hyperfiltratio = dislysis.actual_ultrafiltration
  3553. this.userform.weight_loss = dislysis.weight_loss
  3554. }
  3555. })
  3556. },
  3557. updateTimes(time) {
  3558. if (time < 0) {
  3559. return ''
  3560. } else {
  3561. return uParseTime(time, '{y}-{m}-{d} {h}:{i}')
  3562. }
  3563. },
  3564. getTimes(time) {
  3565. return uParseTime(time, '{y}-{m}-{d} {h}:{i}')
  3566. },
  3567. getTime(time) {
  3568. return uParseTime(time, '{y}-{m}-{d}')
  3569. },
  3570. SaveInformation(formName) {
  3571. if (this.userform.classtype === '') {
  3572. this.userform.classtype = 0
  3573. }
  3574. var classtypes = this.userform.classtype
  3575. var classtype = parseInt(classtypes)
  3576. this.userform.classtype = classtype
  3577. var zone = this.userform.zone
  3578. var zones = parseInt(zone)
  3579. this.userform.zone = zones
  3580. var bednumber = this.userform.bed_number
  3581. var bednumbers = parseInt(bednumber)
  3582. this.userform.bed_number = bednumbers
  3583. // var patientName = this.userform.patient_name
  3584. // var patient_name = parseInt(patientName)
  3585. // this.userform.patient_name = patient_name
  3586. var dialysismode = this.userform.dialysis_mode
  3587. var dialysis_mode = parseInt(dialysismode)
  3588. this.userform.dialysis_mode = dialysis_mode
  3589. if (this.userform.failure_stage === '') {
  3590. this.userform.failure_stage = 0
  3591. }
  3592. if (this.userform.dialysis_checked === '') {
  3593. this.userform.dialysis_checked = 0
  3594. }
  3595. if (this.userform.dialysis_checked === true) {
  3596. this.userform.dialysis_checked = 1
  3597. }
  3598. if (this.userform.dialysis_checked === false) {
  3599. this.userform.dialysis_checked = 2
  3600. }
  3601. if (this.userform.germ_checked === '') {
  3602. this.userform.germ_checked = 0
  3603. }
  3604. if (this.userform.germ_checked === true) {
  3605. this.userform.germ_checked = 1
  3606. }
  3607. if (this.userform.germ_checked === false) {
  3608. this.userform.germ_checked = 2
  3609. }
  3610. if (this.userform.dialysis_name === '') {
  3611. this.userform.dialysis_name = 0
  3612. }
  3613. var dialysis_name = this.userform.dialysis_name
  3614. var dialysis = parseInt(dialysis_name)
  3615. this.userform.dialysis_name = dialysis
  3616. if (this.userform.germ_name === '') {
  3617. this.userform.germ_name = 0
  3618. }
  3619. var germname = this.userform.germ_name
  3620. var germames = parseInt(germname)
  3621. this.userform.germ_name = germames
  3622. if (this.userform.clean === '') {
  3623. this.userform.clean = 0
  3624. }
  3625. if (this.userform.clean === true) {
  3626. this.userform.clean = 1
  3627. }
  3628. if (this.userform.clean === false) {
  3629. this.userform.clean = 2
  3630. }
  3631. // eslint-disable-next-line eqeqeq
  3632. if (this.userform.start_time == '') {
  3633. this.userform.start_time = '0'
  3634. }
  3635. // eslint-disable-next-line eqeqeq
  3636. if (this.userform.end_time == '') {
  3637. this.userform.end_time = '0'
  3638. }
  3639. // eslint-disable-next-line eqeqeq
  3640. if (this.userform.starttime == '') {
  3641. this.userform.starttime = '0'
  3642. }
  3643. // eslint-disable-next-line eqeqeq
  3644. if (this.userform.endtime == '') {
  3645. this.userform.endtime = '0'
  3646. }
  3647. if (this.userform.hyperfiltratio === '') {
  3648. this.userform.hyperfiltratio = 0
  3649. }
  3650. var hyperfiltratio = this.userform.hyperfiltratio
  3651. var hyperfiltratios = parseInt(hyperfiltratio)
  3652. this.userform.hyperfiltratio = hyperfiltratios
  3653. if (this.userform.weight_loss === '') {
  3654. this.userform.weight_loss = 0
  3655. }
  3656. var weightloss = this.userform.weight_loss
  3657. var weidht = parseInt(weightloss)
  3658. this.userform.weight_loss = weidht
  3659. if (this.userform.user_total === '0') {
  3660. this.userform.user_total = 0
  3661. }
  3662. // console.log('上机时间', this.userform.start_time)
  3663. // console.log('下机时间', this.userform.end_time)
  3664. this.$refs[formName].validate((valid) => {
  3665. if (valid) {
  3666. SaveInformation(this.equimentid, this.userform).then(response => {
  3667. if (response.data.state === 1) {
  3668. // eslint-disable-next-line no-unused-vars
  3669. var information = response.data.data.information
  3670. var infor = response.data.data.infor
  3671. this.userform.start_time = ''
  3672. this.userform.end_time = ''
  3673. this.userform.starttime = ''
  3674. this.userform.endtime = ''
  3675. this.userform.date = ''
  3676. this.userform.classtype = ''
  3677. this.userform.zone = ''
  3678. this.userform.patient_name = ''
  3679. this.userform.sign_name = ''
  3680. this.userform.bed_number = ''
  3681. this.userform.hyperfiltratio = ''
  3682. this.userform.weight_loss = ''
  3683. this.userform.dialysis_time = ''
  3684. this.$message.success('添加成功')
  3685. // this.$refs.child.getInformationData()
  3686. }
  3687. })
  3688. }
  3689. })
  3690. },
  3691. toLink() {
  3692. window.location.href = this.guaForm.images
  3693. },
  3694. // changStartTime(val) {
  3695. // this.userform.starttime = val
  3696. // },
  3697. // changeEndTime(val) {
  3698. // this.userform.endtime = val
  3699. // console.log('val', val)
  3700. // console.log('开始时间', this.userform.starttime)
  3701. // console.log('呵呵', this.formatDuring(val))
  3702. // },
  3703. // formatDuring(mss) {
  3704. // const days = parseInt(mss / (1000 * 60 * 60 * 24)) // 得到天数
  3705. // const hours = parseInt((mss % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60)) // 得到小时
  3706. // const minutes = parseInt((mss % (1000 * 60 * 60)) / (1000 * 60)) // 得到分钟数
  3707. // const seconds = (mss % (1000 * 60)) / 1000 // 得到秒数
  3708. // const str1 = hours < 10 ? ('0' + hours) : hours
  3709. // console.log('str1', str1)
  3710. // const str2 = minutes < 10 ? ('0' + minutes) : minutes
  3711. // return str1 + ':' + str2
  3712. // },
  3713. // 获取签名
  3714. getAllOrganization() {
  3715. getAllOrganization().then(response => {
  3716. if (response.data.state === 1) {
  3717. var approle = response.data.data.approle
  3718. // console.log('approle签名',approle)
  3719. this.autograph = approle
  3720. this.sampling = approle
  3721. }
  3722. })
  3723. },
  3724. getUserRegister(id) {
  3725. getUserRegister(id).then(response => {
  3726. if (response.data.state === 1) {
  3727. var information = response.data.data.information
  3728. console.log('产讯使用登记', information)
  3729. // eslint-disable-next-line no-unused-vars
  3730. var role = response.data.data.role
  3731. // console.log('role', role)
  3732. // eslint-disable-next-line eqeqeq
  3733. var dislysis = response.data.data.dislysis
  3734. this.userform.id = information.id
  3735. if (information.date === 0) {
  3736. this.userform.date = moment(new Date()).format('YYYY-MM-DD')
  3737. } else {
  3738. this.userform.date = uParseTime(information.date, '{y}-{m}-{d}')
  3739. }
  3740. this.userform.classtype = information.class
  3741. this.userform.zone = information.zone
  3742. this.userform.bed_number = information.bed_number
  3743. this.userform.patient_name = information.name
  3744. this.userform.patient_id = information.patient_id
  3745. this.userform.contagion = information.contagion
  3746. this.userform.dialysis_mode = information.dialysis_mode
  3747. this.userform.start_time = this.updateTimes(information.start_time)
  3748. // this.userform.start_time = uParseTime(information.start_time, '{y}-{m}-{d} {h}:{i}')
  3749. this.userform.end_time = this.updateTimes(information.end_time)
  3750. // this.userform.end_time = uParseTime(information.end_time, '{y}-{m}-{d} {h}:{i}')
  3751. // this.userform.dialysis_time = information.dialysis_hour
  3752. // this.userform.hyperfiltratio = information.hyperfiltratio
  3753. // this.userform.weight_loss = information.weight_loss
  3754. if (information.hyperfiltratio === '') {
  3755. this.userform.hyperfiltratio = dislysis.actual_ultrafiltration
  3756. } else {
  3757. this.userform.hyperfiltratio = information.hyperfiltratio
  3758. }
  3759. if (information.dialysis_hour === '') {
  3760. this.userform.dialysis_time = dislysis.actual_treatment_hour + 'h' + dislysis.actual_treatment_minute + 'min'
  3761. } else {
  3762. this.userform.dialysis_time = information.dialysis_hour
  3763. }
  3764. // this.userform.dialysis_time = dislysis.actual_treatment_hour + 'h' + dislysis.actual_treatment_minute + 'min'
  3765. // this.userform.hyperfiltratio = dislysis.actual_ultrafiltration
  3766. if (information.weight_loss === '') {
  3767. this.userform.weight_loss = dislysis.weight_loss
  3768. } else {
  3769. this.userform.weight_loss = information.weight_loss
  3770. }
  3771. // this.userform.weight_loss = dislysis.weight_loss
  3772. this.userform.warning_value = information.warning_value
  3773. this.userform.user_total = information.user_total
  3774. if (information.move === 0) {
  3775. this.userform.run = 1
  3776. } else {
  3777. this.userform.run = information.move
  3778. }
  3779. this.userform.failure_stage = information.failure_stage
  3780. this.userform.fault_description = information.fault_description
  3781. this.userform.code_information = information.code_information
  3782. this.userform.disinfect_type = information.disinfect_type
  3783. this.userform.disinfection = information.disinfection
  3784. this.userform.machine_run = information.machine_run
  3785. this.userform.fluid_path = information.fluid_path
  3786. this.userform.disinfectant = information.disinfectant
  3787. this.userform.disinfection_status = information.disinfection_status
  3788. this.userform.disinfection_residue = information.disinfection_residue
  3789. this.userform.longtime = information.long_time
  3790. this.userform.starttime = this.updateTimes(information.disinfec_startime)
  3791. this.userform.endtime = this.updateTimes(information.disinfec_endtime)
  3792. // this.userform.starttime = uParseTime(information.disinfec_startime, '{y}-{m}-{d} {h}:{i}')
  3793. // this.userform.endtime = uParseTime(information.disinfec_endtime, '{y}-{m}-{d} {h}:{i}')
  3794. if (information.dialysis_checked === 1) {
  3795. this.userform.dialysis_checked = true
  3796. }
  3797. if (information.dialysis_checked === 0) {
  3798. this.userform.dialysis_checked = false
  3799. }
  3800. if (information.dialysis_checked === 2) {
  3801. this.userform.dialysis_checked = false
  3802. }
  3803. this.userform.dialysis_name = information.dialysis_name
  3804. this.userform.norms = information.norms
  3805. this.userform.dialysis_concentration = information.dialysis_concentration
  3806. if (information.germ_checked === 0) {
  3807. this.userform.germ_checked = false
  3808. }
  3809. if (information.germ_checked === 2) {
  3810. this.userform.germ_checked = false
  3811. }
  3812. if (information.germ_checked === 1) {
  3813. this.userform.germ_checked = true
  3814. }
  3815. this.userform.germ_name = information.germ_name
  3816. this.userform.germ_number = information.germ_number
  3817. if (information.clean === 1) {
  3818. this.userform.clean = true
  3819. }
  3820. if (information.clean === 0) {
  3821. this.userform.clean = false
  3822. }
  3823. if (information.clean === 2) {
  3824. this.userform.clean = false
  3825. }
  3826. // eslint-disable-next-line eqeqeq
  3827. if (information.admin_user_id == 0) {
  3828. this.userform.sign_name = ''
  3829. } else {
  3830. this.userform.sign_name = information.admin_user_id
  3831. }
  3832. this.$forceUpdate()
  3833. }
  3834. })
  3835. },
  3836. getOrgName() {
  3837. getOrgName().then(response => {
  3838. if (response.data.state === 1) {
  3839. var org = response.data.data.org
  3840. this.qualityForm.detection_unit = org.org_name
  3841. this.qualityFormTwo.detection_unit = org.org_name
  3842. this.qualityFormThree.detection_unit = org.org_name
  3843. }
  3844. })
  3845. },
  3846. SaveBacteria(formName) {
  3847. if (this.qualityForm.specimen === '') {
  3848. this.qualityForm.specimen = 0
  3849. }
  3850. var specimen = this.qualityForm.specimen
  3851. var specimens = parseInt(specimen)
  3852. this.qualityForm.specimen = specimens
  3853. if (this.qualityForm.sampling_locationa === '') {
  3854. this.qualityForm.sampling_locationa = 0
  3855. }
  3856. var samplinglocationa = this.qualityForm.sampling_locationa
  3857. var samplinglocationas = parseInt(samplinglocationa)
  3858. this.qualityForm.sampling_locationa = samplinglocationas
  3859. this.$refs[formName].validate(response => {
  3860. SaveBacteria(this.equimentid, this.qualityForm).then(response => {
  3861. if (response.data.state === 1) {
  3862. var culture = response.data.data.culture
  3863. this.$message.success('保存成功')
  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. this.$refs.child.getAllQulityInfo()
  3872. }
  3873. })
  3874. })
  3875. },
  3876. cleanSaveBacteria() {
  3877. this.qualityForm.specimen = '',
  3878. this.qualityForm.concentrate_noa = '',
  3879. this.qualityForm.concentrate_nob = '',
  3880. this.qualityForm.sampling_locationa = '',
  3881. this.qualityForm.sampler = ''
  3882. this.qualityForm.reporting_date = ''
  3883. this.qualityForm.detection_result = ''
  3884. },
  3885. SaveLincomycin(formName) {
  3886. this.$refs[formName].validate((valid) => {
  3887. if (this.qualityFormTwo.specimenb === '') {
  3888. this.qualityFormTwo.specimenb = 0
  3889. }
  3890. var specimen = this.qualityFormTwo.specimenb
  3891. var specimenb = parseInt(specimen)
  3892. this.qualityFormTwo.specimenb = specimenb
  3893. if (this.qualityFormTwo.sampling_locationb === '') {
  3894. this.qualityFormTwo.sampling_locationb = 0
  3895. }
  3896. var sampling = this.qualityFormTwo.sampling_locationb
  3897. var samplings = parseInt(sampling)
  3898. this.qualityFormTwo.sampling_locationb = samplings
  3899. if (valid) {
  3900. SaveLincomycin(this.equimentid, this.qualityFormTwo).then(response => {
  3901. if (response.data.state === 1) {
  3902. var dialysate = response.data.data.dialysate
  3903. this.$message.success('保存成功')
  3904. this.qualityFormTwo.specimenb = ''
  3905. this.qualityFormTwo.concentrate_noc = ''
  3906. this.qualityFormTwo.concentrateb_nod = ''
  3907. this.qualityFormTwo.sampling_locationb = ''
  3908. this.qualityFormTwo.samplerb = ''
  3909. this.qualityFormTwo.reporting_dateb = ''
  3910. this.qualityFormTwo.detection_resultb = ''
  3911. this.$refs.child.getAllQulityInfo()
  3912. }
  3913. })
  3914. }
  3915. })
  3916. },
  3917. cleanLincomycin() {
  3918. this.qualityFormTwo.specimenb = ''
  3919. this.qualityFormTwo.concentrate_noc = ''
  3920. this.qualityFormTwo.concentrateb_nod = ''
  3921. this.qualityFormTwo.sampling_locationb = ''
  3922. this.qualityFormTwo.samplerb = ''
  3923. this.qualityFormTwo.reporting_dateb = ''
  3924. this.qualityFormTwo.detection_resultb = ''
  3925. },
  3926. SaveQualityControl(formName) {
  3927. this.$refs[formName].validate((valid) => {
  3928. if (valid) {
  3929. SaveQualityControl(this.equimentid, this.qualityFormThree).then(response => {
  3930. if (response.data.state === 1) {
  3931. var ion = response.data.data.ion
  3932. // console.log('ion', ion)
  3933. this.$message.success('保存成功')
  3934. this.$refs.child.getAllQulityInfo()
  3935. this.qualityFormThree.samplerc = ''
  3936. this.qualityFormThree.concentrate_nof = ''
  3937. this.qualityFormThree.concentrate_nog = ''
  3938. this.qualityFormThree.date_reportc = ''
  3939. this.qualityFormThree.actual_na = ''
  3940. this.qualityFormThree.actual_pna = ''
  3941. this.qualityFormThree.actual_k = ''
  3942. this.qualityFormThree.actual_ca = ''
  3943. this.qualityFormThree.actual_ci = ''
  3944. this.qualityFormThree.actual_hco = ''
  3945. this.qualityFormThree.actual_mg = ''
  3946. this.qualityFormThree.actual_ph = ''
  3947. this.qualityFormThree.remakes = ''
  3948. }
  3949. })
  3950. }
  3951. })
  3952. },
  3953. cleanQuality() {
  3954. this.qualityFormThree.samplerc = ''
  3955. this.qualityFormThree.concentrate_nof = ''
  3956. this.qualityFormThree.concentrate_nog = ''
  3957. this.qualityFormThree.date_reportc = ''
  3958. this.qualityFormThree.actual_na = ''
  3959. this.qualityFormThree.actual_pna = ''
  3960. this.qualityFormThree.actual_k = ''
  3961. this.qualityFormThree.actual_ca = ''
  3962. this.qualityFormThree.actual_ci = ''
  3963. this.qualityFormThree.actual_hco = ''
  3964. this.qualityFormThree.actual_mg = ''
  3965. this.qualityFormThree.actual_ph = ''
  3966. this.qualityFormThree.remakes = ''
  3967. },
  3968. changeSpecimen(val) {
  3969. if (val === 0) {
  3970. this.disable = false
  3971. this.diableTwo = false
  3972. }
  3973. if (val === 1) {
  3974. this.disable = false
  3975. this.diableTwo = false
  3976. }
  3977. if (val === 2) {
  3978. this.qualityForm.concentrate_nob = ''
  3979. this.qualityFormTwo.concentrateb_nod = ''
  3980. this.diableTwo = true
  3981. this.disable = false
  3982. }
  3983. if (val === 3) {
  3984. this.qualityForm.concentrate_noa = ''
  3985. this.qualityFormTwo.concentrate_noc = ''
  3986. this.disable = true
  3987. this.diableTwo = false
  3988. }
  3989. if (val === 4) {
  3990. this.disable = false
  3991. this.diableTwo = false
  3992. }
  3993. if (val === 5) {
  3994. this.disable = false
  3995. this.diableTwo = false
  3996. }
  3997. },
  3998. beforeUploadFile(file) {
  3999. var testmsg = file.name.substring(file.name.lastIndexOf('.') + 1)
  4000. const extension = testmsg === 'jpg' || testmsg === 'JPG' || testmsg === 'png' || testmsg === 'PNG' || testmsg === 'gif' || testmsg === 'GIF'
  4001. if (!extension) {
  4002. // eslint-disable-next-line no-mixed-spaces-and-tabs
  4003. this.$message({
  4004. // eslint-disable-next-line no-mixed-spaces-and-tabs
  4005. message: '上传文件只能是jpg或者png或者gif格式!',
  4006. type: 'error'
  4007. })
  4008. return false// 必须加上return false; 才能阻止
  4009. }
  4010. this.filename = file.name
  4011. this.classShow = true
  4012. this.guaForm.imageName = file.name
  4013. const isLt2M = file.size / 1024 / 1024 <= 2048
  4014. var date = new Date()
  4015. var ext = getFileExtension(file.name)
  4016. var key = date.getFullYear() + (date.getMonth() + 1) + date.getDate() + date.getHours() + date.getMinutes() + date.getSeconds() + '_o_' + file.uid + '.' + ext
  4017. const _self = this
  4018. return new Promise((resolve, reject) => {
  4019. getToken().then(response => {
  4020. const token = response.data.data.uptoken
  4021. console.log('token', token)
  4022. _self._data.uploadFileData.token = token
  4023. _self._data.uploadFileData.key = key
  4024. resolve(true)
  4025. // eslint-disable-next-line handle-callback-err
  4026. }).catch(err => {
  4027. reject(false)
  4028. })
  4029. })
  4030. },
  4031. handleSuccess(res, file, fileList) {
  4032. this.guaForm.images = this.qiniuDomain + res.url
  4033. console.log('图片路径', this.guaForm.images)
  4034. this.$refs.upload.clearFiles()
  4035. this.filename = file.name
  4036. this.guaForm.imageName = file.name
  4037. },
  4038. // eslint-disable-next-line no-dupe-keys
  4039. getTime(value, temp) {
  4040. // eslint-disable-next-line eqeqeq
  4041. if (value != undefined) {
  4042. return parseTime(value, temp)
  4043. }
  4044. return ''
  4045. },
  4046. SaveRepair(formName) {
  4047. if (this.guaForm.start_time === '') {
  4048. this.guaForm.start_time = '0'
  4049. }
  4050. if (this.guaForm.arrive_time === '') {
  4051. this.guaForm.arrive_time = '0'
  4052. }
  4053. if (this.guaForm.finish_time === '') {
  4054. this.guaForm.finish_time = '0'
  4055. }
  4056. if (this.guaForm.failure_stage === '') {
  4057. this.guaForm.failure_stage = '0'
  4058. }
  4059. var failurestages = this.guaForm.failure_stage
  4060. var falur = parseInt(failurestages)
  4061. this.guaForm.failure_stage = falur
  4062. if (this.guaForm.exclude === '') {
  4063. this.guaForm.exclude = 0
  4064. }
  4065. var excludes = this.guaForm.exclude
  4066. var exclude = parseInt(excludes)
  4067. this.guaForm.exclude = exclude
  4068. this.$refs[formName].validate((valid) => {
  4069. if (valid) {
  4070. SaveRepair(this.equimentid, this.guaForm).then(response => {
  4071. if (response.data.state === 1) {
  4072. var repair = response.data.data.repair
  4073. // console.log('reqair', repair)
  4074. this.$message.success('保存成功')
  4075. this.$refs.child.getAllRepair()
  4076. this.guaForm.start_time = ''
  4077. this.guaForm.arrive_time = ''
  4078. this.guaForm.finish_time = ''
  4079. this.guaForm.total_distance = ''
  4080. this.guaForm.code_information = ''
  4081. this.guaForm.fault_description = ''
  4082. this.guaForm.cause_analysis = ''
  4083. this.guaForm.reason = ''
  4084. this.guaForm.failure_stage = 0
  4085. this.guaForm.exclude = 0
  4086. this.guaForm.images = ''
  4087. this.guaForm.treatment_process = ''
  4088. this.classShow = false
  4089. this.guaForm.imageName = ''
  4090. }
  4091. })
  4092. }
  4093. })
  4094. },
  4095. querySearchAsync(keyword, cb) {
  4096. let key = ''
  4097. if (keyword != undefined) {
  4098. key = keyword
  4099. }
  4100. let searchArray = []
  4101. PostSearch(key).then(response => {
  4102. if (response.data.state == 1) {
  4103. searchArray = response.data.data.patient
  4104. // console.log("ser",searchArray)
  4105. cb(searchArray)
  4106. }
  4107. })
  4108. return searchArray
  4109. },
  4110. createFilter(queryString) {
  4111. return (searchArray) => {
  4112. return (searchArray.id.toLowerCase().indexOf(queryString.toLowerCase()) === 0)
  4113. }
  4114. },
  4115. handleSelect(item) {
  4116. this.userform.patient_id = item.id
  4117. this.userform.patient_name = item.name
  4118. // eslint-disable-next-line no-undef
  4119. getPatientDetail(item.id).then(response => {
  4120. // eslint-disable-next-line eqeqeq
  4121. if (response.data.state == 1) {
  4122. var patient = response.data.data.patient
  4123. // console.log('patient', patient)
  4124. // eslint-disable-next-line no-undef
  4125. if (patient.is_infectious === 0) {
  4126. this.userform.contagion = ''
  4127. }
  4128. // eslint-disable-next-line no-undef
  4129. if (patient.is_infectious === 1) {
  4130. this.userform.contagion = '无'
  4131. }
  4132. // eslint-disable-next-line no-undef
  4133. if (patient.is_infectious === 2) {
  4134. this.userform.contagion = '有'
  4135. }
  4136. }
  4137. })
  4138. },
  4139. getAllEquitType() {
  4140. getAllEquitType().then(response => {
  4141. if (response.data.state === 1) {
  4142. var equitname = response.data.data.mode
  4143. this.DeviceType = equitname
  4144. }
  4145. })
  4146. },
  4147. getTotalNumber() {
  4148. getTotalNumber(this.equimentid).then(response => {
  4149. if (response.data.state === 1) {
  4150. var total = response.data.data.total
  4151. if (total === '') {
  4152. this.userform.user_total = ''
  4153. }
  4154. this.userform.user_total = total
  4155. } else {
  4156. this.$message.error('数据返回失败')
  4157. }
  4158. })
  4159. },
  4160. getAllpatient() {
  4161. getAllpatient().then(response => {
  4162. if (response.data.state === 1) {
  4163. var allpatient = response.data.data.allpatient
  4164. this.patientName = allpatient
  4165. }
  4166. })
  4167. },
  4168. getTimeWarning(id) {
  4169. getTimeWarning(id).then(response => {
  4170. if (response.data.state === 1) {
  4171. var information = response.data.data.information
  4172. var time = this.getTimestamp(this.userform.date) - information.stime
  4173. // console.log('时间', time)
  4174. // if (time < 2678400) {
  4175. // this.warnShow = false
  4176. // }
  4177. var deviceInformation = response.data.data.deviceInformation
  4178. var timetwo = this.getTimestamp(this.userform.date) - deviceInformation.stime
  4179. // if (timetwo < 2678400) {
  4180. // this.warnShowTwo = false
  4181. // }
  4182. var clean = response.data.data.clean
  4183. // var timethree = this.getTimestamp(this.userform.date) - clean.stime
  4184. // if (timethree < 2678400) {
  4185. // this.warnShowThree = false
  4186. // }
  4187. }
  4188. })
  4189. },
  4190. getTimeBeteen(id) {
  4191. var todayTime = moment(new Date()).format('YYYY-MM-DD')
  4192. // console.log('todayTime', todayTime)
  4193. getTimeBeteen(id, todayTime).then(response => {
  4194. if (response.data.state === 1) {
  4195. var timedata = response.data.data.timeData
  4196. if (timedata.length === 0) {
  4197. this.warnShow = true
  4198. }
  4199. if (timedata.length !== 0) {
  4200. this.warnShow = false
  4201. }
  4202. var todayTimeTwo = response.data.data.timeDataTwo
  4203. // console.log('todayTimeTwo', todayTimeTwo)
  4204. if (todayTimeTwo.length === 0) {
  4205. this.warnShowTwo = true
  4206. }
  4207. if (todayTimeTwo.length !== 0) {
  4208. this.warnShowTwo = false
  4209. }
  4210. var timeDataThree = response.data.data.timeDataThree
  4211. //console.log('timeDataThree', timeDataThree)
  4212. if (timeDataThree.length === 0) {
  4213. this.warnShowThree = true
  4214. }
  4215. if (timeDataThree.length !== 0) {
  4216. this.warnShowThree = false
  4217. }
  4218. }
  4219. })
  4220. },
  4221. getTimestamp(time) { // 把时间日期转成时间戳
  4222. return (new Date(time)).getTime() / 1000
  4223. },
  4224. // eslint-disable-next-line no-irregular-whitespace
  4225. // 通过自组建传值改变表格数据
  4226. getPlanData(data) {
  4227. if (data === 1) {
  4228. this.getAllPlanDetail(this.unitType)
  4229. }
  4230. },
  4231. getAllMode() {
  4232. getAllMode().then(response => {
  4233. var mode = response.data.data.mode
  4234. this.deviceMode = mode
  4235. })
  4236. },
  4237. selectChange(id) {
  4238. selectChange(id).then(response => {
  4239. if (response.data.state === 1) {
  4240. this.userform.bed_number = ''
  4241. var change = response.data.data.change
  4242. this.bedNumberTwo = change
  4243. // console.log('change', change)
  4244. }
  4245. })
  4246. },
  4247. selectBed(id) {
  4248. selectBed(id).then(response => {
  4249. if (response.data.state === 1) {
  4250. var zone = response.data.data.zone
  4251. }
  4252. })
  4253. },
  4254. getData(id) {
  4255. selectBed(id).then(response => {
  4256. if (response.data.state === 1) {
  4257. var zone = response.data.data.zone
  4258. this.$forceUpdate()
  4259. this.userform.bed_number = zone.id
  4260. this.userform.zone = zone.zone_id
  4261. // console.log('zone', zone)
  4262. }
  4263. })
  4264. },
  4265. hiddenShow() {
  4266. this.$confirm(
  4267. '确认要删除所选图片吗? <br>删除后,信息将无法恢复',
  4268. '删除提示',
  4269. {
  4270. dangerouslyUseHTMLString: true,
  4271. confirmButtonText: '确定',
  4272. cancelButtonText: '取消',
  4273. type: 'warning'
  4274. }
  4275. ).then(() => {
  4276. this.filename = ''
  4277. this.guaForm.imageName = ''
  4278. this.guaForm.images = ''
  4279. this.classShow = false
  4280. })
  4281. }
  4282. },
  4283. created() {
  4284. this.getAllSubregion()
  4285. this.getAllMachine()
  4286. var index = this.$route.query.index
  4287. var bedid = this.$route.query.bedid
  4288. // var id = this.$route.query.id
  4289. // this.equimentid = id
  4290. this.bedid = bedid
  4291. this.getAllPlan()
  4292. this.getAllEquimentName()
  4293. this.getAllOrganization()
  4294. this.getOrgName()
  4295. this.getAllEquitType()
  4296. this.getAllpatient()
  4297. this.getAllMode()
  4298. }
  4299. }
  4300. </script>
  4301. <style lang="scss" scoped>
  4302. .zone{
  4303. // margin-left: 30px;
  4304. // text-align: left;
  4305. width: 70px;
  4306. display: inline-block;
  4307. color:#606266;
  4308. }
  4309. .disinfect{
  4310. position: relative;
  4311. .newButton{
  4312. // position: absolute;
  4313. // right: 2%;
  4314. // top:4px;
  4315. // z-index: 9;
  4316. margin-bottom: 10px;
  4317. margin-left: 90%;
  4318. }
  4319. }
  4320. .disinfectOne{
  4321. position: relative;
  4322. .newButtonOne{
  4323. position: absolute;
  4324. right: 0;
  4325. top: -10;
  4326. z-index: 18;
  4327. }
  4328. }
  4329. .but{
  4330. width: 200px;
  4331. height: 50px;
  4332. // border: solid 1px red;
  4333. margin-left: 77%;
  4334. }
  4335. .clearn{
  4336. width: 460px;
  4337. height: 50px;
  4338. // border:solid 1px red;
  4339. margin-left:650px;
  4340. }
  4341. .zClass{
  4342. width: 200px;
  4343. height: 200px;
  4344. // border:solid 1px red;
  4345. margin-left: 450px;
  4346. margin-top: 200px;
  4347. }
  4348. .warn{
  4349. color: red;
  4350. font-size: 14px;
  4351. width: 100%;
  4352. display: inline-block;
  4353. margin-left: 96px;
  4354. }
  4355. .userbutton{
  4356. margin-bottom: 10px;
  4357. margin-left: 82%
  4358. }
  4359. </style>
  4360. <style lang="scss">
  4361. .a{
  4362. margin-bottom: 10px;
  4363. margin-top: 6px;
  4364. }
  4365. .b{
  4366. .el-button{
  4367. margin-left: 90%;
  4368. margin-bottom: 10px;
  4369. }
  4370. }
  4371. .stoppage{
  4372. .el-form-item__label{
  4373. width:190px;
  4374. }
  4375. }
  4376. .st{
  4377. .el-form-item__label{
  4378. width:-10px;
  4379. }
  4380. }
  4381. .main{
  4382. position: relative;
  4383. .newButtonOne{
  4384. position:absolute;
  4385. right: 0;
  4386. z-index: 2;
  4387. }
  4388. }
  4389. .elbutton{
  4390. // border: solid 1px red;
  4391. height: 50px;
  4392. width: 400px;
  4393. margin-left: 650px;
  4394. }
  4395. // .el-form-item__label {
  4396. // width: 130px;
  4397. // font-size: 14px;
  4398. // }
  4399. .el-form-item__error {
  4400. margin-left: 130px;
  4401. }
  4402. .el-upload-list__item-name {
  4403. color: #606266;
  4404. display: block;
  4405. margin-right: 40px;
  4406. overflow: hidden;
  4407. padding-left: 4px;
  4408. text-overflow: ellipsis;
  4409. transition: color .3s;
  4410. white-space: nowrap;
  4411. }
  4412. .el-main{
  4413. padding-top: 0px;
  4414. }
  4415. .newMain{
  4416. .el-form-item__label{
  4417. width: 104px;
  4418. }
  4419. }
  4420. .newDisinfectOne{
  4421. .el-input--prefix .el-input__inner{
  4422. padding-left: 15px
  4423. }
  4424. }
  4425. .stoppage{
  4426. .el-form-item__label{
  4427. width: 18%;
  4428. }
  4429. }
  4430. .newItem{
  4431. .el-form-item__label{
  4432. width: 130px;
  4433. }
  4434. }
  4435. .formItem{
  4436. .el-form-item__label{
  4437. width: 104px;
  4438. line-height: 30px;
  4439. }
  4440. }
  4441. .newname{
  4442. .el-form-item__label{
  4443. width: 60px;
  4444. }
  4445. }
  4446. ::-webkit-scrollbar{
  4447. height: 20px;
  4448. }
  4449. </style>