detail_new_20250528.vue 181 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386338733883389339033913392339333943395339633973398339934003401340234033404340534063407340834093410341134123413341434153416341734183419342034213422342334243425342634273428342934303431343234333434343534363437343834393440344134423443344434453446344734483449345034513452345334543455345634573458345934603461346234633464346534663467346834693470347134723473347434753476347734783479348034813482348334843485348634873488348934903491349234933494349534963497349834993500350135023503350435053506350735083509351035113512351335143515351635173518351935203521352235233524352535263527352835293530353135323533353435353536353735383539354035413542354335443545354635473548354935503551355235533554355535563557355835593560356135623563356435653566356735683569357035713572357335743575357635773578357935803581358235833584358535863587358835893590359135923593359435953596359735983599360036013602360336043605360636073608360936103611361236133614361536163617361836193620362136223623362436253626362736283629363036313632363336343635363636373638363936403641364236433644364536463647364836493650365136523653365436553656365736583659366036613662366336643665366636673668366936703671367236733674367536763677367836793680368136823683368436853686368736883689369036913692369336943695369636973698369937003701370237033704370537063707370837093710371137123713371437153716371737183719372037213722372337243725372637273728372937303731373237333734373537363737373837393740374137423743374437453746374737483749375037513752375337543755375637573758375937603761376237633764376537663767376837693770377137723773377437753776377737783779378037813782378337843785378637873788378937903791379237933794379537963797379837993800380138023803380438053806380738083809381038113812381338143815381638173818381938203821382238233824382538263827382838293830383138323833383438353836383738383839384038413842384338443845384638473848384938503851385238533854385538563857385838593860386138623863386438653866386738683869387038713872387338743875387638773878387938803881388238833884388538863887388838893890389138923893389438953896389738983899390039013902390339043905390639073908390939103911391239133914391539163917391839193920392139223923392439253926392739283929393039313932393339343935393639373938393939403941394239433944394539463947394839493950395139523953395439553956395739583959396039613962396339643965396639673968396939703971397239733974397539763977397839793980398139823983398439853986398739883989399039913992399339943995399639973998399940004001400240034004400540064007400840094010401140124013401440154016401740184019402040214022402340244025402640274028402940304031403240334034403540364037403840394040404140424043404440454046404740484049405040514052405340544055405640574058405940604061406240634064406540664067406840694070407140724073407440754076407740784079408040814082408340844085408640874088408940904091409240934094409540964097409840994100410141024103410441054106410741084109411041114112411341144115411641174118411941204121412241234124412541264127412841294130413141324133413441354136413741384139414041414142414341444145414641474148414941504151415241534154415541564157415841594160416141624163416441654166416741684169417041714172417341744175417641774178417941804181418241834184418541864187418841894190419141924193419441954196419741984199420042014202420342044205420642074208420942104211421242134214421542164217421842194220422142224223422442254226422742284229423042314232423342344235423642374238423942404241424242434244424542464247424842494250425142524253425442554256425742584259426042614262426342644265426642674268426942704271427242734274427542764277427842794280428142824283428442854286428742884289429042914292429342944295429642974298429943004301430243034304430543064307430843094310431143124313431443154316431743184319432043214322432343244325432643274328432943304331433243334334433543364337433843394340434143424343434443454346434743484349435043514352435343544355435643574358435943604361436243634364436543664367436843694370437143724373437443754376437743784379438043814382438343844385438643874388438943904391439243934394439543964397439843994400440144024403440444054406440744084409441044114412441344144415441644174418441944204421442244234424442544264427442844294430443144324433443444354436443744384439444044414442444344444445444644474448444944504451445244534454445544564457445844594460446144624463446444654466446744684469447044714472447344744475447644774478447944804481448244834484448544864487448844894490449144924493449444954496449744984499450045014502450345044505450645074508450945104511451245134514451545164517451845194520452145224523452445254526452745284529453045314532453345344535453645374538453945404541454245434544454545464547454845494550455145524553455445554556455745584559456045614562456345644565456645674568456945704571457245734574457545764577457845794580458145824583458445854586458745884589459045914592459345944595459645974598459946004601460246034604460546064607460846094610461146124613461446154616461746184619462046214622462346244625462646274628462946304631463246334634463546364637463846394640464146424643464446454646464746484649465046514652465346544655465646574658465946604661466246634664466546664667466846694670467146724673467446754676467746784679468046814682468346844685468646874688468946904691469246934694469546964697469846994700470147024703470447054706470747084709471047114712471347144715471647174718471947204721472247234724472547264727472847294730473147324733473447354736473747384739474047414742474347444745474647474748474947504751475247534754475547564757475847594760476147624763476447654766476747684769477047714772477347744775477647774778477947804781478247834784478547864787478847894790479147924793479447954796479747984799480048014802480348044805480648074808480948104811481248134814481548164817481848194820482148224823482448254826482748284829483048314832483348344835483648374838483948404841484248434844484548464847484848494850485148524853485448554856485748584859486048614862486348644865486648674868486948704871487248734874487548764877487848794880488148824883488448854886488748884889489048914892489348944895489648974898489949004901490249034904490549064907490849094910491149124913491449154916491749184919492049214922492349244925492649274928492949304931493249334934493549364937493849394940494149424943494449454946494749484949495049514952495349544955495649574958495949604961496249634964496549664967496849694970497149724973497449754976497749784979498049814982498349844985498649874988498949904991499249934994499549964997499849995000500150025003500450055006500750085009501050115012501350145015501650175018501950205021502250235024502550265027502850295030503150325033503450355036503750385039504050415042504350445045504650475048504950505051505250535054505550565057505850595060506150625063506450655066506750685069507050715072507350745075507650775078507950805081508250835084508550865087508850895090509150925093509450955096509750985099510051015102510351045105510651075108510951105111511251135114511551165117511851195120512151225123512451255126512751285129513051315132513351345135513651375138513951405141514251435144514551465147514851495150515151525153515451555156515751585159516051615162516351645165516651675168516951705171517251735174517551765177517851795180518151825183518451855186518751885189519051915192519351945195519651975198519952005201520252035204520552065207520852095210521152125213521452155216521752185219522052215222522352245225522652275228522952305231523252335234523552365237523852395240524152425243524452455246524752485249525052515252525352545255525652575258525952605261526252635264526552665267526852695270527152725273527452755276527752785279528052815282528352845285528652875288528952905291529252935294529552965297529852995300530153025303530453055306530753085309531053115312531353145315531653175318531953205321532253235324532553265327532853295330533153325333533453355336533753385339534053415342534353445345534653475348534953505351
  1. <template>
  2. <view class="content" >
  3. <view class="header" :style='"background-image:url("+imgUrl+"/detail/bg.png);background-repeat: no-repeat;background-size: 100% 200%;top:-5vh;height:110vh"'>
  4. <view v-if="isH5" @click='goBack()' style=" font-size: 16px;
  5. padding-top: 7px;
  6. position: absolute;
  7. top: 5vh;
  8. left: 20px;
  9. }">
  10. 返回
  11. </view>
  12. <view class="status_info">
  13. <view class="status_detail">
  14. <view class="status_text">{{ getStatusText() }}</view>
  15. <view v-if="deviceInfo.status == 3" class="online_text online">
  16. <view>
  17. {{workText}}
  18. </view>
  19. </view>
  20. <view v-if="deviceInfo.status == 4" class="online_text">·离线</view>
  21. </view>
  22. <view class="device_info">机器名称: {{deviceInfo.deviceName}}</view>
  23. </view>
  24. <view style="position: absolute;right:10vw;top:15vh;z-index: 9" @click="showDrawer">
  25. <image :src="imgUrl+'/detail/setting2.png'" style="width: 50rpx;height: 50rpx;"/>
  26. </view>
  27. <view style="position: relative;top:15vh;width: 100%;text-align: center">
  28. <image :src="productImage" :style="productSize"/>
  29. </view>
  30. <view style="position: relative;height: 150rpx;top:15vh;display: flex;">
  31. <image :src="imgUrl+'/detail/bg_large.png'" style="width: 100%;height:100%;position: absolute;top:0px;"/>
  32. <view @click="changeJianyaoMode(0)" class="left_area" style="width: 50%;height: 100%;display: flex;position: relative">
  33. <view style="width: 30%;height: 100%;align-items: center;display: flex;margin-left:20%">
  34. <image v-if="jianyaoMode == 0" :src="imgUrl+'/img20250528/jian_on.png'" style="width: 61%;height:61%;"/>
  35. <image v-if="jianyaoMode == 1" :src="imgUrl+'/img20250528/jian_off.png'" style="width: 61%;height:61%;"/>
  36. </view>
  37. <view style="width: 50%;height: 100%;align-items: center;display: flex;z-index: 999" v-if="jianyaoMode == 1">
  38. 一煎模式
  39. </view>
  40. <view style="width: 50%;height: 100%;align-items: center;display: flex;z-index: 999;color:#50ACFF" v-if="jianyaoMode == 0">
  41. 一煎模式
  42. </view>
  43. <view @click.stop="showYaofangPicker = true" style="position: absolute;right: 0px;bottom:14px;height: 10px;width: 10px;height: 8px;z-index: 8888">
  44. <image :src="imgUrl+'/img20250528/xia.png'" style="width: 100%;height:100%;"/>
  45. </view>
  46. <view style="position: absolute;right: -12px;top: 10px;height: 11px;width: 45px;">
  47. <image :src="imgUrl+'/img20250528/min-bg.png'" style="width: 100%;height:100%;position: absolute;inset: 0"/>
  48. <view style=" font-size: 9px; position: relative;">{{ yaofang.name }}</view>
  49. </view>
  50. </view>
  51. <view @click="changeJianyaoMode(1)" class="left_area" style="width: 50%;height: 100%;display: flex">
  52. <view style="width: 30%;height: 100%;align-items: center;display: flex;margin-left:20%">
  53. <image v-if="jianyaoMode == 1" :src="imgUrl+'/img20250528/jian_on.png'" style="width: 61%;height:61%;"/>
  54. <image v-if="jianyaoMode == 0" :src="imgUrl+'/img20250528/jian_off.png'" style="width: 61%;height:61%;"/>
  55. </view>
  56. <view style="width: 50%;height: 100%;align-items: center;display: flex;z-index: 999;color:#50ACFF" v-if="jianyaoMode == 1">
  57. 二煎模式
  58. </view>
  59. <view style="width: 50%;height: 100%;align-items: center;display: flex;z-index: 999" v-if="jianyaoMode == 0">
  60. 二煎模式
  61. </view>
  62. <view @click.stop="erqibushuiDlg = true" style="position: absolute;right: 40rpx;bottom:14px;height: 10px;width: 10px;height: 8px;z-index: 8888">
  63. <image :src="imgUrl+'/img20250528/xia.png'" style="width: 100%;height:100%;"/>
  64. </view>
  65. <view style="position: absolute;right: 26rpx;top: 10px;height: 11px;width: 40px;">
  66. <image :src="imgUrl+'/img20250528/min-bg.png'" style="width: 100%;height:100%;position: absolute;inset: 0"/>
  67. <view style=" font-size: 9px; position: relative;">二煎补水</view>
  68. </view>
  69. </view>
  70. </view>
  71. <view class="control_area" v-if="firstTab" :style="boardStyle">
  72. <view class="control" v-if="boardType ==6">
  73. <view class="control_item" v-if="jianyaoMode == 0">
  74. <image :src="imgUrl+'/detail/bg_mid.png'" style="width: 100%;height:100%;position: absolute;top:0px;"/>
  75. <view class="control_item_detail">
  76. <view class="control_item_left" @click="subTemperature(1)">-</view>
  77. <view class="control_item_center">
  78. <view style="position: absolute">
  79. <u-input customStyle="width:150rpx;border:0px;" disabledColor="white" @change="propChange(1)" @focus="propFocus(1)" @confirm="propBlur(1)" @blur="propBlur(1)" v-model="temperature"></u-input>
  80. </view>
  81. </view>
  82. <view class="control_item_center_unit" :style="unitFixedStyle">℃</view>
  83. <view class="control_item_right" @click="addTemperature(1)">+</view>
  84. </view>
  85. <view class="control_item_title">
  86. 设置温度
  87. </view>
  88. </view>
  89. <view class="control_item" v-if="jianyaoMode == 1">
  90. <image :src="imgUrl+'/detail/bg_mid.png'" style="width: 100%;height:100%;position: absolute;top:0px;"/>
  91. <view class="control_item_detail">
  92. <view class="control_item_left" @click="subTemperature(1)">-</view>
  93. <view class="control_item_center">
  94. <view style="position: absolute">
  95. <u-input customStyle="width:150rpx;border:0px;" disabledColor="white" @change="propChange(1)" @focus="propFocus(1)" @confirm="propBlur(1)" @blur="propBlur(1)" v-model="FirstTemp"></u-input>
  96. </view>
  97. </view>
  98. <view class="control_item_center_unit" :style="unitFixedStyle">℃</view>
  99. <view class="control_item_right" @click="addTemperature(1)">+</view>
  100. </view>
  101. <view class="control_item_title">
  102. 设置温度
  103. </view>
  104. </view>
  105. <!-- <view class="control_item" v-if="!wenduSetting">-->
  106. <!-- <image :src="imgUrl+'/detail/bg_mid.png'" style="width: 100%;height:100%;position: absolute;top:0px;"/>-->
  107. <!-- <view class="control_item_detail">-->
  108. <!-- <view class="control_item_left" @click="subTemperature(1)">-</view>-->
  109. <!-- <view class="control_item_center">-->
  110. <!-- <view style="position: absolute">-->
  111. <!-- <u-input customStyle="width:150rpx;border:0px;" disabledColor="white" disabled="" v-model="currentTemperature"></u-input>-->
  112. <!-- </view>-->
  113. <!-- </view>-->
  114. <!-- <view class="control_item_center_unit" :style="unitFixedStyle">℃</view>-->
  115. <!-- <view class="control_item_right" @click="addTemperature(1)">+</view>-->
  116. <!-- </view>-->
  117. <!-- <view class="control_item_title">-->
  118. <!-- 当前温度-->
  119. <!-- </view>-->
  120. <!-- </view>-->
  121. <view class="control_item" v-if=" jianyaoMode == 0">
  122. <image :src="imgUrl+'/detail/bg_mid.png'" style="width: 100%;height:100%;position: absolute;top:0px;"/>
  123. <view class="control_item_detail">
  124. <view class="control_item_left" @click="subNewTemperatureTime(1)">-</view>
  125. <view class="control_item_center">
  126. <view style="position: absolute;z-index: 999">
  127. <u-input customStyle="width:150rpx;border:0px;z-index: 999" disabledColor="white" v-model="temperatureTime"></u-input>
  128. </view>
  129. </view>
  130. <view class="control_item_center_unit" :style="unitFixedStyle">min</view>
  131. <view class="control_item_right" style="left: 74%;" @click="addNewTemperatureTime(1)">+</view>
  132. </view>
  133. <view class="control_item_title">
  134. 时间设置
  135. </view>
  136. </view>
  137. <view class="control_item" v-if=" jianyaoMode == 1">
  138. <image :src="imgUrl+'/detail/bg_mid.png'" style="width: 100%;height:100%;position: absolute;top:0px;"/>
  139. <view class="control_item_detail">
  140. <view class="control_item_left" @click="subTemperatureTime(1)">-</view>
  141. <view class="control_item_center">
  142. <view style="position: absolute;z-index: 999">
  143. <u-input customStyle="width:150rpx;border:0px;z-index: 999" disabledColor="white" v-model="FirstTime"></u-input>
  144. </view>
  145. </view>
  146. <view class="control_item_center_unit" :style="unitFixedStyle">min</view>
  147. <view class="control_item_right" style="left: 74%;" @click="addTemperatureTime(1)">+</view>
  148. </view>
  149. <view class="control_item_title">
  150. 时间设置
  151. </view>
  152. </view>
  153. <!-- <view class="control_item" v-if="!wenhuoTimeDlgShow">-->
  154. <!-- <image :src="imgUrl+'/detail/bg_mid.png'" style="width: 100%;height:100%;position: absolute;top:0px;"/>-->
  155. <!-- <view class="control_item_detail">-->
  156. <!-- <view class="control_item_left" @click="subTemperatureTime(1)">-</view>-->
  157. <!-- <view class="control_item_center">-->
  158. <!-- <view style="position: absolute">-->
  159. <!-- <u-input customStyle="width:150rpx;border:0px;" disabledColor="white" @change="propChange(1)" @focus="propFocus(2)" @confirm="propBlur(2)" @blur="propBlur(2)" v-model="leftJianyaoTime"></u-input>-->
  160. <!-- </view>-->
  161. <!-- </view>-->
  162. <!-- <view class="control_item_center_unit" :style="unitFixedStyle">min</view>-->
  163. <!-- <view class="control_item_right" style="left: 74%;" @click="addTemperatureTime(1)">+</view>-->
  164. <!-- </view>-->
  165. <!-- <view class="control_item_title">-->
  166. <!-- 时间设置-->
  167. <!-- </view>-->
  168. <!-- </view>-->
  169. <view style="position: relative;top:-2vh">
  170. <view class="control_item">
  171. <image :src="imgUrl+'/detail/bg_mid.png'" style="width: 100%;height:100%;position: absolute;top:0px;"/>
  172. <view class="control_item_detail">
  173. <view class="control_item_left" @click="subPlanTime(1)">-</view>
  174. <view class="control_item_center">
  175. <view style="position: absolute">
  176. <u-input customStyle="width:150rpx;border:0px;" disabledColor="white" v-model="planTime"></u-input>
  177. </view>
  178. </view>
  179. <view class="control_item_center_unit" :style="unitFixedStyle">min</view>
  180. <view class="control_item_right" style="left: 74%;" @click="addPlanTime(1)">+</view>
  181. </view>
  182. <view class="control_item_title">
  183. 预约时间
  184. </view>
  185. </view>
  186. <!-- <view class="control_item" v-if="!planEditTime">-->
  187. <!-- <image :src="imgUrl+'/detail/bg_mid.png'" style="width: 100%;height:100%;position: absolute;top:0px;"/>-->
  188. <!-- <view class="control_item_detail">-->
  189. <!-- <view class="control_item_left" @click="subPlanTime(1)">-</view>-->
  190. <!-- <view class="control_item_center">-->
  191. <!-- <view style="position: absolute">-->
  192. <!-- <u-input customStyle="width:150rpx;border:0px;" disabledColor="white" @change="propChange(8)" @focus="propFocus(8)" @confirm="propBlur(8)" @blur="propBlur(8)" v-model="leftAppointmentTime"></u-input>-->
  193. <!-- </view>-->
  194. <!-- </view>-->
  195. <!-- <view class="control_item_center_unit" :style="unitFixedStyle">min</view>-->
  196. <!-- <view class="control_item_right" style="left: 74%;" @click="addPlanTime(1)">+</view>-->
  197. <!-- </view>-->
  198. <!-- <view class="control_item_title">-->
  199. <!-- 预约时间-->
  200. <!-- </view>-->
  201. <!-- </view>-->
  202. <view class="control_item" v-if="jianyaoMode == 0">
  203. <image :src="imgUrl+'/detail/bg_mid.png'" style="width: 100%;height:100%;position: absolute;top:0px;"/>
  204. <view class="control_item_detail">
  205. <view class="control_item_left" @click="subWaterVolume(1)">-</view>
  206. <view class="control_item_center">
  207. <view style="position: absolute">
  208. <u-input customStyle="width:150rpx;border:0px;" disabledColor="white" @change="propChange(1)" @focus="propFocus(1)" @confirm="propBlur(7)" @blur="propBlur(7)" v-model="waterVolume"></u-input>
  209. </view>
  210. </view>
  211. <view class="control_item_center_unit" :style="unitFixedStyle">L</view>
  212. <view class="control_item_right" @click="addWaterVolume(1)">+</view>
  213. </view>
  214. <view class="control_item_title">
  215. 煎药水量
  216. </view>
  217. </view>
  218. <view class="control_item" v-if="jianyaoMode == 1">
  219. <image :src="imgUrl+'/detail/bg_mid.png'" style="width: 100%;height:100%;position: absolute;top:0px;"/>
  220. <view class="control_item_detail">
  221. <view class="control_item_left" @click="subWaterVolume(1)">-</view>
  222. <view class="control_item_center">
  223. <view style="position: absolute">
  224. <u-input customStyle="width:150rpx;border:0px;" disabledColor="white" @change="propChange(1)" @focus="propFocus(1)" @confirm="propBlur(7)" @blur="propBlur(7)" v-model="secondWaterVolume"></u-input>
  225. </view>
  226. </view>
  227. <view class="control_item_center_unit" :style="unitFixedStyle">L</view>
  228. <view class="control_item_right" @click="addWaterVolume(1)">+</view>
  229. </view>
  230. <view class="control_item_title">
  231. 煎药水量
  232. </view>
  233. </view>
  234. <!-- <view class="control_item" v-if="!editWaterVolume">-->
  235. <!-- <image :src="imgUrl+'/detail/bg_mid.png'" style="width: 100%;height:100%;position: absolute;top:0px;"/>-->
  236. <!-- <view class="control_item_detail">-->
  237. <!-- <view class="control_item_left" @click="subWaterVolume(1)">-</view>-->
  238. <!-- <view class="control_item_center">-->
  239. <!-- <view style="position: absolute">-->
  240. <!-- <u-input customStyle="width:150rpx;border:0px;" disabledColor="white" v-model="currentWaterVolume"></u-input>-->
  241. <!-- </view>-->
  242. <!-- </view>-->
  243. <!-- <view class="control_item_center_unit" :style="unitFixedStyle">L</view>-->
  244. <!-- <view class="control_item_right" @click="addWaterVolume(1)">+</view>-->
  245. <!-- </view>-->
  246. <!-- <view class="control_item_title">-->
  247. <!-- 当前煎药水量-->
  248. <!-- </view>-->
  249. <!-- </view>-->
  250. </view>
  251. <view style="position: relative;top:-4vh">
  252. <view class="control_item">
  253. <image :src="imgUrl+'/detail/bg_mid.png'" style="width: 100%;height:100%;position: absolute;top:0px;"/>
  254. <view class="control_item_detail">
  255. <view class="control_item_left" @click="subTimeFirst(1)">-</view>
  256. <view class="control_item_center">
  257. <view style="position: absolute">
  258. <u-input customStyle="width:150rpx;border:0px;" disabledColor="white" @confirm="propBlur(14)" @blur="propBlur(14)" v-model="timeSettingFirst"></u-input>
  259. </view>
  260. </view>
  261. <view class="control_item_center_unit" :style="unitFixedStyle">min</view>
  262. <view class="control_item_right" style="left: 74%;" @click="addTimeFirst(1)">+</view>
  263. </view>
  264. <view class="control_item_title">
  265. 先煎时间
  266. </view>
  267. </view>
  268. <!-- <view class="control_item" v-if="!editTimeSettingFirst">-->
  269. <!-- <image :src="imgUrl+'/detail/bg_mid.png'" style="width: 100%;height:100%;position: absolute;top:0px;"/>-->
  270. <!-- <view class="control_item_detail">-->
  271. <!-- <view class="control_item_left" @click="subTimeFirst(1)">-</view>-->
  272. <!-- <view class="control_item_center">-->
  273. <!-- <view style="position: absolute">-->
  274. <!-- <u-input customStyle="width:150rpx;border:0px;" disabledColor="white" v-model="currentTimeSettingFirst"></u-input>-->
  275. <!-- </view>-->
  276. <!-- </view>-->
  277. <!-- <view class="control_item_center_unit" :style="unitFixedStyle">min</view>-->
  278. <!-- <view class="control_item_right" style="left: 74%;" @click="addTimeFirst(1)">+</view>-->
  279. <!-- </view>-->
  280. <!-- <view class="control_item_title">-->
  281. <!-- 先煎时间-->
  282. <!-- </view>-->
  283. <!-- </view>-->
  284. <view class="control_item">
  285. <image :src="imgUrl+'/detail/bg_mid.png'" style="width: 100%;height:100%;position: absolute;top:0px;"/>
  286. <view class="control_item_detail">
  287. <view class="control_item_left" @click="subTimeSecond(1)">-</view>
  288. <view class="control_item_center">
  289. <view style="position: absolute">
  290. <u-input customStyle="width:150rpx;border:0px;" disabledColor="white" @confirm="propBlur(15)" @blur="propBlur(15)" v-model="timeSettingSecond"></u-input>
  291. </view>
  292. </view>
  293. <view class="control_item_center_unit" :style="unitFixedStyle">min</view>
  294. <view class="control_item_right" style="left: 74%;" @click="addTimeSecond(1)">+</view>
  295. </view>
  296. <view class="control_item_title">
  297. 后下时间
  298. </view>
  299. </view>
  300. <!-- <view class="control_item" v-if="!editTimeSettingSecond">-->
  301. <!-- <image :src="imgUrl+'/detail/bg_mid.png'" style="width: 100%;height:100%;position: absolute;top:0px;"/>-->
  302. <!-- <view class="control_item_detail">-->
  303. <!-- <view class="control_item_left" @click="subTimeSecond(1)">-</view>-->
  304. <!-- <view class="control_item_center">-->
  305. <!-- <view style="position: absolute">-->
  306. <!-- <u-input customStyle="width:150rpx;border:0px;" disabledColor="white" v-model="currentTimeSettingSecond"></u-input>-->
  307. <!-- </view>-->
  308. <!-- </view>-->
  309. <!-- <view class="control_item_center_unit" :style="unitFixedStyle">分钟</view>-->
  310. <!-- <view class="control_item_right" style="left: 74%;" @click="addTimeSecond(1)">+</view>-->
  311. <!-- </view>-->
  312. <!-- <view class="control_item_title">-->
  313. <!-- 后下时间-->
  314. <!-- </view>-->
  315. <!-- </view>-->
  316. </view>
  317. </view>
  318. <view class="bottom" v-if="boardType == 6">
  319. <image :src="imgUrl+'/detail/bg_large.png'" style="width: 100%;height:100%;position: absolute;top:0px;"/>
  320. <view class="bottom_item" @click="setPressTurn">
  321. <image v-if="pressTurn == 1" :src="imgUrl+'/img20250528/jiya_on.png'" style="width: 32%;height:32%;"/>
  322. <image v-if="pressTurn == 0" :src="imgUrl+'/img20250528/jiya_off.png'" style="width: 32%;height:32%;"/>
  323. <view :class="pressTurn == 1?'active_on':''">挤压</view>
  324. </view>
  325. <view class="bottom_item" @click="setResetTurn">
  326. <image v-if="resetTurn == 1" :src="imgUrl+'/img20250528/fuwei_on.png'" style="width: 32%;height:32%;"/>
  327. <image v-if="resetTurn == 0" :src="imgUrl+'/img20250528/fuwei_off.png'" style="width: 32%;height:32%;"/>
  328. <view :class="resetTurn == 1?'active_on':''">复位</view>
  329. </view>
  330. <view class="bottom_item" @click="turnChange(3)">
  331. <image v-if="!qingxiTurn" :src="imgUrl+'/img20250528/qingxi_off.png'" style="width: 32%;height:32%;"/>
  332. <image v-if="qingxiTurn" :src="imgUrl+'/img20250528/qingxi_on.png'" style="width: 32%;height:32%;"/>
  333. <view :class="!qingxiTurn?'':'active_on'">清洗</view>
  334. </view>
  335. <view class="bottom_item" @click="paishui">
  336. <image v-if="drainageTurn == 1" :src="imgUrl+'/img20250528/paishui_on.png'" style="width: 32%;height:32%;"/>
  337. <image v-if="drainageTurn == 0" :src="imgUrl+'/img20250528/paishui_off.png'" style="width: 32%;height:32%;"/>
  338. <view :class="drainageTurn == 1?'active_on':''">排水</view>
  339. </view>
  340. <view class="bottom_item" @click="decoctControlChange">
  341. <image v-if="decoctControlStatus" :src="imgUrl+'/img20250528/qidong_on.png'" style="width: 32%;height:32%;"/>
  342. <image v-else :src="imgUrl+'/img20250528/qidong_off.png'" style="width: 32%;height:32%;"/>
  343. <view :class="decoctControlStatus?'active_on':''">启动</view>
  344. </view>
  345. </view>
  346. </view>
  347. </view>
  348. <u-popup :show="closeFinishStatusPop" @close="closeFinishPop" mode="center" bgColor="transparent" :closeable="true" :closeOnClickOverlay ="false" :round="10">
  349. <view style="position: relative;width: 500rpx; border-radius: 12px;padding-bottom: 22px;background: rgb(244,244,244)">
  350. <view style=" text-align: center;
  351. font-weight: 500;
  352. font-size: 22px;
  353. padding: 15px;">{{ statusHandler.title }}</view>
  354. <view style=" text-align: center;font-size: 18px;font-weight: 500;margin-top: 7px;">
  355. <view v-for="content in statusHandler.desc">{{ content }}</view>
  356. <view>{{ content }}</view>
  357. </view>
  358. <view style=" display: flex;flex-direction: row;">
  359. <view @click="setPressTurn" style="width: 33%;position: relative" >
  360. <view style="background: white;height: 50px;width: 60px;position: relative;border-radius: 10px;top: 10px;margin: 0 10px;">
  361. <view style="height: 30%;width: 40%;position: relative;left: 34%;top: 20%;">
  362. <image v-if="pressTurn == 1" :src="imgUrl+'/img20250528/jiya_on.png'" style="width: 100%;height: 100%"/>
  363. <image v-if="pressTurn == 0" :src="imgUrl+'/img20250528/jiya_off.png'" style="width: 100%;height: 100%"/>
  364. </view>
  365. <view style=" position: relative;left: 37%;top: 29%; font-size: 12px;">挤压</view>
  366. </view>
  367. </view>
  368. <view @click="setResetTurn" style="width: 33%;position: relative" >
  369. <view style="background: white;height: 50px;width: 60px;position: relative;border-radius: 10px;top: 10px;margin: 0 10px;">
  370. <view style="height: 30%;width: 40%;position: relative;left: 34%;top: 20%;">
  371. <image v-if="resetTurn == 1" :src="imgUrl+'/img20250528/fuwei_on.png'" style="width: 100%;height: 100%"/>
  372. <image v-if="resetTurn == 0" :src="imgUrl+'/img20250528/fuwei_off.png'" style="width: 100%;height: 100%"/>
  373. </view>
  374. <view style=" position: relative;left: 37%;top: 29%; font-size: 12px;">复位</view>
  375. </view>
  376. </view>
  377. <view @click="paishui" style="width: 33%;position: relative" >
  378. <view style="background: white;height: 50px;width: 60px;position: relative;border-radius: 10px;top: 10px;margin: 0 10px;">
  379. <view style="height: 30%;width: 40%;position: relative;left: 34%;top: 20%;">
  380. <image v-if="drainageTurn == 1" :src="imgUrl+'/img20250528/chuyao_on.png'" style="width: 100%;height: 100%"/>
  381. <image v-if="drainageTurn == 0" :src="imgUrl+'/img20250528/chuyao_off.png'" style="width: 100%;height: 100%"/>
  382. </view>
  383. <view style=" position: relative;left: 37%;top: 29%; font-size: 12px;">出药</view>
  384. </view>
  385. </view>
  386. </view>
  387. </view>
  388. </u-popup>
  389. <u-popup :show="zhuanyiyaoyePop" mode="center" bgColor="transparent" :closeOnClickOverlay ="false" :round="10">
  390. <view style=" padding-top: 17px;text-align:center;position: relative;width: 500rpx; border-radius: 12px;padding-bottom: 22px;background: rgb(244,244,244)">
  391. <view>
  392. 正在转移药液中
  393. </view>
  394. <view>
  395. 暂时不能进入其他操作
  396. </view>
  397. <view style="background: white;text-align: left;padding: 0px 18%;margin-top: 13px;">
  398. <text style="color: red">转移药液剩余时间:</text>
  399. <text style="margin-left: 10px">{{ leftTransferTime }}</text>
  400. </view>
  401. </view>
  402. </u-popup>
  403. <u-popup :show="closeStatusPop" mode="center" bgColor="transparent" :closeOnClickOverlay ="false" :round="10">
  404. <view style="position: relative;width: 500rpx; border-radius: 12px;padding-bottom: 22px;background: rgb(244,244,244)">
  405. <view style=" text-align: center;
  406. font-weight: 500;
  407. font-size: 22px;
  408. padding: 15px;">{{ statusHandler.title }}</view>
  409. <view v-if="statusHandler.type == 1">
  410. <view class="control_item" style="width: 100%;background: white;height: 90rpx" v-if="!editWaterVolume">
  411. <view class="control_item_detail">
  412. <view class="control_item_left" style="left:22%;top:-41rpx" @click="subWaterVolume(1)">-</view>
  413. <view class="control_item_center" style="top:-2px;left: 40%;">
  414. <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" v-model="currentWaterVolume"/>
  415. </view>
  416. <view class="control_item_center_unit" style="; font-size: 12px;
  417. left: 37vw;
  418. top: 13px;">L</view>
  419. <view class="control_item_right" style="top: -3px" @click="addWaterVolume(1)">+</view>
  420. </view>
  421. </view>
  422. <view class="control_item" style="width: 100%;background: white;height: 90rpx" v-if="editWaterVolume">
  423. <view class="control_item_detail">
  424. <view class="control_item_left" style="left:22%;top:-41rpx" @click="subWaterVolume(1)">-</view>
  425. <view class="control_item_center" style="top:-2px;left: 40%;">
  426. <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" @change="propChange(1)" @focus="propFocus(1)" @confirm="propBlur(7)" @blur="propBlur(7)" v-model="waterVolume"/>
  427. </view>
  428. <view class="control_item_center_unit" style="; font-size: 12px;
  429. left: 37vw;
  430. top: 13px;">L</view>
  431. <view class="control_item_right" style="top: -3px" @click="addWaterVolume(1)">+</view>
  432. </view>
  433. </view>
  434. </view>
  435. <view v-if="statusHandler.type == 2">
  436. <view class="control_item" style="width: 100%;background: white;height: 90rpx" >
  437. <view class="control_item_detail">
  438. <view class="control_item_center" style="top:-2px;left: 40%;">
  439. <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" value="40"/>
  440. </view>
  441. <view class="control_item_center_unit" style="; font-size: 12px;
  442. left: 37vw;
  443. top: 13px;">℃</view>
  444. </view>
  445. </view>
  446. <view class="control_item" style="width: 100%;background: white;height: 90rpx" v-if="planEditTime">
  447. <view class="control_item_detail">
  448. <view class="control_item_left" style="left:22%;top:-41rpx" @click="subPlanTime(1)">-</view>
  449. <view class="control_item_center" style="top:-2px;left: 40%;">
  450. <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" v-model="planTime"/>
  451. </view>
  452. <view class="control_item_center_unit" style="; font-size: 12px;
  453. left: 37vw;
  454. top: 13px;">min</view>
  455. <view class="control_item_right" style="top: -3px" @click="addPlanTime(1)">+</view>
  456. </view>
  457. </view>
  458. <view class="control_item" style="width: 100%;background: white;height: 90rpx" v-if="!planEditTime">
  459. <view class="control_item_detail">
  460. <view class="control_item_left" style="left:22%;top:-41rpx" @click="subPlanTime(1)">-</view>
  461. <view class="control_item_center" style="top:-2px;left: 40%;">
  462. <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" @change="propChange(1)" @focus="propFocus(1)" @confirm="propBlur(7)" @blur="propBlur(7)" v-model="leftAppointmentTime"/>
  463. </view>
  464. <view class="control_item_center_unit" style="; font-size: 12px;
  465. left: 37vw;
  466. top: 13px;">min</view>
  467. <view class="control_item_right" style="top: -3px" @click="addPlanTime(1)">+</view>
  468. </view>
  469. </view>
  470. </view>
  471. <view v-if="statusHandler.type == 3">
  472. <view>
  473. <view class="control_item" style="width: 100%;background: white;height: 90rpx" v-if="editTempSettingFirst">
  474. <view class="control_item_detail">
  475. <view class="control_item_left" style="left:22%;top:-41rpx" @click="subTempSettingFirst(1)">-</view>
  476. <view class="control_item_center" style="top:-2px;left: 40%;">
  477. <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" v-model="tempSettingFirst"/>
  478. </view>
  479. <view class="control_item_center_unit" style="; font-size: 12px;
  480. left: 37vw;
  481. top: 13px;">℃</view>
  482. <view class="control_item_right" style="top: -3px" @click="addTempSettingFirst(1)">+</view>
  483. </view>
  484. </view>
  485. <view class="control_item" style="width: 100%;background: white;height: 90rpx" v-if="!editTempSettingFirst">
  486. <view class="control_item_detail">
  487. <view class="control_item_left" style="left:22%;top:-41rpx" @click="subTempSettingFirst(1)">-</view>
  488. <view class="control_item_center" style="top:-2px;left: 40%;">
  489. <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" @change="propChange(1)" @focus="propFocus(1)" @confirm="propBlur(7)" @blur="propBlur(7)" v-model="currentTemperature"/>
  490. </view>
  491. <view class="control_item_center_unit" style="; font-size: 12px;
  492. left: 37vw;
  493. top: 13px;">℃</view>
  494. <view class="control_item_right" style="top: -3px" @click="addTempSettingFirst(1)">+</view>
  495. </view>
  496. </view>
  497. <view class="control_item" style="width: 100%;background: white;height: 90rpx" v-if="!editTimeSettingFirst">
  498. <view class="control_item_detail">
  499. <view class="control_item_left" style="left:22%;top:-41rpx" @click="subTimeFirst(1)">-</view>
  500. <view class="control_item_center" style="top:-2px;left: 40%;">
  501. <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" v-model="leftJianyaoTime"/>
  502. </view>
  503. <view class="control_item_center_unit" style="; font-size: 12px;
  504. left: 37vw;
  505. top: 13px;">min</view>
  506. <view class="control_item_right" style="top: -3px" @click="addTimeFirst(1)">+</view>
  507. </view>
  508. </view>
  509. <view class="control_item" style="width: 100%;background: white;height: 90rpx" v-if="editTimeSettingFirst">
  510. <view class="control_item_detail">
  511. <view class="control_item_left" style="left:22%;top:-41rpx" @click="subTimeFirst(1)">-</view>
  512. <view class="control_item_center" style="top:-2px;left: 40%;">
  513. <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" @change="propChange(1)" @focus="propFocus(1)" @confirm="propBlur(7)" @blur="propBlur(7)" v-model="timeSettingFirst"/>
  514. </view>
  515. <view class="control_item_center_unit" style="; font-size: 12px;
  516. left: 37vw;
  517. top: 13px;">min</view>
  518. <view class="control_item_right" style="top: -3px" @click="addTimeFirst(1)">+</view>
  519. </view>
  520. </view>
  521. </view>
  522. </view>
  523. <view v-if="statusHandler.type == 4">
  524. <view class="control_item" style="width: 100%;background: white;height: 90rpx" v-if="editTempSettingFirst">
  525. <view class="control_item_detail">
  526. <view class="control_item_left" style="left:22%;top:-41rpx" @click="subTempSettingFirst(1)">-</view>
  527. <view class="control_item_center" style="top:-2px;left: 40%;">
  528. <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" v-model="tempSettingFirst"/>
  529. </view>
  530. <view class="control_item_center_unit" style="; font-size: 12px;
  531. left: 37vw;
  532. top: 13px;">℃</view>
  533. <view class="control_item_right" style="top: -3px" @click="addTempSettingFirst(1)">+</view>
  534. </view>
  535. </view>
  536. <view class="control_item" style="width: 100%;background: white;height: 90rpx" v-if="!editTempSettingFirst">
  537. <view class="control_item_detail">
  538. <view class="control_item_left" style="left:22%;top:-41rpx" @click="subTempSettingFirst(1)">-</view>
  539. <view class="control_item_center" style="top:-2px;left: 40%;">
  540. <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" @change="propChange(1)" @focus="propFocus(1)" @confirm="propBlur(7)" @blur="propBlur(7)" v-model="currentTempSettingFirst"/>
  541. </view>
  542. <view class="control_item_center_unit" style="; font-size: 12px;
  543. left: 37vw;
  544. top: 13px;">℃</view>
  545. <view class="control_item_right" style="top: -3px" @click="addTempSettingFirst(1)">+</view>
  546. </view>
  547. </view>
  548. <view class="control_item" style="width: 100%;background: white;height: 90rpx" v-if="!editTimeSettingFirst">
  549. <view class="control_item_detail">
  550. <view class="control_item_left" style="left:22%;top:-41rpx" @click="subTimeFirst(1)">-</view>
  551. <view class="control_item_center" style="top:-2px;left: 40%;">
  552. <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" v-model="currentTimeSettingFirst"/>
  553. </view>
  554. <view class="control_item_center_unit" style="; font-size: 12px;
  555. left: 37vw;
  556. top: 13px;">min</view>
  557. <view class="control_item_right" style="top: -3px" @click="addTimeFirst(1)">+</view>
  558. </view>
  559. </view>
  560. <view class="control_item" style="width: 100%;background: white;height: 90rpx" v-if="editTimeSettingFirst">
  561. <view class="control_item_detail">
  562. <view class="control_item_left" style="left:22%;top:-41rpx" @click="subTimeFirst(1)">-</view>
  563. <view class="control_item_center" style="top:-2px;left: 40%;">
  564. <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" @change="propChange(1)" @focus="propFocus(1)" @confirm="propBlur(7)" @blur="propBlur(7)" v-model="currentTempSettingFirst"/>
  565. </view>
  566. <view class="control_item_center_unit" style="; font-size: 12px;
  567. left: 37vw;
  568. top: 13px;">min</view>
  569. <view class="control_item_right" style="top: -3px" @click="addTimeFirst(1)">+</view>
  570. </view>
  571. </view>
  572. </view>
  573. <view v-if="statusHandler.type == 5">
  574. <view v-if="secondJianyaoMode == 10">
  575. <view class="control_item" style="width: 100%;background: white;height: 90rpx" v-if="wenduSetting">
  576. <view class="control_item_detail">
  577. <view class="control_item_left" style="left:22%;top:-41rpx" @click="subTemperature(1)">-</view>
  578. <view class="control_item_center" style="top:-2px;left: 40%;">
  579. <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" @confirm="propBlur(13)" @blur="propBlur(13)" v-model="FirstTemp"></u-input>
  580. </view>
  581. <view class="control_item_center_unit" style="; font-size: 12px;
  582. left: 37vw;
  583. top: 13px;">℃</view>
  584. <view class="control_item_right" style="top: -3px" @click="addTemperature(1)">+</view>
  585. </view>
  586. </view>
  587. <view class="control_item" style="width: 100%;background: white;height: 90rpx" v-if="!wenduSetting">
  588. <view class="control_item_detail">
  589. <view class="control_item_left" style="left:22%;top:-41rpx" @click="subTemperature(1)">-</view>
  590. <view class="control_item_center" style="top:-2px;left: 40%;">
  591. <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" @change="propChange(1)" @focus="this.wenduSetting = true" v-model="currentTemperature"/>
  592. </view>
  593. <view class="control_item_center_unit" style="; font-size: 12px;
  594. left: 37vw;
  595. top: 13px;">℃</view>
  596. <view class="control_item_right" style="top: -3px" @click="addTemperature(1)">+</view>
  597. </view>
  598. </view>
  599. <view class="control_item" style="width: 100%;background: white;height: 90rpx" v-if="wenhuoTimeDlgShow">
  600. <view class="control_item_detail">
  601. <view class="control_item_left" style="left:22%;top:-41rpx" @click="subSecondTime(1)">-</view>
  602. <view class="control_item_center" style="top:-2px;left: 40%;">
  603. <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" v-model="SecondTime"/>
  604. </view>
  605. <view class="control_item_center_unit" style="; font-size: 12px;
  606. left: 37vw;
  607. top: 13px;">min</view>
  608. <view class="control_item_right" style="top: -3px" @click="addSecondTime(1)">+</view>
  609. </view>
  610. </view>
  611. <view class="control_item" style="width: 100%;background: white;height: 90rpx" v-if="!wenhuoTimeDlgShow">
  612. <view class="control_item_detail">
  613. <view class="control_item_left" style="left:22%;top:-41rpx" @click="subSecondTime(1)">-</view>
  614. <view class="control_item_center" style="top:-2px;left: 40%;">
  615. <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" @change="propChange(1)" @focus="this.wenhuoTimeDlgShow = true" @confirm="propBlur(12)" @blur="propBlur(12)" v-model="leftJianyaoTime"></u-input>
  616. </view>
  617. <view class="control_item_center_unit" style="; font-size: 12px;
  618. left: 37vw;
  619. top: 13px;">min</view>
  620. <view class="control_item_right" style="top: -3px" @click="addSecondTime(1)">+</view>
  621. </view>
  622. </view>
  623. </view>
  624. <view v-else-if="secondJianyaoMode == 5">
  625. <view class="control_item" style="width: 100%;background: white;height: 90rpx" v-if="wenduSetting">
  626. <view class="control_item_detail">
  627. <view class="control_item_left" style="left:22%;top:-41rpx" @click="subTemperature(1)">-</view>
  628. <view class="control_item_center" style="top:-2px;left: 40%;">
  629. <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" @change="propChange(1)" @focus="propFocus(1)" @confirm="propBlur(1)" @blur="propBlur(1)" v-model="FirstTemp"></u-input>
  630. </view>
  631. <view class="control_item_center_unit" style="; font-size: 12px;
  632. left: 37vw;
  633. top: 13px;">℃</view>
  634. <view class="control_item_right" style="top: -3px" @click="addTemperature(1)">+</view>
  635. </view>
  636. </view>
  637. <view class="control_item" style="width: 100%;background: white;height: 90rpx" v-if="!wenduSetting">
  638. <view class="control_item_detail">
  639. <view class="control_item_left" style="left:22%;top:-41rpx" @click="subTemperature(1)">-</view>
  640. <view class="control_item_center" style="top:-2px;left: 40%;">
  641. <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" v-model="currentTemperature"/>
  642. </view>
  643. <view class="control_item_center_unit" style="; font-size: 12px;
  644. left: 37vw;
  645. top: 13px;">℃</view>
  646. <view class="control_item_right" style="top: -3px" @click="addTemperature(1)">+</view>
  647. </view>
  648. </view>
  649. <view class="control_item" style="width: 100%;background: white;height: 90rpx" v-if="wenhuoTimeDlgShow">
  650. <view class="control_item_detail">
  651. <view class="control_item_left" style="left:22%;top:-41rpx" @click="subTemperatureTime(1)">-</view>
  652. <view class="control_item_center" style="top:-2px;left: 40%;">
  653. <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" v-model="FirstTime"/>
  654. </view>
  655. <view class="control_item_center_unit" style="; font-size: 12px;
  656. left: 37vw;
  657. top: 13px;">min</view>
  658. <view class="control_item_right" style="top: -3px" @click="addTemperatureTime(1)">+</view>
  659. </view>
  660. </view>
  661. <view class="control_item" style="width: 100%;background: white;height: 90rpx" v-if="!wenhuoTimeDlgShow">
  662. <view class="control_item_detail">
  663. <view class="control_item_left" style="left:22%;top:-41rpx" @click="subTemperatureTime(1)">-</view>
  664. <view class="control_item_center" style="top:-2px;left: 40%;">
  665. <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" @change="propChange(1)" @focus="propFocus(2)" @confirm="propBlur(2)" @blur="propBlur(2)" v-model="leftJianyaoTime"></u-input>
  666. </view>
  667. <view class="control_item_center_unit" style="; font-size: 12px;
  668. left: 37vw;
  669. top: 13px;">min</view>
  670. <view class="control_item_right" style="top: -3px" @click="addTemperatureTime(1)">+</view>
  671. </view>
  672. </view>
  673. </view>
  674. <view v-else-if="firstJianyaoMode == 5">
  675. <view class="control_item" style="width: 100%;background: white;height: 90rpx" v-if="wenduSetting">
  676. <view class="control_item_detail">
  677. <view class="control_item_left" style="left:22%;top:-41rpx" @click="subTemperature(4)">-</view>
  678. <view class="control_item_center" style="top:-2px;left: 40%;">
  679. <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" @change="propChange(1)" @focus="propFocus(1)" @confirm="propBlur(1)" @blur="propBlur(1)" v-model="temperature"></u-input>
  680. </view>
  681. <view class="control_item_center_unit" style="; font-size: 12px;
  682. left: 37vw;
  683. top: 13px;">℃</view>
  684. <view class="control_item_right" style="top: -3px" @click="addTemperature(4)">+</view>
  685. </view>
  686. </view>
  687. <view class="control_item" style="width: 100%;background: white;height: 90rpx" v-if="!wenduSetting">
  688. <view class="control_item_detail">
  689. <view class="control_item_left" style="left:22%;top:-41rpx" @click="subTemperature(5)">-</view>
  690. <view class="control_item_center" style="top:-2px;left: 40%;">
  691. <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" v-model="currentTemperature"/>
  692. </view>
  693. <view class="control_item_center_unit" style="; font-size: 12px;
  694. left: 37vw;
  695. top: 13px;">℃</view>
  696. <view class="control_item_right" style="top: -3px" @click="addTemperature(5)">+</view>
  697. </view>
  698. </view>
  699. <view class="control_item" style="width: 100%;background: white;height: 90rpx" v-if="wenhuoTimeDlgShow">
  700. <view class="control_item_detail">
  701. <view class="control_item_left" style="left:22%;top:-41rpx" @click="subTemperatureTime(1)">-</view>
  702. <view class="control_item_center" style="top:-2px;left: 40%;">
  703. <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" v-model="temperatureTime"/>
  704. </view>
  705. <view class="control_item_center_unit" style="; font-size: 12px;
  706. left: 37vw;
  707. top: 13px;">min</view>
  708. <view class="control_item_right" style="top: -3px" @click="addTemperatureTime(1)">+</view>
  709. </view>
  710. </view>
  711. <view class="control_item" style="width: 100%;background: white;height: 90rpx" v-if="!wenhuoTimeDlgShow">
  712. <view class="control_item_detail">
  713. <view class="control_item_left" style="left:22%;top:-41rpx" @click="subTemperatureTime(1)">-</view>
  714. <view class="control_item_center" style="top:-2px;left: 40%;">
  715. <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" @change="propChange(1)" @focus="propFocus(2)" @confirm="propBlur(2)" @blur="propBlur(2)" v-model="leftJianyaoTime"></u-input>
  716. </view>
  717. <view class="control_item_center_unit" style="; font-size: 12px;
  718. left: 37vw;
  719. top: 13px;">min</view>
  720. <view class="control_item_right" style="top: -3px" @click="addTemperatureTime(1)">+</view>
  721. </view>
  722. </view>
  723. </view>
  724. <view v-else>
  725. <view class="control_item" style="width: 100%;background: white;height: 90rpx" v-if="wenduSetting">
  726. <view class="control_item_detail">
  727. <view class="control_item_left" style="left:22%;top:-41rpx" @click="subTemperature(1)">-</view>
  728. <view class="control_item_center" style="top:-2px;left: 40%;">
  729. <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" @change="propChange(1)" @focus="propFocus(1)" @confirm="propBlur(1)" @blur="propBlur(1)" v-model="temperature"></u-input>
  730. </view>
  731. <view class="control_item_center_unit" style="; font-size: 12px;
  732. left: 37vw;
  733. top: 13px;">℃</view>
  734. <view class="control_item_right" style="top: -3px" @click="addTemperature(1)">+</view>
  735. </view>
  736. </view>
  737. <view class="control_item" style="width: 100%;background: white;height: 90rpx" v-if="!wenduSetting">
  738. <view class="control_item_detail">
  739. <view class="control_item_left" style="left:22%;top:-41rpx" @click="subTemperature(1)">-</view>
  740. <view class="control_item_center" style="top:-2px;left: 40%;">
  741. <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" @confirm="propBlur(1)" @blur="propBlur(1)" v-model="currentTemperature"/>
  742. </view>
  743. <view class="control_item_center_unit" style="; font-size: 12px;
  744. left: 37vw;
  745. top: 13px;">℃</view>
  746. <view class="control_item_right" style="top: -3px" @click="addTemperature(1)">+</view>
  747. </view>
  748. </view>
  749. <view class="control_item" style="width: 100%;background: white;height: 90rpx" v-if="wenhuoTimeDlgShow">
  750. <view class="control_item_detail">
  751. <view class="control_item_left" style="left:22%;top:-41rpx" @click="subTemperatureTime(1)">-</view>
  752. <view class="control_item_center" style="top:-2px;left: 40%;">
  753. <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" v-model="FirstTime"/>
  754. </view>
  755. <view class="control_item_center_unit" style="; font-size: 12px;
  756. left: 37vw;
  757. top: 13px;">min</view>
  758. <view class="control_item_right" style="top: -3px" @click="addTemperatureTime(1)">+</view>
  759. </view>
  760. </view>
  761. <view class="control_item" style="width: 100%;background: white;height: 90rpx" v-if="!wenhuoTimeDlgShow">
  762. <view class="control_item_detail">
  763. <view class="control_item_left" style="left:22%;top:-41rpx" @click="subTemperatureTime(1)">-</view>
  764. <view class="control_item_center" style="top:-2px;left: 40%;">
  765. <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" @change="propChange(0)" @focus="propFocus(0)" @confirm="propBlur(16)" @blur="propBlur(16)" v-model="leftJianyaoTime"></u-input>
  766. </view>
  767. <view class="control_item_center_unit" style="; font-size: 12px;
  768. left: 37vw;
  769. top: 13px;">min</view>
  770. <view class="control_item_right" style="top: -3px" @click="addTemperatureTime(1)">+</view>
  771. </view>
  772. </view>
  773. </view>
  774. </view>
  775. <view v-if="statusHandler.type == 6">
  776. <view class="control_item" style="width: 100%;background: white;height: 90rpx" v-if="wenduSetting">
  777. <view class="control_item_detail">
  778. <view class="control_item_left" style="left:22%;top:-41rpx" @click="subTemperature(1)">-</view>
  779. <view class="control_item_center" style="top:-2px;left: 40%;">
  780. <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" @change="propChange(1)" @focus="propFocus(1)" @confirm="propBlur(1)" @blur="propBlur(1)" v-model="temperature"></u-input>
  781. </view>
  782. <view class="control_item_center_unit" style="; font-size: 12px;
  783. left: 37vw;
  784. top: 13px;">℃</view>
  785. <view class="control_item_right" style="top: -3px" @click="addTemperature(1)">+</view>
  786. </view>
  787. </view>
  788. <view class="control_item" style="width: 100%;background: white;height: 90rpx" v-if="!wenduSetting">
  789. <view class="control_item_detail">
  790. <view class="control_item_left" style="left:22%;top:-41rpx" @click="subTemperature(1)">-</view>
  791. <view class="control_item_center" style="top:-2px;left: 40%;">
  792. <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" v-model="currentTemperature"/>
  793. </view>
  794. <view class="control_item_center_unit" style="; font-size: 12px;
  795. left: 37vw;
  796. top: 13px;">℃</view>
  797. <view class="control_item_right" style="top: -3px" @click="addTemperature(1)">+</view>
  798. </view>
  799. </view>
  800. <view class="control_item" style="width: 100%;background: white;height: 90rpx" v-if="editTimeSettingSecond">
  801. <view class="control_item_detail">
  802. <view class="control_item_left" style="left:22%;top:-41rpx" @click="subTimeSecond(1)">-</view>
  803. <view class="control_item_center" style="top:-2px;left: 40%;">
  804. <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" @change="propChange(1)" @focus="propFocus(1)" @confirm="propBlur(7)" @blur="propBlur(7)" v-model="timeSettingSecond"></u-input>
  805. </view>
  806. <view class="control_item_center_unit" style="; font-size: 12px;
  807. left: 37vw;
  808. top: 13px;">min</view>
  809. <view class="control_item_right" style="top: -3px" @click="addTimeSecond(1)">+</view>
  810. </view>
  811. </view>
  812. <view class="control_item" style="width: 100%;background: white;height: 90rpx" v-if="!editTimeSettingSecond">
  813. <view class="control_item_detail">
  814. <view class="control_item_left" style="left:22%;top:-41rpx" @click="subTimeSecond(1)">-</view>
  815. <view class="control_item_center" style="top:-2px;left: 40%;">
  816. <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" v-model="leftJianyaoTime"></u-input>
  817. </view>
  818. <view class="control_item_center_unit" style="; font-size: 12px;
  819. left: 37vw;
  820. top: 13px;">min</view>
  821. <view class="control_item_right" style="top: -3px" @click="addTimeSecond(1)">+</view>
  822. </view>
  823. </view>
  824. </view>
  825. <view v-if="statusHandler.type == 9">
  826. <!-- <view class="control_item" style="width: 100%;background: white;height: 90rpx" v-if="editSecondAddWaterTime">-->
  827. <!-- <view class="control_item_detail">-->
  828. <!-- <view class="control_item_left" style="left:22%;top:-41rpx" @click="subErqibushui(1)">-</view>-->
  829. <!-- <view class="control_item_center" style="top:-2px;left: 40%;">-->
  830. <!-- <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" v-model="secondAddWaterTime"></u-input>-->
  831. <!-- </view>-->
  832. <!-- <view class="control_item_center_unit" style="; font-size: 12px;-->
  833. <!-- left: 37vw;-->
  834. <!-- top: 13px;">s</view>-->
  835. <!-- <view class="control_item_right" style="top: -3px" @click="addErqibushui(1)">+</view>-->
  836. <!-- </view>-->
  837. <!-- </view>-->
  838. <view class="control_item" style="width: 100%;background: white;height: 90rpx">
  839. <view class="control_item_detail">
  840. <!-- <view class="control_item_left" style="left:22%;top:-41rpx" @click="subErqibushui(1)">-</view>-->
  841. <view class="control_item_center" style="top:-2px;left: 40%;">
  842. <u-input fontSize="20px" customStyle="width:150rpx;border:0px;font-size:20px" disabledColor="white" v-model="currentSecondAddWaterTime"></u-input>
  843. </view>
  844. <view class="control_item_center_unit" style="; font-size: 12px;
  845. left: 37vw;
  846. top: 13px;">s</view>
  847. <!-- <view class="control_item_right" style="top: -3px" @click="addErqibushui(1)">+</view>-->
  848. </view>
  849. </view>
  850. <view style="font-size: 10px;color: red;text-align: center">可调范围10~20</view>
  851. </view>
  852. <view style=" text-align: center;font-size: 18px;font-weight: 500;margin-top: 7px;">
  853. <view v-for="content in statusHandler.desc">{{ content }}</view>
  854. <view>{{ content }}</view>
  855. </view>
  856. <view v-if="statusHandler.type == 4">
  857. <view style="position: relative" @click="doAction(3)">
  858. <view style="background: white;height: 60px;width: 90px;position: relative;border-radius: 10px;left: 33%;top: 10px;">
  859. <view style="height: 30%;width: 20%; position: relative;left: 40%;top: 20%;">
  860. <image :src="imgUrl+'/img20250528/qidong_off.png'" style="width: 100%;height: 100%"/>
  861. </view>
  862. <view style=" position: relative;left: 37%;top: 29%; font-size: 12px;">启动</view>
  863. </view>
  864. </view>
  865. </view>
  866. <view v-else>
  867. <view v-if="statusHandler.type !=9">
  868. <view style="position: relative" @click="doAction(1)" v-if="pauseStatus == 0">
  869. <view style="background: white;height: 60px;width: 90px;position: relative;border-radius: 10px;left: 33%;top: 10px;">
  870. <view style="height: 30%;width: 20%; position: relative;left: 40%;top: 20%;">
  871. <image :src="imgUrl+'/img20250528/pause.png'" style="width: 100%;height: 100%"/>
  872. </view>
  873. <view style=" position: relative;left: 37%;top: 29%; font-size: 12px;">暂停</view>
  874. </view>
  875. </view>
  876. <view style="position: relative" @click="doAction(0)" v-if="pauseStatus == 1">
  877. <view style="background: white;height: 60px;width: 90px;position: relative;border-radius: 10px;left: 33%;top: 10px;">
  878. <view style="height: 30%;width: 20%; position: relative;left: 40%;top: 20%;">
  879. <image :src="imgUrl+'/img20250528/qidong_off.png'" style="width: 100%;height: 100%"/>
  880. </view>
  881. <view style=" position: relative;left: 37%;top: 29%; font-size: 12px;">启动</view>
  882. </view>
  883. </view>
  884. </view>
  885. </view>
  886. </view>
  887. </u-popup>
  888. <u-popup :show="false" @close="closePop" mode="center" bgColor="transparent" :closeable="true" :round="10">
  889. <view style="position: relative;width: 500rpx;height:300rpx;background: rgb(240,240,240);padding-top:30px">
  890. <view class="control_item" style="width: 100%" v-if="fengbianDlgShow">
  891. <view class="control_item_detail">
  892. <view class="control_item_left" @click="subEdegTemperature(1)">-</view>
  893. <view class="control_item_center">
  894. <u-input customStyle="width:150rpx;border:0px;" disabledColor="white" @change="changeEdegTemperature" v-model="setEdegTemperature"></u-input>
  895. </view>
  896. <view class="control_item_center_unit" :style="unitFixedStyle1">℃</view>
  897. <view class="control_item_right" @click="addEdegTemperature(1)">+</view>
  898. </view>
  899. <view class="control_item_title">
  900. 封边温度设置
  901. </view>
  902. </view>
  903. </view>
  904. </u-popup>
  905. <u-popup :show="planPopDlg" @close="closePlanPop" mode="center" :closeable="true" :round="10">
  906. <view style="position: relative;width: 400rpx;background: none;padding:40rpx;">
  907. <view class="control_item" style="width: 100%">
  908. <image :src="imgUrl+'/detail/bg_mid.png'" style="width: 100%;height:100%;position: absolute;top:0px;"/>
  909. <view class="control_item_detail">
  910. <view class="control_item_left" @click="subPlanTime(1)" style="left: 18%;">-</view>
  911. <view class="control_item_center">
  912. <view style="position: absolute">
  913. <u-input customStyle="width:150rpx;border:0px;" disabledColor="white" v-model="planTime"></u-input>
  914. </view>
  915. </view>
  916. <view class="control_item_center_unit" :style="unitFixedStyle">min</view>
  917. <view class="control_item_right" style="left: 80%;" @click="addPlanTime(1)">+</view>
  918. </view>
  919. <view class="control_item_title">
  920. 预约时间
  921. </view>
  922. </view>
  923. <view class="control_item" style="width: 100%">
  924. <image :src="imgUrl+'/detail/bg_mid.png'" style="width: 100%;height:100%;position: absolute;top:0px;"/>
  925. <view class="control_item_detail">
  926. <view class="control_item_left" @click="subTemperatureTime()" style="left: 18%;">-</view>
  927. <view class="control_item_center">
  928. <view style="position: absolute">
  929. <u-input customStyle="width:150rpx;border:0px;" disabledColor="white" @change="changeTemperatureTime()" v-model="temperatureTime"></u-input>
  930. </view>
  931. </view>
  932. <view class="control_item_center_unit" :style="unitFixedStyle">min</view>
  933. <view class="control_item_right" @click="addTemperatureTime()" style="left: 80%;">+</view>
  934. </view>
  935. <view class="control_item_title">
  936. 时间设置
  937. </view>
  938. </view>
  939. <view>
  940. <button style="background: white;" @click="plan">确认</button>
  941. </view>
  942. </view>
  943. </u-popup>
  944. <u-popup :show="erqibushuiDlg" @close="closeErqibushuiPop" mode="center" :closeable="true" :round="10">
  945. <view style="position: relative;width: 400rpx;background: none;padding:40rpx;">
  946. <view class="control_item" style="width: 100%" >
  947. <image :src="imgUrl+'/detail/bg_mid.png'" style="width: 100%;height:100%;position: absolute;top:0px;"/>
  948. <view class="control_item_detail">
  949. <view class="control_item_left" @click="subErqibushui(1)" style="left: 18%;">-</view>
  950. <view class="control_item_center">
  951. <view style="position: absolute">
  952. <u-input customStyle="width:150rpx;border:0px;" disabledColor="white" v-model="secondAddWaterTime"></u-input>
  953. </view>
  954. </view>
  955. <view class="control_item_center_unit" :style="unitFixedStyle">s</view>
  956. <view class="control_item_right" style="left: 80%;" @click="addErqibushui(1)">+</view>
  957. </view>
  958. <view class="control_item_title">
  959. 二煎补水时间
  960. </view>
  961. </view>
  962. <!-- <view class="control_item" style="width: 100%" v-if="!editSecondAddWaterTime" >-->
  963. <!-- <image :src="imgUrl+'/detail/bg_mid.png'" style="width: 100%;height:100%;position: absolute;top:0px;"/>-->
  964. <!-- <view class="control_item_detail">-->
  965. <!-- <view class="control_item_left" @click="subErqibushui(1)" style="left: 18%;">-</view>-->
  966. <!-- <view class="control_item_center">-->
  967. <!-- <view style="position: absolute">-->
  968. <!-- <u-input customStyle="width:150rpx;border:0px;" disabledColor="white" v-model="currentSecondAddWaterTime"></u-input>-->
  969. <!-- </view>-->
  970. <!-- </view>-->
  971. <!-- <view class="control_item_center_unit" :style="unitFixedStyle">s</view>-->
  972. <!-- <view class="control_item_right" style="left: 80%;" @click="addErqibushui(1)">+</view>-->
  973. <!-- </view>-->
  974. <!-- <view class="control_item_title">-->
  975. <!-- 二煎补水剩余时间-->
  976. <!-- </view>-->
  977. <!-- </view>-->
  978. </view>
  979. </u-popup>
  980. <!-- 预约框-->
  981. <u-popup :show="yuyueIngPop" @close="closeYuyueIngPop" mode="center" :closeable="true" :round="10">
  982. <view style="position: relative;width: 400rpx;background: none;;padding:30rpx;padding-top:60rpx;">
  983. <view class="control_item" style="width: 100%">
  984. <image :src="imgUrl+'/detail/bg_mid.png'" style="width: 100%;height:100%;position: absolute;top:0px;"/>
  985. <view class="control_item_detail">
  986. <view class="control_item_center">
  987. <u-input customStyle="width:150rpx;border:0px;padding:0px" disabledColor="white" :value="leftAppointmentTime"></u-input>
  988. </view>
  989. <view class="control_item_center_unit" :style="unitFixedStyle">℃</view>
  990. </view>
  991. <view class="control_item_title">
  992. 剩余时间
  993. </view>
  994. </view>
  995. <view>
  996. <button style="background: white;" @click="cancelPlan">取消</button>
  997. </view>
  998. </view>
  999. </u-popup>
  1000. <u-popup :show="planIngPopDlg" @close="closePlanIngPop" mode="center" :closeable="true" :round="10">
  1001. <view style="position: relative;width: 400rpx;background: none;padding:40rpx;">
  1002. <view class="control_item" style="width: 100%">
  1003. <image :src="imgUrl+'/detail/bg_mid.png'" style="width: 100%;height:100%;position: absolute;top:0px;"/>
  1004. <view class="control_item_detail" style="width: 100%; padding: 40rpx;margin-bottom:10rpx;">
  1005. <u-line-progress :percentage="step" activeColor="#50ACFF"></u-line-progress>
  1006. </view>
  1007. <view class="control_item_title" v-if="leftAppointmentTime>0">
  1008. 预约煎药中,倒计时{{leftAppointmentTime}}分钟
  1009. </view>
  1010. <view class="control_item_title" v-else>
  1011. <view v-if="leftJianyaoTime>0">
  1012. 正在熬制,请稍等
  1013. </view>
  1014. <view v-else>
  1015. 煎药完成
  1016. </view>
  1017. </view>
  1018. </view>
  1019. <view class="control_item" style="width: 100%">
  1020. <image :src="imgUrl+'/detail/bg_mid.png'" style="width: 100%;height:100%;position: absolute;top:0px;"/>
  1021. <view class="control_item_detail">
  1022. <view class="control_item_center">
  1023. <u-input customStyle="width:150rpx;border:0px;" disabledColor="white" :value="currentTemperature"></u-input>
  1024. </view>
  1025. <view class="control_item_center_unit" :style="unitFixedStyle">℃</view>
  1026. </view>
  1027. <view class="control_item_title">
  1028. 当前温度
  1029. </view>
  1030. </view>
  1031. <view class="control_item" style="width: 100%">
  1032. <image :src="imgUrl+'/detail/bg_mid.png'" style="width: 100%;height:100%;position: absolute;top:0px;"/>
  1033. <view class="control_item_detail">
  1034. <view class="control_item_center">
  1035. <u-input customStyle="width:150rpx;border:0px;" disabledColor="white" :value="leftJianyaoTime"></u-input>
  1036. </view>
  1037. <view class="control_item_center_unit" :style="unitFixedStyle">min</view>
  1038. </view>
  1039. <view class="control_item_title">
  1040. 文火倒计时
  1041. </view>
  1042. </view>
  1043. <!-- <view>-->
  1044. <!-- <button style="background: white;" @click="cancelPlan">暂停</button>-->
  1045. <!-- </view>-->
  1046. </view>
  1047. </u-popup>
  1048. <uni-drawer ref="showLeft" :width="320" :maskClick="true" mode="right" @change="change($event,'showLeft')">
  1049. <scroll-view style="height: 88%;padding:20% 0%;" scroll-y="true">
  1050. <view style="text-align:center">设置</view>
  1051. <view>
  1052. <!-- <view class="prop-item">-->
  1053. <!-- <view class="prop-item-image">-->
  1054. <!-- <image :src="imgUrl+'/setting/net.png'" style="width: 100%;height:100%;"/>-->
  1055. <!-- </view>-->
  1056. <!-- <view class="prop-item-left">网络连接</view>-->
  1057. <!-- <view class="prop-item-right">-->
  1058. <!-- <view v-if="deviceInfo.status == 3">-->
  1059. <!-- 已连接-->
  1060. <!-- </view>-->
  1061. <!-- <view v-else>-->
  1062. <!-- 未连接-->
  1063. <!--&lt;!&ndash; <uni-icons type="forward" size="16"></uni-icons>&ndash;&gt;-->
  1064. <!-- </view>-->
  1065. <!-- </view>-->
  1066. <!-- </view>-->
  1067. <view class="prop-item" @click="showJiaozhunProp" v-if="firstTab">
  1068. <view class="prop-item-image">
  1069. <image :src="imgUrl+'/setting/oper_temp.png'" style="width: 100%;height:100%;"/>
  1070. </view>
  1071. <view class="prop-item-left">温度校准</view>
  1072. <view class="prop-item-right" >
  1073. {{jiaozhunTemp}}℃<uni-icons type="forward" size="16"></uni-icons>
  1074. </view>
  1075. </view>
  1076. <view class="prop-item" @click="toPlan" v-if="firstTab">
  1077. <view class="prop-item-image" style="width: 60rpx;
  1078. height: 60rpx;
  1079. bottom: 22rpx;
  1080. left: 26rpx;
  1081. }">
  1082. <image :src="imgUrl+'/setting/plan_oper.png?1'" style="width: 100%;height:100%;"/>
  1083. </view>
  1084. <view class="prop-item-left">预约</view>
  1085. <view class="prop-item-right" >
  1086. <uni-icons type="forward" size="16"></uni-icons>
  1087. </view>
  1088. </view>
  1089. <view class="prop-item" v-if="firstTab && boardType == 5">
  1090. <view class="prop-item-image">
  1091. <image :src="imgUrl+'/setting/current_icon6.png'" style="width: 100%;height:100%;"/>
  1092. </view>
  1093. <view class="prop-item-left">当前扭力</view>
  1094. <view class="prop-item-right" >
  1095. {{validCurrent}}
  1096. </view>
  1097. </view>
  1098. <view class="prop-item" @click="showLiuProp" v-if="firstTab && boardType == 5">
  1099. <view class="prop-item-image">
  1100. <image :src="imgUrl+'/setting/current_icon5.png'" style="width: 100%;height:100%;"/>
  1101. </view>
  1102. <view class="prop-item-left">扭力设置</view>
  1103. <view class="prop-item-right" >
  1104. {{turnCurrent}}<uni-icons type="forward" size="16"></uni-icons>
  1105. </view>
  1106. </view>
  1107. <view class="prop-item" @click="showWorkPicker" v-if="firstTab">
  1108. <view class="prop-item-image">
  1109. <image :src="imgUrl+'/setting/list.png'" style="width: 100%;height:100%;"/>
  1110. </view>
  1111. <view class="prop-item-left">工作模式</view>
  1112. <view class="prop-item-right" >
  1113. <view v-if="workMode == 1">
  1114. 1<uni-icons type="forward" size="16"></uni-icons>
  1115. </view>
  1116. <view v-if="workMode == 2">
  1117. 2<uni-icons type="forward" size="16"></uni-icons>
  1118. </view>
  1119. <view v-if="workMode == 3">
  1120. 3<uni-icons type="forward" size="16"></uni-icons>
  1121. </view>
  1122. </view>
  1123. </view>
  1124. <view class="prop-item">
  1125. <view class="prop-item-image">
  1126. <image :src="imgUrl+'/setting/no.png'" style="width: 100%;height:100%;"/>
  1127. </view>
  1128. <view class="prop-item-left">二维码编号</view>
  1129. <view class="prop-item-right">
  1130. <text class="text-right">{{deviceInfo.qrcodeId==null?"未绑定":deviceInfo.qrcodeId}}</text>
  1131. </view>
  1132. </view>
  1133. <view class="prop-item">
  1134. <view class="prop-item-image">
  1135. <image :src="imgUrl+'/setting/no.png'" style="width: 100%;height:100%;"/>
  1136. </view>
  1137. <view class="prop-item-left">设备编号</view>
  1138. <view class="prop-item-right">
  1139. <text class="text-right">{{deviceInfo.serialNumber}}</text>
  1140. </view>
  1141. </view>
  1142. <view class="prop-item" @click="skip(1)">
  1143. <view class="prop-item-image">
  1144. <image :src="imgUrl+'/setting/learn.png'" style="width: 100%;height:100%;"/>
  1145. </view>
  1146. <view class="prop-item-left">使用教程</view>
  1147. <view class="prop-item-right" >
  1148. <uni-icons type="forward" size="16"></uni-icons>
  1149. </view>
  1150. </view>
  1151. <view class="prop-item" @click="skip(1)">
  1152. <view class="prop-item-image">
  1153. <image :src="imgUrl+'/setting/video.png'" style="width: 100%;height:100%;"/>
  1154. </view>
  1155. <view class="prop-item-left">维修视频</view>
  1156. <view class="prop-item-right" >
  1157. <uni-icons type="forward" size="16"></uni-icons>
  1158. </view>
  1159. </view>
  1160. <view class="prop-item" @click="getUpdateInfo">
  1161. <view class="prop-item-image">
  1162. <image :src="imgUrl+'/setting/upload.png'" style="width: 100%;height:100%;"/>
  1163. </view>
  1164. <view class="prop-item-left">在线升级</view>
  1165. <view class="prop-item-right" >
  1166. <uni-icons type="forward" size="16"></uni-icons>
  1167. </view>
  1168. </view>
  1169. <view class="prop-item" @click="skip(2)">
  1170. <view class="prop-item-image">
  1171. <image :src="imgUrl+'/setting/shou.png'" style="width: 100%;height:100%;"/>
  1172. </view>
  1173. <view class="prop-item-left">售后服务</view>
  1174. <view class="prop-item-right" >
  1175. <uni-icons type="forward" size="16"></uni-icons>
  1176. </view>
  1177. </view>
  1178. <view class="prop-item" @click="reset">
  1179. <view class="prop-item-image">
  1180. <image :src="imgUrl+'/setting/reset.png'" style="width: 100%;height:100%;"/>
  1181. </view>
  1182. <view class="prop-item-left">恢复出厂</view>
  1183. <view class="prop-item-right" >
  1184. <uni-icons type="forward" size="16"></uni-icons>
  1185. </view>
  1186. </view>
  1187. <view class="prop-item" @click="modifyName">
  1188. <view class="prop-item-image">
  1189. <image :src="imgUrl+'/setting/runinfo.png'" style="width: 100%;height:100%;"/>
  1190. </view>
  1191. <view class="prop-item-left">修改名称</view>
  1192. <view class="prop-item-right" >
  1193. <uni-icons type="forward" size="16"></uni-icons>
  1194. </view>
  1195. </view>
  1196. </view>
  1197. </scroll-view>
  1198. </uni-drawer>
  1199. <u-popup :show="jiaozhunPopDlg" @close="closejiaozhunPop" mode="center" :closeable="true" :round="10">
  1200. <view style="position: relative;width: 400rpx;background: none;padding:30rpx;padding-top:60rpx;">
  1201. <view class="control_item" style="width: 100%">
  1202. <image :src="imgUrl+'/detail/bg_mid.png'" style="width: 100%;height:100%;position: absolute;top:0px;"/>
  1203. <view class="control_item_detail">
  1204. <view class="control_item_left" @click="subJiaoZhunTemperature(1)" style="left: 18%;">-</view>
  1205. <view class="control_item_center">
  1206. <view style="position: absolute">
  1207. <u-input customStyle="width:150rpx;border:0px;" disabledColor="white" v-model="jiaozhunTemp_temp"></u-input>
  1208. </view>
  1209. </view>
  1210. <view class="control_item_center_unit" :style="unitFixedStyle">℃</view>
  1211. <view class="control_item_right" @click="addJiaoZhunTemperature(1)" style="left: 80%;">+</view>
  1212. </view>
  1213. <view class="control_item_title">
  1214. 校准温度
  1215. </view>
  1216. </view>
  1217. <view>
  1218. <button style="background: white;" @click="confirmJiaozhunTemp">确认</button>
  1219. </view>
  1220. </view>
  1221. </u-popup>
  1222. <u-popup :show="deviceYuyueIngPop" @close="closeDeviceYuyueIngPop" mode="center" :closeable="true" :round="10">
  1223. <view style="position: relative;width: 400rpx;background: none;padding:30rpx;padding-top:60rpx;">
  1224. <view class="control_item" style="width: 100%">
  1225. <image :src="imgUrl+'/detail/bg_mid.png'" style="width: 100%;height:100%;position: absolute;top:0px;"/>
  1226. <view class="control_item_detail">
  1227. <view class="control_item_center">
  1228. <u-input customStyle="width:150rpx;border:0px;padding:0px" disabledColor="white" :value="devicePlanInfo.minute"></u-input>
  1229. </view>
  1230. <view class="control_item_center_unit" :style="unitFixedStyle">分</view>
  1231. </view>
  1232. <view class="control_item_title">
  1233. 剩余时间
  1234. </view>
  1235. </view>
  1236. <view>
  1237. <button style="background: white;" @click="cancelDevicePlan">取消</button>
  1238. </view>
  1239. </view>
  1240. </u-popup>
  1241. <u-popup :show="devicePlanPopDlg" @close="closeDevicePlanPop" mode="center" :closeable="true" :round="10">
  1242. <view style="position: relative;width: 400rpx;background: none;padding:30rpx;padding-top:60rpx;">
  1243. <view class="control_item" style="width: 100%">
  1244. <image :src="imgUrl+'/detail/bg_mid.png'" style="width: 100%;height:100%;position: absolute;top:0px;"/>
  1245. <view class="control_item_detail">
  1246. <view class="control_item_left" @click="subDevicePlanTime(1)" style="left: 18%;">-</view>
  1247. <view class="control_item_center">
  1248. <view style="position: absolute">
  1249. <u-input customStyle="width:150rpx;border:0px;" disabledColor="white" v-model="devicePlanTime"></u-input>
  1250. </view>
  1251. </view>
  1252. <view class="control_item_center_unit" :style="unitFixedStyle">min</view>
  1253. <view class="control_item_right" style="left: 80%;" @click="addDevicePlanTime(1)">+</view>
  1254. </view>
  1255. <view class="control_item_title">
  1256. 预约时间
  1257. </view>
  1258. </view>
  1259. <view>
  1260. <button style="background: white;" @click="devicePlan">确认</button>
  1261. </view>
  1262. </view>
  1263. </u-popup>
  1264. <u-popup :show="liuzhuanPopDlg" @close="closeliuzhuanPop" mode="center" :closeable="true" :round="10">
  1265. <view style="position: relative;width: 400rpx;background: none;padding:30rpx;padding-top:60rpx;">
  1266. <view class="control_item" style="width: 100%">
  1267. <image :src="imgUrl+'/detail/bg_mid.png'" style="width: 100%;height:100%;position: absolute;top:0px;"/>
  1268. <view class="control_item_detail">
  1269. <view class="control_item_center">
  1270. <view style="position: absolute">
  1271. <u-input customStyle="width:150rpx;border:0px;" disabledColor="white" v-model="setTurnCurrent"></u-input>
  1272. </view>
  1273. </view>
  1274. <view class="control_item_center_unit" :style="unitFixedStyle">MA</view>
  1275. </view>
  1276. <view class="control_item_title">
  1277. 扭力
  1278. </view>
  1279. </view>
  1280. <view>
  1281. <button style="background: white;" @click="confirmLiuzhuannCurrent">确认</button>
  1282. </view>
  1283. </view>
  1284. </u-popup>
  1285. <u-popup :show="baowenPopDlg" @close="closeBaowenPopDlg" mode="center" :closeable="true" :round="10">
  1286. <view style="position: relative;width: 400rpx;background: none;padding:30rpx;padding-top:60rpx;">
  1287. <view class="control_item" style="width: 100%">
  1288. <image :src="imgUrl+'/detail/bg_mid.png'" style="width: 100%;height:100%;position: absolute;top:0px;"/>
  1289. <view class="control_item_detail">
  1290. <view class="control_item_left" @click="subBaowenTime(1)" style="left: 18%;">-</view>
  1291. <view class="control_item_center">
  1292. <view style="position: absolute">
  1293. <u-input customStyle="width:150rpx;border:0px;" disabledColor="white" v-model="baowenTime"></u-input>
  1294. </view>
  1295. </view>
  1296. <view class="control_item_center_unit" :style="unitFixedStyle">min</view>
  1297. <view class="control_item_right" style="left: 80%;" @click="addBaowenTime(1)">+</view>
  1298. </view>
  1299. <view class="control_item_title">
  1300. 保温时间
  1301. </view>
  1302. </view>
  1303. <view class="control_item" style="width: 100%">
  1304. <image :src="imgUrl+'/detail/bg_mid.png'" style="width: 100%;height:100%;position: absolute;top:0px;"/>
  1305. <view class="control_item_detail">
  1306. <view class="control_item_left" @click="subBaowenTemp(1)" style="left: 18%;">-</view>
  1307. <view class="control_item_center">
  1308. <view style="position: absolute">
  1309. <u-input customStyle="width:150rpx;border:0px;" disabledColor="white" v-model="baowenTemp"></u-input>
  1310. </view>
  1311. </view>
  1312. <view class="control_item_center_unit" :style="unitFixedStyle">℃</view>
  1313. <view class="control_item_right" style="left: 80%;" @click="addBaowenTemp(1)">+</view>
  1314. </view>
  1315. <view class="control_item_title">
  1316. 保温温度
  1317. </view>
  1318. </view>
  1319. <view>
  1320. <button style="background: white;" @click="doBaowenSeting" v-if="!hasBaowen">确认添加</button>
  1321. <button style="background: white;" @click="delBaowenSetting" v-if="hasBaowen">取消保温</button>
  1322. </view>
  1323. </view>
  1324. </u-popup>
  1325. <u-picker :show="showModelPicker" @cancel="closeModelPicker" @confirm="confirmMode" :columns="modeList" keyName="text"></u-picker>
  1326. <u-picker :show="showYaofangPicker" @cancel="closeYaofangPicker" @confirm="confirmYaofang" :columns="yaofangList" keyName="text"></u-picker>
  1327. </view>
  1328. </template>
  1329. <script>
  1330. import { getDetail,getDeviceStatus,cacheJsonThingsModel,reportError ,getDeviceRunTime,getLatestFirmware,bingDeviceDept,editDeviceName,getDevicePlan,addDevicePlan,delDevicePlan,saveBaowenSetting,getBaoWen,editBaowenSetting,cancelBaowen} from '@/api/device/device.js'
  1331. import config from '@/config'
  1332. import UPicker from "../../uni_modules/uview-ui/components/u-picker/u-picker";
  1333. import UImage from "../../uni_modules/uview-ui/components/u--image/u--image";
  1334. import UText from "../../uni_modules/uview-ui/components/u-text/u-text";
  1335. export default {
  1336. components: {UText, UImage, UPicker},
  1337. data(){
  1338. return {
  1339. SecondTime:0,
  1340. FirstTemp:0,
  1341. FirstTime:0,
  1342. lineProgreeStyle:"width:0%;background:#50ACFF;height: 100%;",
  1343. liuzhuanPopDlg:false,
  1344. turnPercent:1,
  1345. onlineStatus:false,
  1346. modeList:[[
  1347. {id:1,text:"1"},
  1348. {id:2,text:"2"},
  1349. {id:3,text:"3"},
  1350. ]],
  1351. yaofangList:[[
  1352. {id:0,text:"一般药方"},
  1353. {id:1,text:"解表药方"},
  1354. {id:2,text:"滋补药方"},
  1355. ]],
  1356. productSize:"",
  1357. productImage:"",
  1358. showModelPicker:false,
  1359. showYaofangPicker:false,
  1360. unitFixedStyle:"",
  1361. unitFixedStyle1:"",
  1362. planTime:0,
  1363. setSealingTemperature:160,
  1364. setEdegTemperature:160,
  1365. sealingTemperature:0,
  1366. edegTemperature:0,
  1367. hightTemperature:0,
  1368. currentTemperature:0,
  1369. temperatureTime:1,
  1370. temperature:0,
  1371. packageNumber:1,
  1372. packageVolume:50,
  1373. firstTab:true,
  1374. decoctControlStatus:false,
  1375. decoctControlOnOffStatus:false,
  1376. packageControlOnOffStatus:false,
  1377. subDecoctTabList:[
  1378. {name:'子煎药1'},
  1379. {name:'子煎药2'},
  1380. {name:'子煎药3'},
  1381. ],
  1382. DecoctControlStatus:false,
  1383. PackagControlStatus:false,
  1384. baozhuangTurn:false,
  1385. qitingTurn:false,
  1386. qingxiTurn:false,
  1387. subCurrent:0,
  1388. current:0,
  1389. inputStyle:{height:'44rpx','fontSize':'20rpx'},
  1390. modelKey:['PowerControl','LockControl'],
  1391. jianyaoKeys : ["SecondTime","TempSetting","TimeSetting","WaterVolume","SecondWaterVolume","AppointmentTime","TimeSetFirst","TimeSetSecond","SecondAddWaterTime","TempSetFirst","FirstTemp","FirstTime"],
  1392. baozhuangKeys:["SetSealTemp","SetBandingTemp","PackageQuantity","PackingVolume"],
  1393. power:{
  1394. loading:true,
  1395. value:0,
  1396. },
  1397. lock:{
  1398. loading:true,
  1399. value:0,
  1400. },
  1401. showTimeDlg:false,
  1402. showErrDlg:null,
  1403. errorMsg:"asdasdasdasd",
  1404. show:null,
  1405. value:"",
  1406. deviceInfo:{},
  1407. id:0,
  1408. summary:[
  1409. ],
  1410. tabs:[
  1411. {tabName:"煎药控制"},
  1412. {tabName:"包装控制"},
  1413. ],
  1414. activeName:0,
  1415. childId:0,
  1416. oneToMul:false,
  1417. inputProp:[],
  1418. watchProp:[],
  1419. columns:[],
  1420. location:{},
  1421. sysDept:null,
  1422. timeobj:{alltime:0,avgtime:0},
  1423. publishMsg:false,
  1424. checkTimer:null,
  1425. functions:[],
  1426. properties:[],
  1427. propMap:{},
  1428. jianyaoTimer:null,
  1429. baozhuangTimer:null,
  1430. editing:false,
  1431. workMode:2,
  1432. leftAppointmentTime:0,
  1433. leftJianyaoTime:0,
  1434. planEditTime:false,
  1435. editWaterVolume:false,
  1436. timeSettingFirst:0,
  1437. currentTimeSettingFirst:0,
  1438. timeSettingSecond:0,
  1439. currentTimeSettingSecond:0,
  1440. editTimeSettingFirst:false,
  1441. editTimeSettingSecond:false,
  1442. secondAddWaterTime:0,
  1443. editSecondAddWaterTime:false,
  1444. editSecondAddWaterTimeTimer:null,
  1445. currentSecondAddWaterTime:0,
  1446. imgUrl:"",
  1447. popDlg:false,
  1448. fengbianDlgShow:true,
  1449. fengkouDlgShow:false,
  1450. wenhuoTimeDlgShow:false,
  1451. planPopDlg:false,
  1452. erqibushuiDlg:false,
  1453. planIngPopDlg:false,
  1454. maxWidth:320,
  1455. jiaozhunTemp:0,//校准温度,
  1456. jiaozhunTemp_temp:0,//校准温度,
  1457. jiaozhunPopDlg:false,
  1458. step:0,
  1459. yuyueIngPop:false,
  1460. firmware:{},
  1461. jianyaoPopClose:true,
  1462. tabIndex:1,
  1463. appid:"wxfd7b1a0e03e9b7e9",
  1464. firstMachine:true,
  1465. secondMachine:false,
  1466. thirdMachine:false,
  1467. forthMachine:true,
  1468. deviceType:1,
  1469. tabActive:[true,false,false],
  1470. resetDuration:4000,
  1471. jianyaoWenduSetting:false,
  1472. jianyaoShijianSetting:false,
  1473. baozhuangFengbianSetting:false,
  1474. baozhuangFengkouSetting:false,
  1475. baozhuangRongLiangSetting:false,
  1476. baozhuangShuLIangSetting:false,
  1477. tempFengkouWendu:0,
  1478. tempFengBianWendu:0,
  1479. boardType:6,//板子类型
  1480. lineTimer:null,
  1481. validCurrent:0,//当前扭力
  1482. turnCurrent:0,//堵转电流值
  1483. setTurnCurrent:0,
  1484. pressTurn:0,
  1485. resetTurn:0,
  1486. drainageTurn:0,
  1487. canGetPrsValue:false,//可以接收挤压的动画
  1488. devicePlanInfo: {},//设备后台预约任务
  1489. devicePlanPopDlg:false,
  1490. deviceYuyueIngPop:false,
  1491. baowenPopDlg:false,
  1492. devicePlanTime:10,
  1493. boardStyle:"",
  1494. baowenTime:10,
  1495. baowenTemp:100,
  1496. hasBaowen:false,
  1497. baowenId:0,
  1498. jiashuiTurn:false,
  1499. baowenTurn:false,
  1500. waterVolume:5,
  1501. secondWaterVolume:5,
  1502. currentWaterVolume:0,
  1503. baowenSettingMode:false,
  1504. baowenSettingTimer:null,
  1505. baowenSettingSendTimer:null,
  1506. wenwuhuoTurn:false,
  1507. wenduSetting:false,
  1508. wenduSettingTimer:null,
  1509. planTimeSettingTimer:null,
  1510. waterVolumeSettingTimer:null,
  1511. timeSettingFirstSettingTimer:null,
  1512. timeSettingSecondSettingTimer:null,
  1513. workText:"·在线",
  1514. isH5:false,
  1515. jianyaoMode:0,
  1516. yaofang:{
  1517. type:0,
  1518. name:"一般药方"
  1519. },
  1520. closeStatusPop:false,
  1521. closeFinishStatusPop:false,
  1522. zhuanyiyaoyePop:false,
  1523. statusHandler:{
  1524. type:0,
  1525. title:"",
  1526. desc:[],
  1527. pause:false
  1528. },
  1529. firstJianyaoMode:0,
  1530. secondJianyaoMode:0,
  1531. leftTransferTime:30,
  1532. pauseStatus:0,
  1533. tempSettingFirst:0,//先煎时间
  1534. currentTempSettingFirst:0,
  1535. editTempSettingFirst:false,
  1536. tempSettingFirstTimer:null
  1537. }
  1538. },
  1539. onLoad: function(opt) {
  1540. this.id = opt.id;
  1541. // this.id = 61;
  1542. this.connectMqtt();
  1543. this.getDetail();
  1544. this.imgUrl = config.imgUrl
  1545. this.fixStyle();
  1546. this.setSystemInfo();
  1547. // this.fixImage();
  1548. // console.log = function(){}
  1549. },
  1550. destroyed() {
  1551. // 取消订阅主题
  1552. this.mqttUnSubscribe(this.deviceInfo);
  1553. clearTimeout(this.checkTimer);
  1554. },
  1555. watch: {
  1556. turnPercent(newvalue){
  1557. // this.lineProgreeStyle = ""
  1558. this.lineProgreeStyle = "width:"+newvalue+"%;background:#50ACFF;height: 100%;";
  1559. },
  1560. pressTurn(newVal,oldValue) {
  1561. // this.pressTurnChangeEvent(newVal);
  1562. },
  1563. resetTurn(newVal){
  1564. // this.resetTurnChnageEvent(newVal);
  1565. },
  1566. decoctControlStatus(newVal,oldValue){
  1567. console.log(newVal+",煎药");
  1568. this.setStatusText();
  1569. },
  1570. currentTemperature(newVal){
  1571. console.log(newVal+",当前温度");
  1572. this.setStatusText();
  1573. },
  1574. temperature(newVal){
  1575. console.log(newVal+",实时温度");
  1576. this.setStatusText();
  1577. }
  1578. },
  1579. methods:{
  1580. closeFinishPop(){
  1581. this.closeFinishStatusPop = false
  1582. let arr = [];
  1583. let obj = {};
  1584. obj.id = "DecoctingSwitch";
  1585. obj.shadow = 0;
  1586. this.decoctControlStatus = false;
  1587. arr.push(obj);
  1588. this.mqttPublish(2,this.deviceInfo,arr,true)
  1589. },
  1590. closeStatusFunc(){
  1591. this.closeStatusPop = false;
  1592. },
  1593. doStatusHandler(){
  1594. let mode = this.jianyaoMode;
  1595. let title = "";
  1596. let desc = []
  1597. let type = 0;
  1598. let isFisish = false
  1599. let noStart = false;
  1600. if(mode == 0) {//煎药一模式
  1601. type = this.firstJianyaoMode
  1602. if(this.firstJianyaoMode == 0){
  1603. noStart = true;
  1604. }
  1605. if(this.firstJianyaoMode == 1){
  1606. title = "加水中";
  1607. desc = ['加水中!']
  1608. }
  1609. if(this.firstJianyaoMode == 2){
  1610. title = "煎药预约";
  1611. desc = ['预约恒温40℃泡药中!']
  1612. }
  1613. this.planEditTime = false;
  1614. if(this.firstJianyaoMode ==3){
  1615. title = "先煎中";
  1616. desc = ['先煎运行中','请打开压力表下方排气阀!']
  1617. }
  1618. if(this.firstJianyaoMode ==4){
  1619. title = "先煎完成";
  1620. desc = ['先煎完成,请放入后下的药','材,关闭排气阀后启动煎药']
  1621. }
  1622. if(this.firstJianyaoMode ==5){
  1623. title = "煎药中";
  1624. desc = ['精心熬制中,祝您早日康复!']
  1625. }
  1626. if(this.firstJianyaoMode ==6){
  1627. title = "后下中";
  1628. desc = ['后下运行中','请确保关闭排气阀']
  1629. }
  1630. if(this.firstJianyaoMode ==7){
  1631. title = "熬制完成";
  1632. isFisish = true;
  1633. }
  1634. }else if(mode == 1) {
  1635. type = this.secondJianyaoMode
  1636. if (this.secondJianyaoMode == 1) {
  1637. title = "一煎加水";
  1638. desc = ['加水中!']
  1639. }
  1640. if (this.secondJianyaoMode == 2) {
  1641. title = "煎药预约";
  1642. desc = ['预约恒温40℃泡药中!']
  1643. }
  1644. this.planEditTime = false;
  1645. if (this.secondJianyaoMode == 3) {
  1646. title = "先煎中";
  1647. desc = ['先煎运行中', '请打开压力表下方排气阀!']
  1648. }
  1649. if (this.secondJianyaoMode == 4) {
  1650. title = "先煎完成";
  1651. desc = ['先煎完成,请放入后下的药', '材,关闭排气阀后启动煎药']
  1652. }
  1653. if (this.secondJianyaoMode == 5) {
  1654. title = "后下中";
  1655. desc = ['后下运行中', '请确保关闭排气阀']
  1656. }
  1657. if (this.secondJianyaoMode == 7) {
  1658. title = "煎药中";
  1659. desc = ['一煎运行中', '精心熬制中,祝您早日康复!']
  1660. type = 5
  1661. }
  1662. if (this.secondJianyaoMode == 8) {
  1663. title = "煎药中";
  1664. type = 8
  1665. desc = ['精心熬制中,祝您早日康复!']
  1666. }
  1667. if (this.secondJianyaoMode == 9) {
  1668. title = "二煎补水";
  1669. desc = []
  1670. }
  1671. if (this.secondJianyaoMode == 10) {
  1672. title = "煎药中";
  1673. type = 5
  1674. desc = ['二煎运行中', '精心熬制中,祝您早日康复!']
  1675. }
  1676. if (this.secondJianyaoMode == 11) {
  1677. title = "熬制完成";
  1678. type = 7
  1679. desc = []
  1680. isFisish = true;
  1681. }
  1682. }
  1683. this.statusHandler = {
  1684. type: type,
  1685. title: title,
  1686. desc: desc,
  1687. pause: false
  1688. }
  1689. if(type == 8){
  1690. this.closeStatusPop = false
  1691. this.zhuanyiyaoyePop = true;
  1692. return;
  1693. }
  1694. if (isFisish) {
  1695. this.closeStatusPop = false;
  1696. this.closeFinishStatusPop = true;
  1697. return;
  1698. }
  1699. if(noStart){
  1700. this.closeStatusPop = false;
  1701. this.closeFinishStatusPop = false;
  1702. this.zhuanyiyaoyePop = false;
  1703. return;
  1704. }
  1705. if (title) {
  1706. this.closeStatusPop = true
  1707. }
  1708. },
  1709. setStatusHandler(){
  1710. let self = this;
  1711. setTimeout(()=>{
  1712. self.doStatusHandler()
  1713. },50);
  1714. },
  1715. setSystemInfo(){
  1716. const systemInfo = uni.getSystemInfoSync();
  1717. let uniPlatform = systemInfo.uniPlatform;
  1718. if(uniPlatform == 'web' || uniPlatform == 'h5'){
  1719. this.isH5 = true;
  1720. }else{
  1721. this.isH5 = false;
  1722. }
  1723. },
  1724. setStatusText(){
  1725. if(!this.jianyaoIng()){
  1726. this.workText = "·在线";
  1727. return;
  1728. }
  1729. if(this.currentTemperature>=this.temperature){
  1730. this.workText = "·文火煎药";
  1731. }else{
  1732. this.workText = "·武火煎药";
  1733. }
  1734. },
  1735. goBack(){
  1736. uni.navigateBack();
  1737. },
  1738. pressTurnChangeEvent(newVal){
  1739. },
  1740. resetTurnChnageEvent(newVal){
  1741. },
  1742. closeDeviceYuyueIngPop(){
  1743. this.deviceYuyueIngPop = false;
  1744. },
  1745. closeDevicePlanPop(){
  1746. this.devicePlanPopDlg = false;
  1747. },
  1748. devicePlan(){
  1749. let self = this;
  1750. if(this.devicePlanTime>600){
  1751. this.$modal.showToast('预约时间最大为600分钟')
  1752. return;
  1753. }
  1754. if(this.devicePlanTime == 0){
  1755. this.$modal.showToast('预约时间不能为空')
  1756. }else{
  1757. let child = this.childId;
  1758. let obj = {deviceNo:this.deviceInfo.serialNumber+"&&"+child,minute:this.devicePlanTime};
  1759. addDevicePlan(obj).then(res=>{
  1760. self.getDevicePlanInfo();
  1761. self.$modal.showToast('预约成功')
  1762. self.devicePlanPopDlg = false;
  1763. });
  1764. }
  1765. },
  1766. closeliuzhuanPop(){
  1767. this.liuzhuanPopDlg = false;
  1768. },
  1769. addBaowenTime(){
  1770. console.log("增加保温时间")
  1771. this.baowenTime++;
  1772. this.sendBaowenSetting();
  1773. },
  1774. subBaowenTime(){
  1775. console.log("减少保温时间")
  1776. this.baowenTime--;
  1777. if(this.baowenTime < 0){
  1778. this.baowenTime = 0;
  1779. }
  1780. this.sendBaowenSetting();
  1781. },
  1782. subBaowenTemp(){
  1783. this.baowenTemp--;
  1784. if(this.baowenTemp<0){
  1785. this.baowenTemp = 1;
  1786. }
  1787. console.log("减少保温温度")
  1788. this.sendBaowenSetting();
  1789. },
  1790. addBaowenTemp(){
  1791. console.log("增加保温温度")
  1792. this.baowenTemp++;
  1793. this.sendBaowenSetting();
  1794. },
  1795. closeBaowenPopDlg(){
  1796. this.baowenPopDlg = false;
  1797. },
  1798. sendBaowenSetting(){
  1799. this.resetBaowenTimer();
  1800. if(this.baowenSettingSendTimer){
  1801. clearTimeout(this.baowenSettingSendTimer);
  1802. }
  1803. let self = this;
  1804. this.baowenSettingSendTimer = setTimeout(function(){
  1805. self.doBaowenSeting();
  1806. },500)
  1807. },
  1808. //6号板子的保温功能
  1809. doBaowenSeting(){
  1810. let arr = [];
  1811. let pressObj = {};
  1812. pressObj.id = "HoldingTemp";
  1813. pressObj.shadow = this.baowenTemp;
  1814. let baowen = {};
  1815. baowen.id = "HoldingTime";
  1816. baowen.shadow = this.baowenTime;
  1817. arr.push(pressObj);
  1818. arr.push(baowen);
  1819. this.mqttPublish(2,this.deviceInfo,arr,true)
  1820. },
  1821. addBaowenSetting(){
  1822. let self = this;
  1823. let obj = {};
  1824. obj.baowenTemp = this.baowenTemp;
  1825. obj.baowenTime = this.baowenTime;
  1826. obj.childId = this.childId;
  1827. obj.productId = this.deviceInfo.productId;
  1828. obj.status = 0;
  1829. obj.deviceNo = this.deviceInfo.serialNumber;
  1830. saveBaowenSetting(obj).then(res=>{
  1831. let code = res.code;
  1832. if(code == 200){
  1833. self.$modal.showToast('添加成功')
  1834. this.closeBaowenPopDlg();
  1835. }else{
  1836. self.$modal.showToast('已经存在保温设置')
  1837. }
  1838. });
  1839. },
  1840. editBaowenSetting(){
  1841. let obj = {};
  1842. obj.baowenTemp = this.baowenTemp;
  1843. obj.baowenTime = this.baowenTime;
  1844. obj.childId = this.childId;
  1845. obj.productId = this.deviceInfo.productId;
  1846. obj.status = 0;
  1847. obj.id = this.baowenId;
  1848. obj.deviceNo = this.deviceInfo.serialNumber;
  1849. editBaowenSetting(obj).then(res=>{
  1850. this.closeBaowenPopDlg();
  1851. });
  1852. },
  1853. delBaowenSetting(){
  1854. let obj = {};
  1855. obj.id = this.baowenId;
  1856. obj.status = 1;
  1857. editBaowenSetting(obj).then(res=>{
  1858. this.hasBaowen = false;
  1859. this.baowenId = 0;
  1860. this.closeBaowenPopDlg();
  1861. });
  1862. },
  1863. confirmLiuzhuannCurrent(){
  1864. if(this.setTurnCurrent<200 || this.setTurnCurrent>400){
  1865. this.notifyError("扭力范围为200-400")
  1866. return;
  1867. }
  1868. let arr = [];
  1869. let pressObj = {};
  1870. pressObj.id = "TurnCurrent";
  1871. pressObj.shadow = this.setTurnCurrent;
  1872. arr.push(pressObj);
  1873. this.mqttPublish(2,this.deviceInfo,arr)
  1874. this.closeliuzhuanPop();
  1875. },
  1876. setPressTurn(){
  1877. let self = this;
  1878. let arr = [];
  1879. let currentPresturn = this.pressTurn;
  1880. let pressObj = {};
  1881. if(this.resetTurn == 1){
  1882. this.resetTurn = 0;
  1883. }
  1884. if(currentPresturn == 1){//代表要关闭
  1885. pressObj.id = "PressTurn";
  1886. pressObj.shadow = 0;
  1887. arr.push(pressObj);
  1888. this.turnPercent = 0;
  1889. this.pressTurn = 0;
  1890. }else{//代表要开启
  1891. pressObj.id = "PressTurn";
  1892. pressObj.shadow = 1;
  1893. arr.push(pressObj);
  1894. this.pressTurn = 1;
  1895. this.resetTurn = 0;
  1896. }
  1897. let resetObj = {}
  1898. resetObj.id = "ResetTurn";
  1899. resetObj.shadow = 0;
  1900. arr.push(resetObj);
  1901. this.mqttPublish(2,this.deviceInfo,arr,true);
  1902. },
  1903. startProgressTimer(type){
  1904. let self = this;
  1905. if(self.lineTimer != null){
  1906. clearInterval(self.lineTimer)
  1907. }
  1908. if(type == 1){
  1909. self.lineTimer = setInterval(function(){
  1910. if(self.turnPercent >=100){
  1911. self.turnPercent = 1;
  1912. clearInterval(self.lineTimer);
  1913. self.startProgressTimer(1);
  1914. }
  1915. self.turnPercent +=2;
  1916. },100);
  1917. }else{
  1918. self.lineTimer = setInterval(function(){
  1919. if(self.turnPercent >=100){
  1920. self.turnPercent = 1;
  1921. clearInterval(self.lineTimer);
  1922. self.startProgressTimer(2);
  1923. }
  1924. self.turnPercent +=2;
  1925. },100);
  1926. }
  1927. },
  1928. setResetTurn(){
  1929. let self = this;
  1930. if(this.pressTurn == 1){
  1931. this.pressTurn = 0;
  1932. }
  1933. let arr = [];
  1934. if(this.resetTurn == 1){
  1935. let resetObj = {};
  1936. resetObj.id = "ResetTurn";
  1937. resetObj.shadow = 0;
  1938. this.resetTurn = 0;
  1939. this.turnPercent = 0;
  1940. arr.push(resetObj);
  1941. }else{
  1942. let resetObj = {};
  1943. resetObj.id = "ResetTurn";
  1944. resetObj.shadow = 1;
  1945. this.resetTurn = 0;
  1946. this.turnPercent = 0;
  1947. arr.push(resetObj);
  1948. }
  1949. let pressObj = {};
  1950. pressObj.id = "PressTurn";
  1951. pressObj.shadow = 0;
  1952. arr.push(pressObj);
  1953. this.mqttPublish(2,this.deviceInfo,arr,true);
  1954. },
  1955. fixImage(heng){
  1956. let self = this;
  1957. wx.getSystemInfo({
  1958. success: res => {
  1959. const { windowWidth, windowHeight, statusBarHeight } = res;
  1960. if(heng){
  1961. let rate = 0.35;
  1962. if(windowHeight<800){
  1963. rate = 0.30;
  1964. }
  1965. let imgHeight = windowWidth*0.85;
  1966. let imageWidth = windowWidth * 1;
  1967. if(this.isH5){
  1968. imgHeight = windowWidth*0.6;
  1969. imageWidth = windowWidth * 0.8;
  1970. }
  1971. self.productSize = ";width:"+imageWidth+"px;height:"+imgHeight+"px;";
  1972. }else{
  1973. let rate = 0.42;
  1974. if(windowHeight<800){
  1975. rate = 0.30;
  1976. }
  1977. let imgHeight = windowHeight*rate;
  1978. let imageWidth = imgHeight * 0.6;
  1979. self.productSize = ";width:"+imageWidth+"px;height:"+imgHeight+"px;";
  1980. }
  1981. }
  1982. })
  1983. },
  1984. propChange(type){
  1985. // if(type == 1){
  1986. // }
  1987. },
  1988. propFocus(type){
  1989. if(type == 1){
  1990. this.jianyaoWenduSetting = true;
  1991. }
  1992. if(type == 2){
  1993. this.jianyaoShijianSetting = true;
  1994. }
  1995. if(type == 3){
  1996. this.baozhuangFengbianSetting = true;
  1997. this.tempFengBianWendu = this.edegTemperature;
  1998. this.edegTemperature = this.setEdegTemperature;
  1999. }
  2000. if(type == 4){
  2001. this.baozhuangFengkouSetting = true;
  2002. this.tempFengkouWendu = this.sealingTemperature;
  2003. this.sealingTemperature = this.setSealingTemperature;
  2004. }
  2005. if(type == 5){
  2006. this.baozhuangRongLiangSetting = true;
  2007. }
  2008. if(type == 6){
  2009. this.baozhuangShuLIangSetting = true;
  2010. }
  2011. },
  2012. autoBlur(type){
  2013. },
  2014. propBlur(type){
  2015. if(type == 1){
  2016. if(this.jianyaoMode == 1){
  2017. this.wenduSetting = true;
  2018. this.changeFirstTemperature();
  2019. }else{
  2020. this.jianyaoWenduSetting = false;
  2021. this.changeTemperature();
  2022. }
  2023. }
  2024. if(type == 2){
  2025. this.temperatureTime = this.leftJianyaoTime;
  2026. this.changeTemperatureTime();
  2027. }
  2028. if(type == 3){
  2029. this.setEdegTemperature = this.edegTemperature;
  2030. this.changeEdegTemperature();
  2031. }
  2032. if(type == 4){
  2033. this.setSealingTemperature = this.sealingTemperature;
  2034. this.changeSealingTemperature();
  2035. }
  2036. if(type == 5){
  2037. this.changePackageVolume()
  2038. }
  2039. if(type == 6){
  2040. this.changePackageNumber();
  2041. }
  2042. if(type ==7){
  2043. this.sendWaterVolume();
  2044. }
  2045. if(type == 8){
  2046. this.sendPlanTime();
  2047. }
  2048. if(type == 9){
  2049. this.sendPlanTime(2);
  2050. }
  2051. if(type == 10){
  2052. this.sendBaowenSetting();
  2053. }
  2054. if(type == 11){
  2055. this.sendBaowenSetting();
  2056. }
  2057. if(type == 12){
  2058. this.changeSecondTime()
  2059. }
  2060. if(type == 13){
  2061. this.changeFirstTemperature();
  2062. }
  2063. if(type ==14){
  2064. this.changeTimeFirst();
  2065. }
  2066. if(type ==15){
  2067. this.changeTimeSecond();
  2068. }
  2069. if(type == 16){
  2070. this.changeFirstTime();
  2071. }
  2072. },
  2073. modifyName(){
  2074. let self = this;
  2075. uni.showModal({
  2076. title: "修改设备名称",
  2077. editable: true,
  2078. placeholderText: "请输入设备名称",
  2079. content: this.deviceInfo.deviceName,
  2080. showCancel: true,
  2081. success: function (res) {
  2082. console.log(res);
  2083. if(res.confirm){
  2084. let content = res.content;
  2085. let obj = {"deviceId":self.id,deviceName:content};
  2086. editDeviceName(obj).then(res=>{
  2087. if(res.code == 200){
  2088. self.deviceInfo.deviceName = content;
  2089. self.$modal.showToast('修改成功')
  2090. }else{
  2091. self.$modal.showToast('修改失败,请稍后再试')
  2092. }
  2093. });
  2094. }
  2095. },
  2096. fail: function (res) {
  2097. console.log(res);
  2098. }
  2099. })
  2100. },
  2101. showWorkPicker(){
  2102. let self = this;
  2103. uni.showModal({
  2104. title: "提 示",
  2105. content: "非专业人员修改可能导致机器损坏",
  2106. confirmText:"确认",
  2107. success: function (res) {
  2108. if(res.confirm){
  2109. self.showModelPicker = true;
  2110. }
  2111. },
  2112. })
  2113. },
  2114. skip(type){
  2115. if(type == 1){
  2116. wx.navigateToMiniProgram({
  2117. appId: this.appid,
  2118. path: 'pages/news_details/help?id=25',
  2119. success(res) {
  2120. // 打开成功
  2121. },
  2122. fail(res){
  2123. console.log(res);
  2124. }
  2125. })
  2126. }else if(type == 2){
  2127. wx.openCustomerServiceChat({
  2128. extInfo: {url: 'https://work.weixin.qq.com/kfid/kfc4202b8764df71c0c'},
  2129. corpId: 'ww8e678fbe6f1079ba',
  2130. success(res) {
  2131. },
  2132. fail(res){
  2133. console.log(res);
  2134. }
  2135. })
  2136. }
  2137. },
  2138. isMulTab(index){
  2139. let type = this.deviceType;
  2140. if(this.secondMachine || this.secondMachine){
  2141. return true;
  2142. }
  2143. return false;
  2144. },
  2145. isPage(index){
  2146. if(this.tabIndex == index){
  2147. return true;
  2148. }
  2149. return false;
  2150. },
  2151. getUpdateInfo(){
  2152. let self = this;
  2153. getLatestFirmware(this.id).then(res=>{
  2154. self.firmware = res.data;
  2155. let curVersion = self.deviceInfo.firmwareVersion;
  2156. let onlineVersion = self.firmware.version
  2157. if(curVersion>=onlineVersion){
  2158. this.$modal.showToast('当前已经是最新版本')
  2159. }else{
  2160. uni.showModal({
  2161. title: '检测到新版本',
  2162. content: "当前版本:"+curVersion+",新版本:"+onlineVersion,
  2163. cancelText: '取消',
  2164. confirmText: '升级',
  2165. success: function(res) {
  2166. if (res.confirm) {
  2167. self.doUpdate();
  2168. }
  2169. }
  2170. })
  2171. }
  2172. });
  2173. },
  2174. doUpdate(){
  2175. if(this.deviceInfo.status != 3){
  2176. this.notifyError("请等待设备上线后操作")
  2177. return;
  2178. }
  2179. let device = this.deviceInfo;
  2180. let message = "";
  2181. let topic = "";
  2182. let title = "升级";
  2183. topic = "/" + device.productId + "/" + device.serialNumber + "/ota/get";
  2184. message = '{"version":"' + this.firmware.version + '","downloadUrl":"' + this.getDownloadUrl(this.firmware.filePath) + '","size":"'+this.firmware.size+'"}';
  2185. this.$mqttTool.publish(topic, message,title).then(res => {
  2186. this.notifySuccess(res);
  2187. }).catch(res => {
  2188. this.notifyError(res);
  2189. });
  2190. },
  2191. getStatusText(){
  2192. if(this.baozhuangRunning()){
  2193. return "工作中";
  2194. }
  2195. if(this.jianyaoIng()){
  2196. return "工作中";
  2197. }
  2198. if(this.leftAppointmentTime>0){
  2199. return "已预约";
  2200. }
  2201. return "空闲中";
  2202. },
  2203. closeYuyueIngPop(){
  2204. this.yuyueIngPop = false;
  2205. },
  2206. confirmMode(item){
  2207. console.log(item)
  2208. this.workMode = item.value[0].id;
  2209. this.setMode(this.workMode);
  2210. this.closeModelPicker();
  2211. },
  2212. closeModelPicker(){
  2213. this.showModelPicker = false;
  2214. },
  2215. confirmYaofang(item){
  2216. this.yaofang = {
  2217. type:item.value[0].id,
  2218. name:item.value[0].text
  2219. }
  2220. let arr = [];
  2221. let obj = {};
  2222. obj.id = "MedicineType";
  2223. obj.shadow = item.value[0].id;
  2224. arr.push(obj);
  2225. this.mqttPublish(2,this.deviceInfo,arr,true)
  2226. this.closeYaofangPicker();
  2227. },
  2228. closeYaofangPicker(){
  2229. this.showYaofangPicker = false;
  2230. },
  2231. confirmJiaozhunTemp(){
  2232. this.jiaozhunTemp = this.jiaozhunTemp_temp;
  2233. this.temperNumber();
  2234. this.closejiaozhunPop();
  2235. },
  2236. addJiaoZhunTemperature(){
  2237. this.jiaozhunTemp_temp ++;
  2238. if(this.jiaozhunTemp_temp>20){
  2239. this.jiaozhunTemp_temp = 20;
  2240. }
  2241. },
  2242. subJiaoZhunTemperature(){
  2243. this.jiaozhunTemp_temp --;
  2244. if(this.jiaozhunTemp_temp<-20){
  2245. this.jiaozhunTemp_temp = -20;
  2246. }
  2247. },
  2248. closejiaozhunPop(){
  2249. this.jiaozhunPopDlg = false;
  2250. },
  2251. showLiuProp(){
  2252. let self = this;
  2253. uni.showModal({
  2254. title: "提 示",
  2255. content: "非专业人员修改可能导致机器损坏",
  2256. confirmText:"确认",
  2257. success: function (res) {
  2258. if(res.confirm){
  2259. self.liuzhuanPopDlg = true;
  2260. }
  2261. },
  2262. })
  2263. },
  2264. showJiaozhunProp(){
  2265. let self = this;
  2266. uni.showModal({
  2267. title: "提 示",
  2268. content: "非专业人员修改可能导致机器损坏",
  2269. confirmText:"确认",
  2270. success: function (res) {
  2271. if(res.confirm){
  2272. self.jiaozhunTemp_temp = self.jiaozhunTemp;
  2273. self.jiaozhunPopDlg = true;
  2274. }
  2275. },
  2276. })
  2277. },
  2278. resetBaowenTimer(){
  2279. let self = this;
  2280. this.baowenSettingMode = true;
  2281. if(this.baowenSettingTimer != null){
  2282. clearTimeout(this.baowenSettingTimer)
  2283. }
  2284. this.baowenSettingTimer = setTimeout(function(){
  2285. self.baowenSettingMode = false;
  2286. },3000);
  2287. },
  2288. jinBaowenMode(){
  2289. let self = this;
  2290. if(!this.jianyaoOpen()){
  2291. this.notifyError("请先开机后再进行操作")
  2292. return;
  2293. }
  2294. if(this.jianyaoIng()){
  2295. this.$modal.showToast('必须在非煎药模式下才能设置')
  2296. return;
  2297. }
  2298. let arr = [];
  2299. let obj = {};
  2300. obj.id = "HoldingSwitch";
  2301. if(!this.baowenTurn){
  2302. obj.shadow = 1;
  2303. this.baowenTurn = true;
  2304. console.log("保温状态打开")
  2305. this.resetBaowenTimer();
  2306. }else{
  2307. this.baowenTurn = false;
  2308. obj.shadow = 0;
  2309. console.log("保温状态关闭")
  2310. }
  2311. arr.push(obj);
  2312. this.mqttPublish(2,this.deviceInfo,arr,true)
  2313. },
  2314. showBaowenProp(){
  2315. if(this.jianyaoIng()){
  2316. this.$modal.showToast('必须非煎药模式下才能设置')
  2317. return;
  2318. }
  2319. let obj = {};
  2320. obj.childId = this.childId;
  2321. obj.status =0;
  2322. obj.deviceNo = this.deviceInfo.serialNumber;
  2323. getBaoWen(obj).then(res=>{
  2324. let data = res.data;
  2325. if(data != null){
  2326. this.baowenTime = data.baowenTime;
  2327. this.baowenTemp = data.baowenTemp;
  2328. this.baowenId = data.id;
  2329. this.hasBaowen = true;
  2330. }else{
  2331. this.hasBaowen = false;
  2332. this.baowenId = 0;
  2333. }
  2334. this.baowenPopDlg = true;
  2335. });
  2336. },
  2337. fixStyle(){
  2338. let self = this;
  2339. wx.getSystemInfo({
  2340. success: res => {
  2341. const { windowWidth, windowHeight, statusBarHeight } = res;
  2342. // 在这里可以获取到屏幕的宽度和高度
  2343. console.log(windowWidth, windowHeight, statusBarHeight);
  2344. if(windowWidth<=350){
  2345. self.unitFixedStyle = ";padding-top:6px;left: 28vw;";
  2346. self.unitFixedStyle1 = ";padding-top:6px;left: 28vw;";
  2347. }else if(windowWidth>=360){
  2348. self.unitFixedStyle = ";padding-top:10rpx;";
  2349. self.unitFixedStyle1 = ";padding-top:10rpx;left: 32vw;";
  2350. }
  2351. self.maxWidth = windowWidth;
  2352. }
  2353. })
  2354. },
  2355. closePlanIngPop(){
  2356. this.jianyaoPopClose = false;
  2357. this.planIngPopDlg = false;
  2358. },
  2359. closePlanPop(){
  2360. this.planPopDlg = false;
  2361. },
  2362. closeErqibushuiPop(){
  2363. this.erqibushuiDlg = false;
  2364. },
  2365. showBaozhuangDlg(type){
  2366. this.popDlg = true;
  2367. if(type == 1){
  2368. this.fengbianDlgShow = true;
  2369. }else if(type == 2){
  2370. this.fengkouDlgShow = true;
  2371. }else if(type == 3){
  2372. this.wenhuoTimeDlgShow = true;
  2373. }
  2374. },
  2375. closePop(){
  2376. this.popDlg = false;
  2377. this.fengbianDlgShow = false;
  2378. this.fengkouDlgShow = false;
  2379. this.wenhuoTimeDlgShow = false;
  2380. },
  2381. changeTab(index,tag){
  2382. if(!tag){
  2383. return;
  2384. }
  2385. let type = this.deviceType;
  2386. let self = this;
  2387. if(index == 2 || index == 3){
  2388. if(!this.isMulTab(index)){
  2389. return;
  2390. }
  2391. }
  2392. this.resetChoose();
  2393. if(index == 4){
  2394. if(!this.forthMachine){
  2395. return;
  2396. }
  2397. uni.showLoading({title:"加载中"});
  2398. getDeviceStatus(this.id,0).then(res=>{
  2399. let data =res.data;
  2400. this.deviceInfo = data;
  2401. self.parseStatusData(data)
  2402. setTimeout(function () {
  2403. uni.hideLoading();
  2404. self.firstTab = false;
  2405. },100);
  2406. });
  2407. }else{
  2408. this.resetResetFunc();
  2409. let arr = ["a","b","c"]
  2410. if(this.isMulTab(index)){
  2411. this.childId =arr[index-1];
  2412. this.getDeviceStatus(function(){
  2413. self.tabIndex = index;
  2414. self.firstTab = true;
  2415. self.tabActive[index-1] = true;
  2416. self.$forceUpdate();
  2417. });
  2418. }else{
  2419. this.getDeviceStatus(function(){
  2420. self.tabIndex = index;
  2421. self.firstTab = true;
  2422. self.tabActive[index-1] = true;
  2423. self.$forceUpdate();
  2424. })
  2425. }
  2426. console.log(this.tabActive)
  2427. }
  2428. },
  2429. resetResetFunc(){
  2430. let self = this;
  2431. if(self.lineTimer != null){
  2432. clearInterval(self.lineTimer)
  2433. }
  2434. this.turnPercent = 0;
  2435. },
  2436. resetChoose(){
  2437. this.tabIndex = 0;
  2438. for (let i = 0; i < 3; i++) {
  2439. this.tabActive[i] = false;
  2440. }
  2441. },
  2442. changePackageVolume(){
  2443. if(this.packageVolume<50){
  2444. this.packageVolume = 50;
  2445. }
  2446. if(this.packageVolume>300){
  2447. this.packageVolume = 300;
  2448. }
  2449. this.sendBaozhuang("PackingVolume");
  2450. },
  2451. changePackageNumber(){
  2452. let min = 1;
  2453. let max = 999;
  2454. if(this.packageNumber<min){
  2455. this.packageNumber = min;
  2456. }
  2457. if(this.packageNumber>max){
  2458. this.packageNumber = max;
  2459. }
  2460. this.sendBaozhuang("PackageQuantity");
  2461. },
  2462. changeEdegTemperature(){
  2463. let min = 80;
  2464. let max = 220;
  2465. if(this.setEdegTemperature<min){
  2466. this.setEdegTemperature = min;
  2467. }
  2468. if(this.setEdegTemperature>max){
  2469. this.setEdegTemperature = max;
  2470. }
  2471. console.log("current setEdegTemperature is :"+this.setEdegTemperature)
  2472. this.sendBaozhuang("SetBandingTemp");
  2473. },
  2474. changeSealingTemperature(){
  2475. let min = 80;
  2476. let max = 220;
  2477. if(this.setSealingTemperature<min){
  2478. this.setSealingTemperature = min;
  2479. }
  2480. if(this.setSealingTemperature>max){
  2481. this.setSealingTemperature = max;
  2482. }
  2483. console.log("current setSealingTemperature is :"+this.setSealingTemperature)
  2484. this.sendBaozhuang("SetSealTemp");
  2485. },
  2486. changeTemperature(){
  2487. let max = 140;
  2488. let min = 100;
  2489. if(this.workMode == 2){
  2490. min = 1;
  2491. }
  2492. if(this.temperature<min){
  2493. this.temperature = min;
  2494. }
  2495. if(this.temperature>max){
  2496. this.temperature = max;
  2497. }
  2498. console.log("current temperature is :"+this.temperature)
  2499. this.sendJianYao("TempSetting");
  2500. },
  2501. changeTemperatureTime(){
  2502. let min = 1;
  2503. let max = 600;
  2504. if(this.temperatureTime<min){
  2505. this.temperatureTime = min;
  2506. }
  2507. if(this.temperatureTime>max){
  2508. this.temperatureTime = max;
  2509. }
  2510. console.log("current temperatureTime is :"+this.temperatureTime)
  2511. this.sendJianYao("TimeSetting");
  2512. },
  2513. jianyaoOpen(){
  2514. if(this.decoctControlOnOffStatus){
  2515. return true;
  2516. }
  2517. return false;
  2518. },
  2519. baozhuangOpen(){
  2520. if(this.packageControlOnOffStatus){
  2521. return true;
  2522. }
  2523. return false;
  2524. },
  2525. baozhuangRunning(){
  2526. if(this.qingxiTurn || this.baozhuangTurn || this.qitingTurn){
  2527. return true;
  2528. }
  2529. return false;
  2530. },
  2531. jianyaoIng(){
  2532. if(this.decoctControlStatus){
  2533. return true;
  2534. }
  2535. return false;
  2536. },
  2537. cancelPlan(){
  2538. let arr = [];
  2539. let obj = {};
  2540. obj.id = "AppointmentTime";
  2541. obj.shadow = 0;
  2542. arr.push(obj);
  2543. let self = this;
  2544. self.kongzhiJianyao(false,arr);
  2545. this.mqttPublish(2,this.deviceInfo,arr,true);
  2546. this.closeYuyueIngPop();
  2547. },
  2548. toPlan(){
  2549. if(!this.jianyaoOpen()){
  2550. this.$modal.showToast('煎药机已经关机')
  2551. return;
  2552. }
  2553. if(this.leftAppointmentTime>0){
  2554. this.yuyueIngPop = true;
  2555. }else{
  2556. if(this.jianyaoIng()){
  2557. this.$modal.showToast('正在煎药')
  2558. return;
  2559. }
  2560. this.planPopDlg = true;
  2561. }
  2562. },
  2563. toDevicePlan(){
  2564. let self = this;
  2565. if(this.decoctControlOnOffStatus){
  2566. this.$modal.showToast('请先关闭煎药后再预约')
  2567. return;
  2568. }
  2569. getDevicePlan(this.deviceInfo.serialNumber+"&&"+this.childId).then(res=>{
  2570. if(res.data != null){
  2571. self.deviceYuyueIngPop = true;
  2572. self.devicePlanInfo = res.data;
  2573. let minute = self.devicePlanInfo.minute;
  2574. if(minute<0){
  2575. minute = 10;
  2576. }
  2577. self.devicePlanInfo.minute = minute;
  2578. }else{
  2579. self.devicePlanPopDlg = true;
  2580. }
  2581. });
  2582. },
  2583. cancelDevicePlan(){
  2584. delDevicePlan(this.devicePlanInfo.id).then(res=>{
  2585. this.$modal.showToast('取消成功')
  2586. this.deviceYuyueIngPop = false;
  2587. this.devicePlanInfo = null;
  2588. })
  2589. },
  2590. getDevicePlanInfo(){
  2591. if(this.boardType != 4){
  2592. return;
  2593. }
  2594. let self = this;
  2595. self.devicePlanInfo = null;
  2596. getDevicePlan(this.deviceInfo.serialNumber+"&&"+self.childId).then(res=>{
  2597. if(res.data != null){
  2598. self.devicePlanInfo = res.data;
  2599. let minute = self.devicePlanInfo.minute;
  2600. if(minute<0){
  2601. minute = 10;
  2602. }
  2603. self.devicePlanInfo.minute = minute;
  2604. }
  2605. });
  2606. },
  2607. calcuStep(){
  2608. if(this.leftAppointmentTime>0){
  2609. this.step = 0;
  2610. return 0;
  2611. }
  2612. if(this.leftJianyaoTime == 0){
  2613. this.step = 100;
  2614. return ;
  2615. }
  2616. let currentTemperature = this.currentTemperature;
  2617. let hightTemperature = this.temperatureTime-this.leftJianyaoTime;//设置的高温时间
  2618. let targetTemperature =100;// this.temperature;
  2619. let targetTemperatureTime = this.temperatureTime;//倒计时
  2620. if(targetTemperature>100){
  2621. targetTemperature = 100;
  2622. }
  2623. let step = 0;
  2624. if(currentTemperature<100){
  2625. let tem = currentTemperature/200*100;
  2626. step = tem;
  2627. }else{
  2628. step = 50;
  2629. let rate = hightTemperature/targetTemperatureTime;
  2630. rate = rate/2;
  2631. rate = rate*100;
  2632. rate = rate.toFixed(2)
  2633. step = step + parseFloat(rate);
  2634. }
  2635. this.step = step.toFixed(2);
  2636. },
  2637. plan(){
  2638. let self = this;
  2639. if(this.planTime>600){
  2640. this.$modal.showToast('预约时间最大为600分钟')
  2641. return;
  2642. }
  2643. if(this.planTime == 0){
  2644. this.$modal.showToast('预约时间不能为空')
  2645. }else{
  2646. let arr = [];
  2647. let obj = {};
  2648. obj.id = "AppointmentTime";
  2649. obj.shadow = this.planTime;
  2650. arr.push(obj);
  2651. this.kongzhiJianyao(true,arr);
  2652. this.mqttPublish(2,this.deviceInfo,arr,true);
  2653. }
  2654. this.$modal.showToast('预约成功')
  2655. this.planPopDlg = false;
  2656. },
  2657. lockCtrl(key){
  2658. let arr = [];
  2659. let obj = {};
  2660. obj.id = "LockControl";
  2661. if(key == 0){
  2662. obj.shadow = 1;
  2663. this.lock.value = 1;
  2664. }else{
  2665. obj.shadow = 0;
  2666. this.lock.value = 0;
  2667. }
  2668. arr.push(obj);
  2669. this.mqttPublish(2,this.deviceInfo,arr)
  2670. },
  2671. setMode(type){
  2672. let arr = [];
  2673. let obj = {};
  2674. obj.id = "WorkMode";
  2675. obj.shadow = type;
  2676. arr.push(obj);
  2677. this.mqttPublish(2,this.deviceInfo,arr,true)
  2678. this.workMode = type;
  2679. },
  2680. temperNumber(value){
  2681. let arr = [];
  2682. let obj = {};
  2683. obj.id = "CalibrationTemp";
  2684. obj.shadow = this.jiaozhunTemp;
  2685. arr.push(obj);
  2686. this.mqttPublish(2,this.deviceInfo,arr,true)
  2687. },
  2688. volumeNumber(){
  2689. let arr = [];
  2690. let obj = {};
  2691. obj.id = "CapacityCalibration";
  2692. obj.shadow = 1;
  2693. arr.push(obj);
  2694. this.mqttPublish(2,this.deviceInfo,arr,true)
  2695. },
  2696. showConfirm(title,content,yes,no){
  2697. uni.showModal({
  2698. title: title,
  2699. content: content,
  2700. success: function (res) {
  2701. if (res.confirm) {
  2702. yes();
  2703. } else if (res.cancel) {
  2704. no();
  2705. }
  2706. }
  2707. });
  2708. },
  2709. reset(){
  2710. let self = this;
  2711. uni.showModal({
  2712. title: "提 示",
  2713. content: "非专业人员修改可能导致机器损坏",
  2714. confirmText:"确认",
  2715. success: function (res) {
  2716. if(res.confirm){
  2717. let arr = [];
  2718. let obj = {};
  2719. obj.id = "RestoreFactory";
  2720. obj.shadow = 1;
  2721. arr.push(obj);
  2722. self.mqttPublish(2,self.deviceInfo,arr)
  2723. }
  2724. },
  2725. })
  2726. },
  2727. paishui(){
  2728. let flag = false;
  2729. flag = this.drainageTurn == 1?true:false;
  2730. let arr = [];
  2731. let obj = {};
  2732. if(flag){
  2733. obj.shadow = 0;
  2734. }else{
  2735. obj.shadow = 1;
  2736. }
  2737. obj.id = "DrainageTurn";
  2738. arr.push(obj);
  2739. this.mqttPublish(2,this.deviceInfo,arr)
  2740. },
  2741. turnChange(type){
  2742. let flag = false;
  2743. let obj = {};
  2744. if(type ==3){
  2745. flag = this.qingxiTurn;
  2746. obj.id = "WashSwitch";
  2747. }else if(type == 2){
  2748. if(this.qingxiTurn || this.qitingTurn){
  2749. this.$modal.showToast("启停、包装、清洗不能同时打开")
  2750. return;
  2751. }
  2752. flag = this.baozhuangTurn;
  2753. obj.id = "PackageSwitch";
  2754. }else if(type == 1) {
  2755. if(this.qingxiTurn || this.baozhuangTurn){
  2756. this.$modal.showToast("启停、包装、清洗不能同时打开")
  2757. return;
  2758. }
  2759. flag = this.qitingTurn;
  2760. obj.id = "CarrybagSwitch";
  2761. }
  2762. flag = !flag;
  2763. let arr = [];
  2764. if(flag){
  2765. obj.shadow = 1;
  2766. }else{
  2767. obj.shadow = 0;
  2768. }
  2769. arr.push(obj);
  2770. this.mqttPublish(2,this.deviceInfo,arr)
  2771. },
  2772. addPackageVolume(){
  2773. this.packageVolume++;
  2774. if(this.packageVolume>300){
  2775. this.packageVolume = 50;
  2776. }
  2777. console.log("增加包装容量")
  2778. this.changePackageVolume()
  2779. },
  2780. subPackageVolume(){
  2781. this.packageVolume--;
  2782. if( this.packageVolume<50){
  2783. this.packageVolume = 300;
  2784. }
  2785. console.log("减少包装容量")
  2786. this.changePackageVolume()
  2787. },
  2788. addPackageNumber(){
  2789. this.packageNumber++;
  2790. if(this.packageNumber>999){
  2791. this.packageNumber = 1;
  2792. }
  2793. console.log("增加包装数量")
  2794. this.changePackageNumber();
  2795. },
  2796. subPackageNumber(){
  2797. this.packageNumber--;
  2798. if(this.packageNumber<1){
  2799. this.packageNumber = 999;
  2800. }
  2801. console.log("减少包装数量")
  2802. this.changePackageNumber();
  2803. },
  2804. addSealingTemperature(){
  2805. console.log("增加封口温度")
  2806. if(!this.fengkouDlgShow){
  2807. this.fengkouDlgShow = true;
  2808. }
  2809. this.setSealingTemperature++;
  2810. this.changeSealingTemperature();
  2811. },
  2812. subSealingTemperature(){
  2813. console.log("减少封口温度")
  2814. if(!this.fengkouDlgShow){
  2815. this.fengkouDlgShow = true;
  2816. }
  2817. this.setSealingTemperature--;
  2818. this.changeSealingTemperature();
  2819. },
  2820. addEdegTemperature(){
  2821. console.log("增加封边温度")
  2822. this.editing = true;
  2823. if(!this.fengbianDlgShow){
  2824. this.fengbianDlgShow = true;
  2825. }
  2826. this.setEdegTemperature++;
  2827. this.changeEdegTemperature();
  2828. },
  2829. subEdegTemperature(){
  2830. console.log("减少封边温度")
  2831. this.editing = true;
  2832. if(!this.fengbianDlgShow){
  2833. this.fengbianDlgShow = true;
  2834. }
  2835. this.setEdegTemperature--;
  2836. this.changeEdegTemperature();
  2837. },
  2838. subErqibushui(){
  2839. this.secondAddWaterTime--;
  2840. if(this.secondAddWaterTime <10){
  2841. this.secondAddWaterTime = 10
  2842. }
  2843. this.editSecondAddWaterTime = true;
  2844. this.sendJianYao("SecondAddWaterTime")
  2845. },
  2846. addErqibushui(){
  2847. this.secondAddWaterTime++;
  2848. if(this.secondAddWaterTime >20){
  2849. this.secondAddWaterTime = 20
  2850. }
  2851. this.editSecondAddWaterTime = true;
  2852. this.sendJianYao("SecondAddWaterTime")
  2853. },
  2854. addTemperatureTime(type){
  2855. if(this.jianyaoMode == 0){
  2856. console.log("增加煎药时间")
  2857. if(!this.wenhuoTimeDlgShow){
  2858. this.wenhuoTimeDlgShow = true;
  2859. this.temperatureTime = this.leftJianyaoTime;
  2860. }
  2861. this.temperatureTime++;
  2862. this.changeTemperatureTime()
  2863. }else{
  2864. this.wenhuoTimeDlgShow = true;
  2865. this.FirstTime++;
  2866. this.changeFirstTime()
  2867. }
  2868. },
  2869. subNewTemperatureTime(type){
  2870. this.temperatureTime--;
  2871. let min = 1;
  2872. let max = 600;
  2873. if(this.temperatureTime<min){
  2874. this.temperatureTime = min;
  2875. }
  2876. if(this.temperatureTime>max){
  2877. this.temperatureTime = max;
  2878. }
  2879. this.sendData("TimeSetting",this.temperatureTime)
  2880. },
  2881. addNewTemperatureTime(type){
  2882. this.temperatureTime++
  2883. let min = 1;
  2884. let max = 600;
  2885. if(this.temperatureTime<min){
  2886. this.temperatureTime = min;
  2887. }
  2888. if(this.temperatureTime>max){
  2889. this.temperatureTime = max;
  2890. }
  2891. this.sendData("TimeSetting",this.temperatureTime)
  2892. },
  2893. sendData(key,value){
  2894. let obj = {};
  2895. let arr = [];
  2896. obj.id = key;
  2897. obj.shadow = value;
  2898. arr.push(obj);
  2899. this.mqttPublish(2,this.deviceInfo,arr,true)
  2900. },
  2901. subTemperatureTime(type){
  2902. if(this.jianyaoMode == 0){
  2903. console.log("减少煎药时间")
  2904. if(!this.wenhuoTimeDlgShow){
  2905. this.wenhuoTimeDlgShow = true;
  2906. this.temperatureTime = this.leftJianyaoTime;
  2907. }
  2908. this.temperatureTime--;
  2909. if(this.temperatureTime<=0){
  2910. this.temperatureTime = 1;
  2911. }
  2912. this.changeTemperatureTime()
  2913. }else{
  2914. this.wenhuoTimeDlgShow = true;
  2915. this.FirstTime--;
  2916. if(this.FirstTime<=0){
  2917. this.FirstTime = 1;
  2918. }
  2919. this.changeFirstTime()
  2920. }
  2921. },
  2922. addSecondTime(){
  2923. this.SecondTime ++;
  2924. this.wenhuoTimeDlgShow = true;
  2925. this.changeSecondTime()
  2926. },
  2927. subSecondTime(){
  2928. this.SecondTime --;
  2929. if(this.SecondTime<15){
  2930. this.SecondTime = 15;
  2931. }
  2932. this.wenhuoTimeDlgShow = true;
  2933. this.changeSecondTime()
  2934. },
  2935. changeSecondTime(){
  2936. let min = 1;
  2937. let max = 600;
  2938. if(this.SecondTime<min){
  2939. this.SecondTime = min;
  2940. }
  2941. if(this.SecondTime>max){
  2942. this.SecondTime = max;
  2943. }
  2944. console.log("current temperatureTime is :"+this.SecondTime)
  2945. this.sendJianYao("SecondTime");
  2946. },
  2947. changeFirstTime(){
  2948. let min = 1;
  2949. let max = 600;
  2950. if(this.FirstTime<min){
  2951. this.FirstTime = min;
  2952. }
  2953. if(this.FirstTime>max){
  2954. this.FirstTime = max;
  2955. }
  2956. console.log("current temperatureTime is :"+this.FirstTime)
  2957. this.sendJianYao("FirstTime");
  2958. },
  2959. addTemperature(){
  2960. if(this.jianyaoMode == 0){
  2961. console.log("zengjia煎药温度")
  2962. this.temperature++;
  2963. this.wenduSetting = true;
  2964. this.changeTemperature();
  2965. }else{
  2966. console.log("zengjia煎药温度")
  2967. this.FirstTemp++;
  2968. this.wenduSetting = true;
  2969. this.changeFirstTemperature();
  2970. }
  2971. },
  2972. resetShowPlanTime(){
  2973. let self = this;
  2974. if(this.planTimeSettingTimer){
  2975. clearTimeout(this.planTimeSettingTimer);
  2976. }
  2977. this.planTimeSettingTimer = setTimeout(function(){
  2978. self.planEditTime = false;
  2979. },3000)
  2980. },
  2981. resetWaterVolume(){
  2982. let self = this;
  2983. if(this.waterVolumeSettingTimer){
  2984. clearTimeout(this.waterVolumeSettingTimer);
  2985. }
  2986. this.waterVolumeSettingTimer = setTimeout(function(){
  2987. self.editWaterVolume = false;
  2988. },3000)
  2989. },
  2990. resetTimeSettingFirst(){
  2991. let self = this;
  2992. if(this.timeSettingFirstSettingTimer){
  2993. clearTimeout(this.timeSettingFirstSettingTimer);
  2994. }
  2995. this.timeSettingFirstSettingTimer = setTimeout(function(){
  2996. self.editTimeSettingFirst = false;
  2997. },3000)
  2998. },
  2999. resetTimeSettingSecond(){
  3000. let self = this;
  3001. if(this.timeSettingSecondSettingTimer){
  3002. clearTimeout(this.timeSettingSecondSettingTimer);
  3003. }
  3004. this.timeSettingSecondSettingTimer = setTimeout(function(){
  3005. self.editTimeSettingSecond = false;
  3006. },3000)
  3007. },
  3008. resetShowWendu(){
  3009. let self = this;
  3010. if(this.wenduSettingTimer){
  3011. clearTimeout(this.wenduSettingTimer);
  3012. }
  3013. this.wenduSettingTimer = setTimeout(function(){
  3014. self.wenduSetting = false;
  3015. },3000)
  3016. },
  3017. resetTempSettingFirstTimer(){
  3018. let self = this;
  3019. if(this.tempSettingFirstTimer){
  3020. clearTimeout(this.tempSettingFirstTimer);
  3021. }
  3022. this.tempSettingFirstTimer = setTimeout(function(){
  3023. self.editTempSettingFirst = false;
  3024. },3000)
  3025. },
  3026. resetSecondAddWaterTimeTimer(){
  3027. let self = this;
  3028. if(this.editSecondAddWaterTimeTimer){
  3029. clearTimeout(this.editSecondAddWaterTimeTimer);
  3030. }
  3031. this.editSecondAddWaterTimeTimer = setTimeout(function(){
  3032. self.editSecondAddWaterTime = false;
  3033. },3000)
  3034. },
  3035. subTimeFirst(){
  3036. this.timeSettingFirst = parseInt(this.timeSettingFirst) -1;
  3037. if(this.timeSettingFirst<0){
  3038. this.timeSettingFirst = 0;
  3039. }
  3040. this.editTimeSettingFirst = true;
  3041. this.changeTimeFirst();
  3042. },
  3043. addTimeFirst(){
  3044. this.timeSettingFirst = parseInt(this.timeSettingFirst) +1;
  3045. this.editTimeSettingFirst = true;
  3046. this.changeTimeFirst();
  3047. },
  3048. changeTimeFirst(){
  3049. this.sendJianYao("TimeSetFirst");
  3050. },
  3051. doAction(type){
  3052. if(type == 3){
  3053. let mode = this.jianyaoMode;
  3054. if(mode == 0){
  3055. this.firstJianyaoMode = 5;
  3056. }else{
  3057. this.secondJianyaoMode = 8;
  3058. }
  3059. let arr = []
  3060. let obj2 = {};
  3061. obj2.id = "DecoctingSwitch";
  3062. obj2.shadow = 1;
  3063. arr.push(obj2);
  3064. this.mqttPublish(2,this.deviceInfo,arr,true);
  3065. this.setStatusHandler()
  3066. return;
  3067. }
  3068. this.pauseStatus = type
  3069. let arr = []
  3070. let obj2 = {};
  3071. obj2.id = "PauseStatus";
  3072. obj2.shadow = type;
  3073. arr.push(obj2);
  3074. this.mqttPublish(2,this.deviceInfo,arr,true);
  3075. },
  3076. addTimeSecond(){
  3077. this.timeSettingSecond = parseInt(this.timeSettingSecond) +1;
  3078. this.editTimeSettingSecond = true;
  3079. this.changeTimeSecond();
  3080. },
  3081. subTimeSecond(){
  3082. this.timeSettingSecond = parseInt(this.timeSettingSecond) -1;
  3083. if(this.timeSettingSecond<0){
  3084. this.timeSettingSecond = 0
  3085. }
  3086. this.editTimeSettingSecond = true;
  3087. this.changeTimeSecond();
  3088. },
  3089. changeTimeSecond(){
  3090. this.sendJianYao("TimeSetSecond");
  3091. },
  3092. subWaterVolume(){
  3093. if(this.jianyaoMode == 0){
  3094. this.waterVolume = parseFloat(this.waterVolume) -0.1;
  3095. this.waterVolume = this.waterVolume.toFixed(1);
  3096. this.editWaterVolume = true;
  3097. this.sendWaterVolume();
  3098. }else if(this.jianyaoMode == 1){
  3099. this.secondWaterVolume = parseFloat(this.secondWaterVolume) -0.1;
  3100. this.secondWaterVolume = this.secondWaterVolume.toFixed(1);
  3101. this.editWaterVolume = true;
  3102. this.sendSecondWaterVolume();
  3103. }
  3104. },
  3105. addWaterVolume(){
  3106. if(this.jianyaoMode == 0){
  3107. this.waterVolume = parseFloat(this.waterVolume) +0.1;
  3108. this.waterVolume = this.waterVolume.toFixed(1);
  3109. this.editWaterVolume = true;
  3110. this.sendWaterVolume();
  3111. }else if(this.jianyaoMode == 1){
  3112. this.secondWaterVolume = parseFloat(this.secondWaterVolume) +0.1;
  3113. this.secondWaterVolume = this.secondWaterVolume.toFixed(1);
  3114. this.editWaterVolume = true;
  3115. this.sendSecondWaterVolume();
  3116. }
  3117. },
  3118. subSecondWaterVolume(){
  3119. this.waterVolume = parseFloat(this.waterVolume) -0.1;
  3120. this.waterVolume = this.waterVolume.toFixed(1);
  3121. this.editWaterVolume = true;
  3122. this.sendWaterVolume();
  3123. },
  3124. addSecondWaterVolume(){
  3125. this.waterVolume = parseFloat(this.waterVolume) +0.1;
  3126. this.waterVolume = this.waterVolume.toFixed(1);
  3127. this.editWaterVolume = true;
  3128. this.sendWaterVolume();
  3129. },
  3130. sendSecondWaterVolume(){
  3131. if(this.secondWaterVolume<0){
  3132. this.secondWaterVolume = 0;
  3133. }
  3134. this.sendJianYao("SecondWaterVolume");
  3135. },
  3136. sendWaterVolume(){
  3137. if(this.jianyaoMode == 0){
  3138. if(this.waterVolume<0){
  3139. this.waterVolume = 0;
  3140. }
  3141. this.sendJianYao("WaterVolume");
  3142. }else{
  3143. this.sendSecondWaterVolume();
  3144. }
  3145. },
  3146. subTemperature(type){
  3147. if(this.jianyaoMode == 0){
  3148. console.log("减少煎药温度")
  3149. this.temperature--;
  3150. this.wenduSetting = true;
  3151. this.changeTemperature();
  3152. }else{
  3153. console.log("减少煎药温度")
  3154. this.FirstTemp--;
  3155. this.wenduSetting = true;
  3156. this.changeFirstTemperature();
  3157. }
  3158. },
  3159. changeFirstTemperature(){
  3160. let max = 140;
  3161. let min = 100;
  3162. if(this.FirstTemp<min){
  3163. this.FirstTemp = min;
  3164. }
  3165. if(this.FirstTemp>max){
  3166. this.FirstTemp = max;
  3167. }
  3168. console.log("current temperature is :"+this.FirstTemp)
  3169. this.sendJianYao("FirstTemp");
  3170. },
  3171. changeJianyaoMode(mode){
  3172. let arr = [];
  3173. this.jianyaoMode = mode
  3174. let obj2 = {};
  3175. obj2.id = "JianyaoMode";
  3176. obj2.shadow = mode;
  3177. arr.push(obj2);
  3178. this.mqttPublish(2,this.deviceInfo,arr,true);
  3179. },
  3180. addPlanTime(type){
  3181. console.log("增加预约时间")
  3182. if(type == 2){
  3183. this.planTime = this.leftAppointmentTime;
  3184. }
  3185. this.planTime++;
  3186. this.planEditTime = true;
  3187. this.sendPlanTime(type);
  3188. },
  3189. subTempSettingFirst(){
  3190. this.editTempSettingFirst = true;
  3191. this.tempSettingFirst --;
  3192. if(this.tempSettingFirst <0){
  3193. this.tempSettingFirst = 0
  3194. }
  3195. this.sendJianYao("TempSetFirst")
  3196. },
  3197. addTempSettingFirst(){
  3198. this.editTempSettingFirst = true;
  3199. this.tempSettingFirst ++;
  3200. if(this.tempSettingFirst>105){
  3201. this.tempSettingFirst = 105;
  3202. }
  3203. this.sendJianYao("TempSetFirst")
  3204. },
  3205. subPlanTime(type){
  3206. console.log("减少预约时间")
  3207. if(type == 2){
  3208. this.planTime = this.leftAppointmentTime;
  3209. }
  3210. this.planEditTime = true;
  3211. this.planTime--;
  3212. this.sendPlanTime(type);
  3213. },
  3214. sendPlanTime(type){
  3215. if(this.planTime<0){
  3216. this.planTime = 0;
  3217. }
  3218. if(type == 2){
  3219. this.leftAppointmentTime = this.planTime;
  3220. }
  3221. this.sendJianYao("AppointmentTime");
  3222. },
  3223. subDevicePlanTime(){
  3224. this.devicePlanTime--;
  3225. if(this.devicePlanTime<0){
  3226. this.devicePlanTime = 1;
  3227. }
  3228. console.log("减少预约时间")
  3229. this.sendJianYao("AppointmentTime")
  3230. },
  3231. addDevicePlanTime(){
  3232. console.log("增加预约时间")
  3233. this.devicePlanTime++;
  3234. this.planEditTime = true;
  3235. this.sendJianYao("AppointmentTime")
  3236. },
  3237. sendBaozhuang(targetKey){
  3238. let self = this;
  3239. let arr = [];
  3240. if(this.baozhuangTimer != null){
  3241. clearTimeout(this.baozhuangTimer);
  3242. }
  3243. this.baozhuangTimer = setTimeout(function (){
  3244. for (let i = 0; i <this.baozhuangKeys.length; i++) {
  3245. let key = this.baozhuangKeys[i];
  3246. let obj = {};
  3247. obj.id = key;
  3248. if(key === "PackingVolume"){
  3249. obj.shadow = this.packageVolume;
  3250. setTimeout(function (){
  3251. self.baozhuangRongLiangSetting = false;
  3252. },self.resetDuration);
  3253. }
  3254. if(key === "PackageQuantity"){
  3255. obj.shadow = this.packageNumber;
  3256. setTimeout(function (){
  3257. self.baozhuangShuLIangSetting = false;
  3258. },self.resetDuration);
  3259. }
  3260. if(key === "SetSealTemp"){
  3261. obj.shadow = this.setSealingTemperature;
  3262. setTimeout(function (){
  3263. self.fengkouDlgShow = false;
  3264. self.baozhuangFengkouSetting = false;
  3265. self.sealingTemperature = self.tempFengKouWendu;;
  3266. },self.resetDuration);
  3267. }
  3268. if(key === "SetBandingTemp"){
  3269. obj.shadow = this.setEdegTemperature;
  3270. setTimeout(function (){
  3271. self.fengbianDlgShow = false;
  3272. self.baozhuangFengbianSetting = false;
  3273. self.edegTemperature = self.tempFengBianWendu;
  3274. },self.resetDuration);
  3275. }
  3276. if(targetKey == key){
  3277. arr.push(obj);
  3278. break;
  3279. }
  3280. }
  3281. this.mqttPublish(2,this.deviceInfo,arr)
  3282. }.bind(this),500);
  3283. },
  3284. sendJianYao(targetKey){
  3285. let self = this;
  3286. let arr = [];
  3287. if(this.jianyaoTimer != null){
  3288. clearTimeout(this.jianyaoTimer);
  3289. }
  3290. this.jianyaoTimer = setTimeout(function (targetKey){
  3291. let isExist = false;
  3292. for (let j = 0; j <this.jianyaoKeys.length; j++) {
  3293. let key = this.jianyaoKeys[j];
  3294. if(key == targetKey){
  3295. isExist = true;
  3296. }
  3297. }
  3298. if(isExist){
  3299. let key = targetKey
  3300. let obj = {};
  3301. obj.id = key;
  3302. if(key === "TempSetting"){
  3303. obj.shadow = this.temperature;
  3304. self.resetShowWendu();
  3305. }
  3306. if(key === "FirstTemp"){
  3307. obj.shadow = this.FirstTemp;
  3308. self.resetShowWendu();
  3309. }
  3310. if(key === "FirstTime"){
  3311. obj.shadow = this.FirstTime;
  3312. setTimeout(function(){
  3313. self.wenhuoTimeDlgShow = false;
  3314. self.jianyaoShijianSetting = false;
  3315. },self.resetDuration)
  3316. }
  3317. if(key === "SecondTime"){
  3318. obj.shadow = this.SecondTime;
  3319. setTimeout(function(){
  3320. self.wenhuoTimeDlgShow = false;
  3321. self.jianyaoShijianSetting = false;
  3322. },self.resetDuration)
  3323. }
  3324. if(key === "TempSetFirst"){
  3325. obj.shadow = this.tempSettingFirst;
  3326. self.resetTempSettingFirstTimer();
  3327. }
  3328. if(key === "SecondAddWaterTime"){
  3329. obj.shadow = this.secondAddWaterTime;
  3330. self.resetSecondAddWaterTimeTimer();
  3331. }
  3332. if(key === "TimeSetFirst"){
  3333. obj.shadow = this.timeSettingFirst
  3334. self.resetTimeSettingFirst()
  3335. }
  3336. if(key === "TimeSetSecond"){
  3337. obj.shadow = this.timeSettingSecond
  3338. self.resetTimeSettingSecond()
  3339. }
  3340. if(key === "WaterVolume"){
  3341. obj.shadow = this.waterVolume*10;
  3342. self.resetWaterVolume();
  3343. }
  3344. if(key === "SecondWaterVolume"){
  3345. obj.shadow = this.secondWaterVolume*10;
  3346. self.resetWaterVolume();
  3347. }
  3348. if(key === "AppointmentTime"){
  3349. obj.shadow = this.planTime;
  3350. self.resetShowPlanTime();
  3351. }
  3352. if(key === "TimeSetting"){
  3353. obj.shadow = this.temperatureTime;
  3354. self.leftJianyaoTime = this.temperatureTime;;
  3355. setTimeout(function(){
  3356. self.wenhuoTimeDlgShow = false;
  3357. self.jianyaoShijianSetting = false;
  3358. },self.resetDuration)
  3359. }
  3360. arr.push(obj);
  3361. this.mqttPublish(2,this.deviceInfo,arr,true)
  3362. }
  3363. }.bind(this,targetKey),500);
  3364. },
  3365. buildPropKey(key){
  3366. if(this.childId !=0){
  3367. return key+"_"+this.childId;
  3368. }else{
  3369. return key;
  3370. }
  3371. },
  3372. addWater(){
  3373. if(!this.jianyaoOpen()){
  3374. this.notifyError("请先开机后再进行操作")
  3375. return;
  3376. }
  3377. if(this.jianyaoIng()){
  3378. this.$modal.showToast('必须在非煎药模式下才能设置')
  3379. return;
  3380. }
  3381. let obj = {};
  3382. let arr = [];
  3383. obj.id = "WaterSwitch";
  3384. if(!this.jiashuiTurn){
  3385. obj.shadow = 1;
  3386. console.log("加水状态打开")
  3387. }else{
  3388. obj.shadow = 0;
  3389. console.log("加水状态关闭")
  3390. }
  3391. arr.push(obj);
  3392. this.mqttPublish(2,this.deviceInfo,arr,true)
  3393. },
  3394. canStart(){
  3395. if(this.timeSettingFirst == 0 && this.timeSettingSecond == 0){
  3396. return true;
  3397. }
  3398. if(this.timeSettingFirst >0 && this.timeSettingSecond >0){
  3399. return true
  3400. }
  3401. return false;
  3402. },
  3403. decoctControlChange(){
  3404. // if(this.decoctControlStatus){
  3405. // this.stopDecoctControlChange();
  3406. // return;
  3407. // }
  3408. if(!this.decoctControlStatus){
  3409. if(!this.canStart()){
  3410. this.$modal.alert("先煎时间和后下时间必须均不设置或均设置")
  3411. return;
  3412. }
  3413. }
  3414. this.decoctControlStatus = !this.decoctControlStatus;
  3415. let arr = [];
  3416. let obj = {};
  3417. obj.id = "DecoctingSwitch";
  3418. if(this.decoctControlStatus){
  3419. obj.shadow = 1;
  3420. console.log("煎药状态打开")
  3421. this.beforeStart();
  3422. this.setStatusHandler()
  3423. this.checkJianyao();
  3424. }else{
  3425. obj.shadow = 0;
  3426. console.log("煎药状态关闭")
  3427. }
  3428. arr.push(obj);
  3429. this.mqttPublish(2,this.deviceInfo,arr,true)
  3430. },
  3431. beforeStart(){
  3432. this.pauseStatus = 0
  3433. if(parseInt(this.jianyaoMode) === 0){
  3434. if(parseFloat(this.waterVolume)>0){//是否有加水
  3435. this.firstJianyaoMode = 1;
  3436. }else{
  3437. if(parseFloat(this.planTime)>0){//是否预约
  3438. this.firstJianyaoMode = 2;
  3439. }else{
  3440. if(parseFloat(this.timeSettingFirst)>0){//是否设置先煎
  3441. this.firstJianyaoMode = 3;
  3442. }else{
  3443. this.firstJianyaoMode = 5;
  3444. }
  3445. }
  3446. }
  3447. }else if(parseInt(this.jianyaoMode) === 1){
  3448. if(parseFloat(this.secondWaterVolume)>0) {
  3449. this.secondJianyaoMode = 1;
  3450. }else{
  3451. if(parseFloat(this.planTime)>0) {//是否预约
  3452. this.secondJianyaoMode = 2;
  3453. }else{
  3454. if(parseFloat(this.timeSettingFirst)>0){//是否设置先煎
  3455. this.secondJianyaoMode = 3;
  3456. }else{
  3457. this.secondJianyaoMode = 7;
  3458. }
  3459. }
  3460. }
  3461. }
  3462. },
  3463. kongzhiJianyao(flag,arr){//不判断煎药状态
  3464. let obj = {};
  3465. if(!this.decoctControlOnOffStatus){
  3466. this.notifyError("请先开机后再进行操作")
  3467. return;
  3468. }
  3469. obj.id = "DecoctingSwitch";
  3470. if(flag){
  3471. obj.shadow = 1;
  3472. console.log("煎药状态打开")
  3473. this.checkJianyao();
  3474. }else{
  3475. obj.shadow = 0;
  3476. console.log("煎药状态关闭")
  3477. }
  3478. arr.push(obj);
  3479. },
  3480. stopDecoctControlChange(){
  3481. let obj = {};
  3482. let arr = [];
  3483. if(!this.decoctControlOnOffStatus){
  3484. this.notifyError("请先开机后再进行操作")
  3485. return;
  3486. }
  3487. if(!this.decoctControlStatus){
  3488. return;
  3489. }
  3490. this.decoctControlStatus = !this.decoctControlStatus;
  3491. obj.id = "DecoctingSwitch";
  3492. if(this.decoctControlStatus){
  3493. obj.shadow = 1;
  3494. console.log("煎药状态打开")
  3495. }else{
  3496. obj.shadow = 0;
  3497. console.log("煎药状态关闭")
  3498. }
  3499. arr.push(obj);
  3500. let obj2 = {};
  3501. obj2.id = "AppointmentTime";
  3502. obj2.shadow = 0;
  3503. arr.push(obj2);
  3504. this.mqttPublish(2,this.deviceInfo,arr,true);
  3505. this.cancelBaowen();
  3506. },
  3507. cancelBaowen(){
  3508. let obj = {};
  3509. obj.childId = this.childId;
  3510. obj.productId = this.deviceInfo.productId;
  3511. obj.status = 0;
  3512. obj.deviceNo = this.deviceInfo.serialNumber;
  3513. cancelBaowen(obj);
  3514. },
  3515. decoctControlOnOffChange(){
  3516. let obj = {};
  3517. //4号板子预约是无法开启煎药的
  3518. if(!this.decoctControlOnOffStatus){
  3519. if(this.boardType == 4){
  3520. if(this.devicePlanInfo != null){
  3521. this.$modal.showToast('请先取消预约后再开机');
  3522. return;
  3523. }
  3524. }
  3525. }
  3526. this.decoctControlOnOffStatus = !this.decoctControlOnOffStatus;
  3527. let arr = [];
  3528. obj.id = "PowerControl";
  3529. let isMul = false;
  3530. if(this.boardType != 4){
  3531. if(this.decoctControlStatus){
  3532. this.$modal.showToast('请先结束煎药后操作')
  3533. this.decoctControlOnOffStatus = !this.decoctControlOnOffStatus;
  3534. return;
  3535. }
  3536. }
  3537. if(this.oneToMul && this.firstTab){
  3538. obj.id = "PowerCtl";
  3539. isMul = true;
  3540. }
  3541. if(this.decoctControlOnOffStatus){
  3542. obj.shadow = 1;
  3543. console.log("煎药机开关打开")
  3544. }else{
  3545. obj.shadow = 0;
  3546. console.log("煎药机开关关闭")
  3547. }
  3548. arr.push(obj);
  3549. this.mqttPublish(2,this.deviceInfo,arr,isMul)
  3550. },
  3551. packageControlOnOffChange(){
  3552. let obj = {};
  3553. let arr = [];
  3554. if(this.baozhuangRunning()){
  3555. this.$modal.showToast('请先停止运行后操作')
  3556. return;
  3557. }
  3558. obj.id = "PackagePowerControl";
  3559. this.packageControlOnOffStatus = !this.packageControlOnOffStatus;
  3560. if(this.packageControlOnOffStatus){
  3561. console.log("包装机器开关打开")
  3562. obj.shadow = 1;
  3563. }else{
  3564. console.log("包装机器开关关闭")
  3565. obj.shadow = 0;
  3566. }
  3567. arr.push(obj);
  3568. this.mqttPublish(2,this.deviceInfo,arr)
  3569. },
  3570. containKey(arr,key){
  3571. for (let i = 0; i < arr.length; i++) {
  3572. const data = arr[i];
  3573. if(data == key){
  3574. return true;
  3575. }
  3576. }
  3577. return false;
  3578. },
  3579. // 抽屉状态发生变化触发
  3580. change(e, type) {
  3581. console.log(e);
  3582. },
  3583. showDrawer() {
  3584. uni.navigateTo({
  3585. url: '/subpkg/device/setting?id='+this.id
  3586. });
  3587. // this.$refs.showLeft.open();
  3588. },
  3589. closeDrawer() {
  3590. this.$refs.showLeft.close();
  3591. },
  3592. checkItemValue(item){
  3593. if(!item.shadow){
  3594. item.shadow = 0;
  3595. }
  3596. if(!item.unit){
  3597. item.unit = "";
  3598. }
  3599. return true;
  3600. },
  3601. sendProperties(){
  3602. let properties = this.properties;
  3603. for (let i = 0; i < properties; i++) {
  3604. let property = this.properties[i];
  3605. let shadow = property.shadow;
  3606. if(shadow){
  3607. arr.push(property);
  3608. }
  3609. }
  3610. this.mqttPublish(1,this.deviceInfo,arr)
  3611. },
  3612. sendFunctions(){
  3613. let arr = [];
  3614. let functions = this.functions;
  3615. for (let i = 0; i < functions.length; i++) {
  3616. let functionObj = this.functions[i];
  3617. let shadow = functionObj.shadow;
  3618. if(shadow){
  3619. arr.push(functionObj);
  3620. }
  3621. }
  3622. this.mqttPublish(2,this.deviceInfo,arr)
  3623. },
  3624. changeProp(key,val){
  3625. let item = null;
  3626. let obj = null;
  3627. let oneToMul = this.oneToMul;
  3628. if(key === "LockControl"){
  3629. this.lock.value = val;
  3630. item = this.lock;
  3631. }else if(key === "PowerControl"){
  3632. this.power.value = val;
  3633. item = this.power;
  3634. }
  3635. let value = val;
  3636. obj = item.item;
  3637. if(value){
  3638. obj.value = 1;
  3639. obj.shadow = 1;
  3640. }else{
  3641. obj.value = 0;
  3642. obj.shadow = 0;
  3643. }
  3644. if(!oneToMul){
  3645. }
  3646. this.publishThingsModel(this.deviceInfo,obj);
  3647. },
  3648. checkCommonProp(item){
  3649. let id =item.id;
  3650. let isCommonKey = this.modelKey.some(res=>{
  3651. return id === res;
  3652. })
  3653. return !isCommonKey;
  3654. },
  3655. getRunTime(){
  3656. let self = this;
  3657. getDeviceRunTime(this.id).then(res=>{
  3658. self.timeobj = res.data;
  3659. if(!self.timeobj){
  3660. return;
  3661. }
  3662. if(self.timeobj.avgtime == ""){
  3663. self.timeobj.avgtime = 0;
  3664. }
  3665. if(self.timeobj.alltime == ""){
  3666. self.timeobj.alltime = 0;
  3667. }
  3668. })
  3669. },
  3670. seeTime(){
  3671. this.showTimeDlg = true;
  3672. this.getRunTime();
  3673. },
  3674. closeTime(){
  3675. this.showTimeDlg = false;
  3676. },
  3677. cancel(){
  3678. this.showErrDlg = false;
  3679. },
  3680. reportError(){
  3681. this.showErrDlg = true;
  3682. },
  3683. doReportError(){
  3684. if(!this.errorMsg){
  3685. this.$modal.showToast('异常信息不能为空')
  3686. }else{
  3687. let self = this;
  3688. let errObj = {};
  3689. errObj.deviceId = this.deviceInfo.deviceId;
  3690. errObj.deviceName = this.deviceInfo.deviceName
  3691. errObj.desc = this.errorMsg;
  3692. errObj.deptId= this.deviceInfo.deptId;
  3693. reportError(errObj).then(res=>{
  3694. self.$modal.showToast(res.msg)
  3695. self.cancel();
  3696. })
  3697. }
  3698. },
  3699. openLocation(){
  3700. uni.openLocation({
  3701. latitude: this.location.latitude,
  3702. longitude: this.location.longitude,
  3703. success: function () {
  3704. console.log('success');
  3705. }
  3706. });
  3707. },
  3708. confirmItemData(e){
  3709. let data = e.value[0];
  3710. this.show.text = data.text;
  3711. this.show.shadow=data.value;
  3712. this.show = null;
  3713. console.log(data);
  3714. },
  3715. send(){
  3716. let shadow = false
  3717. let _arr = []
  3718. this.inputProp.forEach((item)=>{
  3719. _arr.push(item.value)
  3720. })
  3721. // if(_arr.some(val => val === '' || val.length < 0)){
  3722. // shadow = true
  3723. // }
  3724. if(this.deviceInfo.status != 3){
  3725. uni.showToast({
  3726. title:"设备暂未上线",
  3727. icon:"error"
  3728. })
  3729. return;
  3730. }
  3731. if(shadow){
  3732. uni.showToast({
  3733. title:"数据不能为空",
  3734. icon:"error"
  3735. })
  3736. return;
  3737. }
  3738. this.publishThingsModel(this.deviceInfo,this.inputProp.map(item=>{return{"id":item.id,"value":item.value}}))
  3739. },
  3740. /** 更新设备状态 */
  3741. updateDeviceStatus(device) {
  3742. },
  3743. chooseItemData(data){
  3744. if(this.deviceInfo.status != 3){
  3745. uni.showToast({
  3746. title:"设备暂未上线",
  3747. icon:"error"
  3748. })
  3749. return;
  3750. }
  3751. this.columns = [data.enumList];
  3752. this.show =data;
  3753. },
  3754. getDetail(){
  3755. let self = this;
  3756. getDetail(this.id).then(res=>{
  3757. self.deviceInfo = res.data;
  3758. self.deviceType = res.data.type;
  3759. let msg = res.msg;
  3760. if(msg){
  3761. try{
  3762. msg = JSON.parse(msg+"");
  3763. }catch (e){
  3764. msg = null;
  3765. }
  3766. }
  3767. let productId = self.deviceInfo.productId;
  3768. if(productId === 57){
  3769. self.boardType = 6;
  3770. }
  3771. let online = self.deviceInfo.status == 3?true:false;
  3772. if(!online){
  3773. if(!self.onlineStatus){
  3774. uni.showModal({
  3775. title: '系统提示',
  3776. content: "设备未在线,无法操作",
  3777. confirmText: '确定',
  3778. showCancel:false,
  3779. success(res){
  3780. if(res.confirm){
  3781. self.onlineStatus = true;
  3782. }
  3783. },
  3784. })
  3785. }
  3786. }
  3787. if(msg != null){
  3788. let b = msg.b;
  3789. let c = msg.c;
  3790. let a = msg.a;
  3791. let d = msg.d;
  3792. if(a == 1){
  3793. self.firstMachine = true;
  3794. }else if(a == 0){
  3795. self.firstMachine = false;
  3796. }
  3797. if(b == 1){
  3798. self.secondMachine = true;
  3799. }else if(b == 0){
  3800. self.secondMachine = false;
  3801. }
  3802. if(c == 1){
  3803. self.thirdMachine = true;
  3804. }else if(c == 0){
  3805. self.thirdMachine = false;
  3806. }
  3807. if(d == 1){
  3808. self.forthMachine = true;
  3809. }else if(d==0){
  3810. self.forthMachine = false;
  3811. }
  3812. }
  3813. console.log("当前设备类型:"+JSON.stringify(self.deviceInfo.type))
  3814. self.location = {
  3815. latitude: self.deviceInfo.latitude,
  3816. longitude: self.deviceInfo.longitude};
  3817. self.sysDept = self.deviceInfo.sysDept;
  3818. self.parseSummay(res.data.summary)
  3819. self.mqttSubscribe(res.data);
  3820. self.getDeviceStatus();
  3821. self.seeTime();
  3822. let heng = false;
  3823. self.productImage = self.imgUrl+'/detail/product.png'
  3824. heng = self.setImage(self.deviceType);
  3825. let typeArr = [7,8,9,10,11,12,15];//单煎药机类型
  3826. for (let i = 0; i < typeArr.length; i++) {
  3827. let typeMa = typeArr[i];
  3828. if(typeMa == self.deviceType){
  3829. self.forthMachine = false;
  3830. }
  3831. }
  3832. self.fixImage(heng);
  3833. if(self.boardType == 4){
  3834. self.boardStyle = ";top:15vh;";
  3835. self.modeList=[[
  3836. {id:1,text:"1"},
  3837. {id:2,text:"2"}
  3838. ]];
  3839. }
  3840. self.$forceUpdate();
  3841. });
  3842. },
  3843. getDeviceStatus(func){
  3844. let self = this;
  3845. if(this.summary.length>1){
  3846. }else{
  3847. this.childId = 0;
  3848. }
  3849. uni.showLoading({title:"加载中"});
  3850. getDeviceStatus(this.id,this.childId).then(res=>{
  3851. let data =res.data;
  3852. this.deviceInfo = data;
  3853. self.parseStatusData(data)
  3854. self.getDevicePlanInfo();
  3855. setTimeout(function () {
  3856. uni.hideLoading();
  3857. if(typeof func == "function"){
  3858. func();
  3859. }
  3860. },50);
  3861. });
  3862. },
  3863. setImage(type){
  3864. let heng = false;
  3865. let self = this;
  3866. self.productImage = self.imgUrl+'/product/24.png'
  3867. return heng;
  3868. },
  3869. getNewDeviceStatus(item){
  3870. console.log(item);
  3871. let self = this;
  3872. if(item.index == 0){
  3873. this.firstTab = true;
  3874. this.getDeviceStatus();
  3875. }
  3876. if(item.index == 1){
  3877. this.firstTab = false;
  3878. getDeviceStatus(this.id,0).then(res=>{
  3879. let data =res.data;
  3880. this.deviceInfo = data;
  3881. self.parseStatusData(data)
  3882. });
  3883. }
  3884. },
  3885. changeSub(item){
  3886. this.childId = item.id;
  3887. this.getDeviceStatus()
  3888. },
  3889. parseEnumList(flag){
  3890. let enumList = this.deviceInfo.enumList;
  3891. for (let enumListElement of enumList) {
  3892. let id = enumListElement.id;
  3893. if(id == 'LockControl'){
  3894. let shadow = enumListElement.shadow;
  3895. this.lock.item = enumListElement;
  3896. if(shadow == 1){
  3897. this.lock.value = true;
  3898. this.lock.loading = false;
  3899. }else if(shadow == 0){
  3900. this.lock.value = false;
  3901. this.lock.loading = false;
  3902. }else{
  3903. this.lock.loading = true;
  3904. }
  3905. }
  3906. if(id == 'PowerControl'){
  3907. let shadow = enumListElement.shadow;
  3908. if(this.oneToMul){
  3909. if(!this.firstTab){
  3910. if(shadow == 1){
  3911. this.decoctControlOnOffStatus = true;
  3912. this.getDevicePlanInfo();
  3913. }else if(shadow == 0){
  3914. this.decoctControlOnOffStatus = false;
  3915. }
  3916. }
  3917. }else{
  3918. if(shadow == 1){
  3919. this.decoctControlOnOffStatus = true;
  3920. this.getDevicePlanInfo();
  3921. }else if(shadow == 0){
  3922. this.decoctControlOnOffStatus = false;
  3923. }
  3924. }
  3925. }
  3926. if(id == 'PowerCtl'){
  3927. if(this.oneToMul && this.firstTab){
  3928. let shadow = enumListElement.shadow;
  3929. if(shadow == 1){
  3930. this.decoctControlOnOffStatus = true;
  3931. this.getDevicePlanInfo();
  3932. }else if(shadow == 0){
  3933. this.decoctControlOnOffStatus = false;
  3934. }
  3935. }
  3936. }
  3937. if(id == 'MedicineType'){
  3938. let shadow = enumListElement.shadow;
  3939. if(!shadow){
  3940. shadow = 0;
  3941. }
  3942. let yaofangMap = {};
  3943. let enumList = enumListElement.enumList
  3944. for (let i = 0; i < enumList.length; i++) {
  3945. let yaofangEnum= enumList[i];
  3946. yaofangMap[yaofangEnum.value] = yaofangEnum.text;
  3947. }
  3948. this.yaofang = {
  3949. type:shadow,
  3950. name:yaofangMap[shadow+""]
  3951. }
  3952. }
  3953. this.formatValue(id,enumListElement,"PackagePowerControl","packageControlOnOffStatus")
  3954. this.formatValue(id,enumListElement,"DecoctingSwitch","decoctControlStatus")
  3955. this.formatValue(id,enumListElement,"CarrybagSwitch","qitingTurn")
  3956. this.formatValue(id,enumListElement,"WashSwitch","qingxiTurn")
  3957. this.formatValue(id,enumListElement,"PackageSwitch","baozhuangTurn");
  3958. this.formatValue(id,enumListElement,"DrainageTurn","drainageTurn");
  3959. //6号
  3960. this.formatValue(id,enumListElement,"WaterSwitch","jiashuiTurn");
  3961. this.formatValue(id,enumListElement,"HoldingSwitch","baowenTurn")
  3962. this.formatValue(id,enumListElement,"PauseStatus","pauseStatus")
  3963. this.formatValue(id,enumListElement,"SlowHighswitch","wenwuhuoTurn")
  3964. //pressTurn resetTurn
  3965. if(id == 'PressTurn'){
  3966. let shadow = enumListElement.shadow;
  3967. if(!shadow){
  3968. shadow = 0;
  3969. }
  3970. if(shadow == 1){
  3971. this.pressTurn = 1;
  3972. this.resetTurn = 0;
  3973. }else{
  3974. this.pressTurn = 0;
  3975. }
  3976. this.pressTurnChangeEvent(shadow);
  3977. }
  3978. if(id == 'ResetTurn'){
  3979. let shadow = enumListElement.shadow;
  3980. if(!shadow){
  3981. shadow = 0;
  3982. }
  3983. if(shadow == 1){
  3984. this.resetTurn = 1;
  3985. this.pressTurn = 0;
  3986. }else{
  3987. this.resetTurn = 0;
  3988. }
  3989. this.resetTurnChnageEvent(shadow);
  3990. }
  3991. if(id == 'WorkMode'){
  3992. let shadow = enumListElement.shadow;
  3993. if(!shadow){
  3994. shadow = 1;
  3995. }
  3996. this.workMode = shadow;
  3997. }
  3998. let shadow = enumListElement.shadow
  3999. let valueList = enumListElement.enumList;
  4000. for (let valueObj of valueList){
  4001. if(valueObj.value == shadow){
  4002. enumListElement.text = valueObj.text;
  4003. }
  4004. }
  4005. }
  4006. },
  4007. formatValue(id,enumListElement,key,propkey){
  4008. if(id == key){
  4009. let shadow = enumListElement.shadow;
  4010. if(shadow == 1){
  4011. this[propkey] = true;
  4012. }else if(shadow == 0){
  4013. this[propkey] = false;
  4014. }
  4015. }
  4016. },
  4017. parseStatusData(data){
  4018. let self = this;
  4019. cacheJsonThingsModel(data.productId).then(res=>{
  4020. let thingsModel = JSON.parse(res.data);
  4021. let arr = [];
  4022. let arrayList = data.arrayList;
  4023. arr = arr.concat(arrayList);
  4024. let enumList = data.enumList;
  4025. arr = arr.concat(enumList);
  4026. let integerList = data.integerList;
  4027. arr = arr.concat(integerList);
  4028. let stringList = data.stringList;
  4029. arr = arr.concat(stringList);
  4030. let decimalList =data.decimalList
  4031. arr = arr.concat(decimalList);
  4032. self.inputProp = arr;
  4033. for (let i = 0; i < thingsModel.functions.length; i++) {
  4034. for (let j = 0; j < arr.length; j++) {
  4035. let model = arr[j];
  4036. if(model.id == thingsModel.functions[i].id){
  4037. self.functions.push(model);
  4038. }
  4039. }
  4040. }
  4041. for (let i = 0; i < thingsModel.properties.length; i++) {
  4042. for (let j = 0; j < arr.length; j++) {
  4043. let model = arr[j];
  4044. if(model.id == thingsModel.properties[i].id){
  4045. self.properties.push(model);
  4046. }
  4047. }
  4048. }
  4049. let readOnlyList = data.readOnlyList;
  4050. self.watchProp = readOnlyList;
  4051. self.parseEnumList();
  4052. self.parseProp();
  4053. self.checkJianyao();
  4054. })
  4055. },
  4056. showJianyao(){
  4057. this.calcuStep();
  4058. this.planIngPopDlg = true;
  4059. },
  4060. parseProp(){
  4061. let self = this;
  4062. for (let i = 0; i <self.inputProp.length; i++) {
  4063. let prop = self.inputProp[i];
  4064. let value = prop.shadow||0;
  4065. let id = prop.id;
  4066. if(id === "TimeSetting"){//温度设置
  4067. self.temperatureTime = value;
  4068. }
  4069. if(!self.jianyaoWenduSetting){
  4070. if(id === "TempSetting"){
  4071. self.temperature = value;
  4072. }
  4073. }
  4074. if(id == "WaterVolume"){
  4075. this.waterVolume = parseInt(value)/10;
  4076. }
  4077. if(id == "SecondWaterVolume"){
  4078. this.secondWaterVolume = parseInt(value)/10;
  4079. }
  4080. if(id == "CurrentWaterVolume"){
  4081. this.currentWaterVolume = parseInt(value)/10;
  4082. }
  4083. this.setPropValue(id,"SlowfireTiem","leftJianyaoTime",value,0)
  4084. this.setPropValue(id,"HighTempTime","hightTemperature",value,0)
  4085. this.setPropValue(id,"CurrentTemp","currentTemperature",value,0)
  4086. this.setPropValue(id,"CalibrationTemp","jiaozhunTemp",value,0)
  4087. this.setPropValue(id,"PackingVolume","packageVolume",value,50)
  4088. this.setPropValue(id,"PackageQuantity","packageNumber",value,1)
  4089. this.setPropValue(id,"SecondTime","SecondTime",value,1)
  4090. this.setPropValue(id,"FirstTemp","FirstTemp",value,1)
  4091. this.setPropValue(id,"FirstTime","FirstTime",value,1)
  4092. //封边温度
  4093. this.setPropValue(id,"BandingTemp","edegTemperature",value);
  4094. this.setPropValue(id,"BandingTemp","tempFengBianWendu",value)
  4095. //封口温度
  4096. this.setPropValue(id,"SealTemp","sealingTemperature",value);
  4097. this.setPropValue(id,"SealTemp","tempFengKouWendu",value)
  4098. this.setPropValue(id,"LeftAppointmentTime","leftAppointmentTime",value,0)
  4099. this.setPropValue(id,"ValidCurrent","validCurrent",value,0)
  4100. this.setPropValue(id,"TurnCurrent","turnCurrent",value,0)
  4101. this.setPropValue(id,"HoldingTemp","baowenTemp",value,0)
  4102. this.setPropValue(id,"HoldingTime","baowenTime",value,0)
  4103. this.setPropValue(id,"AppointmentTime","planTime",value,0)
  4104. this.setPropValue(id,"TempSetFirst","tempSettingFirst",value,0)
  4105. this.setPropValue(id,"TimeSetFirst","timeSettingFirst",value,0)
  4106. this.setPropValue(id,"CurrentTimeSettingFirst","currentTimeSettingFirst",value,0)
  4107. this.setPropValue(id,"TimeSetSecond","timeSettingSecond",value,0)
  4108. this.setPropValue(id,"CurrentTimeSettingSecond","currentTimeSettingSecond",value,0)
  4109. this.setPropValue(id,"SecondAddWaterTime","secondAddWaterTime",value,0)
  4110. this.setPropValue(id,"CurrentSecondAddWaterTime","currentSecondAddWaterTime",value,0)
  4111. this.setPropValue(id,"JianyaoMode","jianyaoMode",value,0)
  4112. if(id == "FirstJianyaoMode"){
  4113. this.setPropValue(id,"FirstJianyaoMode","firstJianyaoMode",value,0)
  4114. this.setStatusHandler()
  4115. }
  4116. if(id == "SecondJianyaoMode"){
  4117. this.setPropValue(id,"SecondJianyaoMode","secondJianyaoMode",value,0)
  4118. this.setStatusHandler()
  4119. }
  4120. this.setPropValue(id,"LeftTransferTime","leftTransferTime",value,0)
  4121. self.propMap[id] = prop;
  4122. }
  4123. },
  4124. setPropValue(id,key,propKey,value,defaultValue){
  4125. if(!value && defaultValue){
  4126. value = defaultValue;
  4127. }
  4128. if(id === key){
  4129. this[propKey] = value;
  4130. }
  4131. },
  4132. parseSummay(summary){
  4133. let self = this;
  4134. if(!summary){
  4135. summary = "";
  4136. }
  4137. if(summary.length>0){
  4138. this.summary = JSON.parse(summary);
  4139. if(self.summary.length>0){
  4140. this.oneToMul = true;
  4141. for (let i = 0; i < self.summary.length; i++) {
  4142. self.summary[i].tabName = self.summary[i].name
  4143. }
  4144. let childId = "";
  4145. if(this.oneToMul){
  4146. this.childId = self.summary[0].id;
  4147. }
  4148. }else{
  4149. this.summary = [{name:"煎药机一"}]
  4150. }
  4151. }else{
  4152. this.summary = [{name:"煎药机一"}]
  4153. }
  4154. },
  4155. goDeviceDetail(id){
  4156. uni.navigateTo({
  4157. url: '/subpkg/device/detail/detail?id='+id
  4158. });
  4159. },
  4160. async connectMqtt() {
  4161. if (this.$mqttTool.client == null) {
  4162. await this.$mqttTool.connect(this.vuex_token);
  4163. }
  4164. this.mqttCallback();
  4165. this.startCheck();
  4166. },
  4167. /** Mqtt订阅主题 */
  4168. mqttSubscribe(device) {
  4169. // 订阅当前设备状态和实时监测
  4170. let topicStatus = '/' + device.productId + '/' + device.serialNumber + '/status/post';
  4171. let topicProperty = '/' + device.productId + '/' + device.serialNumber + '/property/post';
  4172. let topicFunction = '/' + device.productId + '/' + device.serialNumber + '/function/post';
  4173. let topics = [];
  4174. topics.push(topicStatus);
  4175. topics.push(topicProperty);
  4176. topics.push(topicFunction);
  4177. this.$mqttTool.subscribe(topics);
  4178. },
  4179. /** Mqtt取消订阅主题 */
  4180. mqttUnSubscribe(device) {
  4181. // 订阅当前设备状态和实时监测
  4182. let topicStatus = '/' + device.productId + '/' + device.serialNumber + '/status/post';
  4183. let topicProperty = '/' + device.productId + '/' + device.serialNumber + '/property/post';
  4184. let topicFunction = '/' + device.productId + '/' + device.serialNumber + '/function/post';
  4185. let topics = [];
  4186. topics.push(topicStatus);
  4187. topics.push(topicProperty);
  4188. topics.push(topicFunction);
  4189. console.log('取消订阅', topics);
  4190. this.$mqttTool.unsubscribe(topics);
  4191. },
  4192. /* Mqtt回调处理 */
  4193. mqttCallback() {
  4194. this.$mqttTool.client.on('message', (topic, message, buffer) => {
  4195. let topics = topic.split('/');
  4196. let productId = topics[1];
  4197. let deviceNum = topics[2];
  4198. console.log('接收到内容:'+message);
  4199. message = JSON.parse(message.toString());
  4200. if (topics[3] == 'status') {
  4201. console.log('接收到【设备状态-运行】主题:', topic);
  4202. console.log('接收到【设备状态-运行】内容:', message);
  4203. // 更新列表中设备的状态
  4204. if (this.deviceInfo.serialNumber == deviceNum) {
  4205. this.deviceInfo.status = message.status;
  4206. this.deviceInfo.isShadow = message.isShadow;
  4207. this.deviceInfo.rssi = message.rssi;
  4208. this.updateDeviceStatus(this.deviceInfo);
  4209. }
  4210. }
  4211. if (topics[3] == 'property' || topics[3] == 'function') {
  4212. console.log('接收到【物模型】主题:', topic);
  4213. console.log('接收到【物模型】内容:', message);
  4214. if(this.oneToMul){
  4215. let curTabId = this.childId;
  4216. let msg = [];
  4217. for (let i = 0; i < message.length; i++) {
  4218. let curMsg = message[i];
  4219. let id = curMsg.id;
  4220. let ids = id.split("_");
  4221. let value = curMsg.value;
  4222. if(ids.length == 2){
  4223. if(curTabId == ids[1]){
  4224. msg.push({id:ids[0],value:value});
  4225. }
  4226. }else{
  4227. msg.push(curMsg);
  4228. }
  4229. }
  4230. message = msg;
  4231. }
  4232. // 更新列表中设备的属性
  4233. if (this.deviceInfo.serialNumber == deviceNum) {
  4234. for (let j = 0; j < message.length; j++) {
  4235. let isComplete = false;
  4236. let msgId = message[j].id;
  4237. this.exchangeData(msgId,message[j]);
  4238. // 布尔类型
  4239. if(this.deviceInfo.boolList == null){
  4240. return;
  4241. }
  4242. for (let k = 0; k < this.deviceInfo.boolList.length && !isComplete; k++) {
  4243. if (this.deviceInfo.boolList[k].id == message[j].id) {
  4244. this.deviceInfo.boolList[k].shadow = message[j].value;
  4245. isComplete = true;
  4246. break;
  4247. }
  4248. }
  4249. // 枚举类型
  4250. for (let k = 0; k < this.deviceInfo.enumList.length && !isComplete; k++) {
  4251. if (this.deviceInfo.enumList[k].id == message[j].id) {
  4252. this.deviceInfo.enumList[k].shadow = message[j].value;
  4253. isComplete = true;
  4254. break;
  4255. }
  4256. }
  4257. // 字符串类型
  4258. for (let k = 0; k < this.deviceInfo.stringList.length && !isComplete; k++) {
  4259. if (this.deviceInfo.stringList[k].id == message[j].id) {
  4260. this.deviceInfo.stringList[k].shadow = message[j].value;
  4261. isComplete = true;
  4262. break;
  4263. }
  4264. }
  4265. // 数组类型
  4266. for (let k = 0; k < this.deviceInfo.arrayList.length && !isComplete; k++) {
  4267. if (this.deviceInfo.arrayList[k].id == message[j].id) {
  4268. this.deviceInfo.arrayList[k].shadow = message[j].value;
  4269. isComplete = true;
  4270. break;
  4271. }
  4272. }
  4273. // 整数类型
  4274. for (let k = 0; k < this.deviceInfo.integerList.length && !isComplete; k++) {
  4275. if (this.deviceInfo.integerList[k].id == message[j].id) {
  4276. this.deviceInfo.integerList[k].shadow = message[j].value;
  4277. isComplete = true;
  4278. break;
  4279. }
  4280. }
  4281. // 小数类型
  4282. for (let k = 0; k < this.deviceInfo.decimalList.length && !isComplete; k++) {
  4283. if (this.deviceInfo.decimalList[k].id == message[j].id) {
  4284. this.deviceInfo.decimalList[k].shadow = message[j].value;
  4285. isComplete = true;
  4286. break;
  4287. }
  4288. }
  4289. // 监测数据
  4290. for (let k = 0; k < this.deviceInfo.readOnlyList.length && !isComplete; k++) {
  4291. if (this.deviceInfo.readOnlyList[k].id == message[j].id) {
  4292. this.deviceInfo.readOnlyList[k].shadow = message[j].value;
  4293. // 更新图表
  4294. // for (let m = 0; m < this.monitorChart.length; m++) {
  4295. // if (message[j].id == this.monitorChart[m].data.id) {
  4296. // let data = [{
  4297. // value: message[j].value,
  4298. // name: this.monitorChart[m].data.name
  4299. // }];
  4300. // this.monitorChart[m].chart.setOption({
  4301. // series: [{
  4302. // data: data
  4303. // }]
  4304. // });
  4305. // break;
  4306. // }
  4307. // }
  4308. isComplete = true;
  4309. break;
  4310. }
  4311. }
  4312. }
  4313. this.parseEnumList(true);
  4314. this.checkJianyao();
  4315. if(this.planIngPopDlg){
  4316. this.calcuStep();
  4317. }
  4318. }
  4319. this.$forceUpdate();
  4320. }
  4321. });
  4322. },
  4323. checkJianyao(){
  4324. },
  4325. exchangeData(msgId,obj){
  4326. if(msgId === "TempSetting"){
  4327. this.temperature = obj.value;
  4328. }
  4329. if(msgId === "TimeSetting"){
  4330. this.temperatureTime = obj.value;
  4331. }
  4332. if(msgId === "CurrentTemp"){
  4333. this.currentTemperature = obj.value;
  4334. }
  4335. if(msgId === "HighTempTime"){
  4336. this.hightTemperature = obj.value;
  4337. }
  4338. if(msgId === "SealTemp"){//封口温度
  4339. if(!this.editing){
  4340. if(this.baozhuangFengkouSetting){
  4341. this.tempFengkouWendu = obj.value;
  4342. }else{
  4343. this.sealingTemperature = obj.value;
  4344. }
  4345. }
  4346. }
  4347. if(msgId === "BandingTemp"){//封边温度
  4348. if(!this.editing){
  4349. if(this.baozhuangFengbianSetting){
  4350. this.tempFengBianWendu = obj.value;
  4351. }else{
  4352. this.edegTemperature = obj.value;
  4353. }
  4354. }
  4355. }
  4356. if(msgId === "PackingVolume"){
  4357. if(!this.editing){
  4358. if(this.baozhuangRongLiangSetting){
  4359. }else{
  4360. this.packageVolume = obj.value;
  4361. }
  4362. }
  4363. }
  4364. if(msgId === "PackageQuantity"){
  4365. if(!this.editing){
  4366. if(this.baozhuangShuLIangSetting){
  4367. }else{
  4368. this.packageNumber = obj.value;
  4369. }
  4370. }
  4371. }
  4372. if(msgId === "LeftAppointmentTime"){
  4373. this.leftAppointmentTime = obj.value;
  4374. }
  4375. if(msgId === "SlowfireTiem"){
  4376. this.leftJianyaoTime = obj.value;
  4377. }
  4378. if(msgId === "CalibrationTemp"){
  4379. this.jiaozhunTemp = obj.value;
  4380. }
  4381. if(msgId === "TurnCurrent"){
  4382. this.turnCurrent = obj.value;
  4383. }
  4384. if(msgId === "ValidCurrent"){
  4385. this.validCurrent = obj.value;
  4386. }
  4387. if(msgId === "WaterVolume"){
  4388. this.waterVolume = parseInt(obj.value)/10;
  4389. }
  4390. if(msgId === "CurrentWaterVolume"){
  4391. this.currentWaterVolume = parseInt(obj.value)/10;
  4392. }
  4393. if(msgId === "HoldingTemp"){
  4394. this.baowenTemp = obj.value;
  4395. }
  4396. if(msgId === "HoldingTime"){
  4397. this.baowenTime = obj.value
  4398. }
  4399. if(msgId === "AppointmentTime"){
  4400. this.planTime = obj.value
  4401. }
  4402. if(msgId === "PressTurn"){
  4403. this.pressTurn = obj.value
  4404. }
  4405. if(msgId === "ResetTurn"){
  4406. this.resetTurn = obj.value
  4407. }
  4408. if(msgId === "DrainageTurn"){
  4409. this.drainageTurn = obj.value
  4410. }
  4411. if(msgId === "TimeSetFirst"){
  4412. this.timeSettingFirst = obj.value;
  4413. }
  4414. if(msgId === "CurrentTimeSettingFirst"){
  4415. this.currentTimeSettingFirst = obj.value;
  4416. }
  4417. if(msgId === "TimeSetSecond"){
  4418. this.timeSettingSecond = obj.value;
  4419. }
  4420. if(msgId === "CurrentTimeSettingSecond"){
  4421. this.currentTimeSettingSecond = obj.value;
  4422. }
  4423. if(msgId === "SecondAddWaterTime"){
  4424. this.secondAddWaterTime = obj.value;
  4425. }
  4426. if(msgId === "CurrentSecondAddWaterTime"){
  4427. this.currentSecondAddWaterTime = obj.value;
  4428. }
  4429. if(msgId == "JianyaoMode"){
  4430. this.jianyaoMode = obj.value;
  4431. }
  4432. if(msgId == "FirstJianyaoMode"){
  4433. this.firstJianyaoMode = obj.value;
  4434. this.setStatusHandler()
  4435. }
  4436. if(msgId == "SecondJianyaoMode"){
  4437. this.secondJianyaoMode = obj.value;
  4438. setTimeout(()=>{
  4439. this.setStatusHandler()
  4440. })
  4441. }
  4442. if(msgId == "LeftTransferTime"){
  4443. this.leftTransferTime = obj.value
  4444. }
  4445. if(msgId == "SecondTime"){
  4446. this.SecondTime = obj.value
  4447. }
  4448. if(msgId == "FirstTemp"){
  4449. this.FirstTemp = obj.value
  4450. }
  4451. if(msgId == "FirstTime"){
  4452. this.FirstTime = obj.value
  4453. }
  4454. if(msgId == "SecondWaterVolume"){
  4455. this.secondWaterVolume = parseInt(obj.value)/10;
  4456. }
  4457. if(msgId == "TempSetFirst"){
  4458. this.tempSettingFirst = obj.value
  4459. }
  4460. },
  4461. /** 发布物模型 类型(1=属性,2=功能) */
  4462. publishThingsModel(device, model) {
  4463. // 获取缓存的Json物模型
  4464. cacheJsonThingsModel(device.productId).then(response => {
  4465. let thingsModel = JSON.parse(response.data);
  4466. let type = 0;
  4467. for (let i = 0; i < thingsModel.functions.length; i++) {
  4468. if (model.id == thingsModel.functions[i].id) {
  4469. type = 2;
  4470. break;
  4471. }
  4472. }
  4473. if (type == 0) {
  4474. for (let i = 0; i < thingsModel.properties.length; i++) {
  4475. if (model.id == thingsModel.properties[i].id) {
  4476. type = 1;
  4477. break;
  4478. }
  4479. }
  4480. }
  4481. if (type != 0) {
  4482. this.mqttPublish(type, device, [model]);
  4483. }
  4484. });
  4485. },
  4486. notifyError(res){
  4487. uni.showToast({
  4488. title:res,
  4489. icon:"error"
  4490. })
  4491. },
  4492. notifySuccess(res){
  4493. uni.showToast({
  4494. title:res,
  4495. icon:"success"
  4496. })
  4497. },
  4498. getDownloadUrl(path){
  4499. return this.firmware.downUrl +"/iot/tool/download?fileName="+ path;
  4500. },
  4501. /**
  4502. * Mqtt发布消息
  4503. * @type 类型(1=属性,2=功能,3=OTA升级,4=实时监测)
  4504. * @device 设备
  4505. * @model 物模型
  4506. * */
  4507. mqttPublish(type, device, modelList,needMore) {
  4508. if(this.deviceInfo.status != 3){
  4509. this.notifyError("请等待设备上线后操作")
  4510. return;
  4511. }
  4512. if(modelList.length == 0){
  4513. return;
  4514. }
  4515. let topic = "";
  4516. let message = ""
  4517. let oneToMul = false;
  4518. if(this.summary.length>1){
  4519. oneToMul = true;
  4520. }
  4521. if(!needMore){
  4522. oneToMul = false;
  4523. }
  4524. if(this.firstTab){
  4525. let isKaijiKey = false;
  4526. if(modelList.length >0){
  4527. let modelData = modelList[0];
  4528. let curKeyId = modelData.id;
  4529. if(!this.decoctControlOnOffStatus){
  4530. if(oneToMul){
  4531. if(curKeyId == 'PowerCtl'){
  4532. isKaijiKey = true;
  4533. }
  4534. }else{
  4535. if(curKeyId == 'PowerControl'){
  4536. isKaijiKey = true;
  4537. }
  4538. }
  4539. }else{
  4540. isKaijiKey = true;
  4541. }
  4542. }
  4543. // if(!isKaijiKey){
  4544. // this.notifyError("请先开机后再进行操作")
  4545. // return;
  4546. // }
  4547. }else{
  4548. let isKaijiKey = false;
  4549. if(modelList.length >0){
  4550. let modelData = modelList[0];
  4551. let curKeyId = modelData.id;
  4552. if(!this.packageControlOnOffStatus){
  4553. if(curKeyId == 'PackagePowerControl'){
  4554. isKaijiKey = true;
  4555. }
  4556. }else{
  4557. isKaijiKey = true;
  4558. }
  4559. }
  4560. if(!isKaijiKey){
  4561. this.notifyError("请先开机后再进行操作")
  4562. return;
  4563. }
  4564. }
  4565. if (type == 1) {
  4566. if (device.status == 3) {
  4567. // 属性,在线模式
  4568. topic = "/" + device.productId + "/" + device.serialNumber + "/property-online/get";
  4569. }
  4570. } else if (type == 2) {
  4571. if (device.status == 3) {
  4572. // 功能,在线模式
  4573. topic = "/" + device.productId + "/" + device.serialNumber + "/function-online/get";
  4574. }
  4575. } else if (type == 3) {
  4576. // OTA升级
  4577. topic = "/" + device.productId + "/" + device.serialNumber + "/ota/get";
  4578. } else {
  4579. return;
  4580. }
  4581. let title = "";
  4582. if(type == 1){
  4583. title = "属性";
  4584. }else if(type == 2){
  4585. title = "功能";
  4586. }else if(type == 3){
  4587. title = "升级";
  4588. }
  4589. if (topic != "") {
  4590. // 发布
  4591. let arr = [];
  4592. for (let i = 0; i <modelList.length; i++) {
  4593. let model = modelList[i];
  4594. let modelId = model.id;
  4595. if(oneToMul){
  4596. let childId = this.childId;
  4597. if(childId){
  4598. modelId = modelId+"_"+childId;
  4599. }
  4600. }
  4601. let shadow = model.shadow+"";
  4602. let modelType = model.type;
  4603. let shadowInt = parseInt(shadow,10);
  4604. let isNumber = false;
  4605. let shadowStr = shadowInt+"";
  4606. if(shadowStr === shadow){
  4607. isNumber = true;
  4608. shadow = shadowInt;
  4609. }
  4610. if(modelType == "integer" && !isNumber){
  4611. this.$modal.showToast(model.name+'的值必须是数字类型')
  4612. return;
  4613. }
  4614. arr.push({id:modelId,value:shadow+""});
  4615. }
  4616. message = JSON.stringify(arr);
  4617. let self = this;
  4618. this.$mqttTool.publish(topic, message,title).then(res => {
  4619. this.notifySuccess(res);
  4620. }).catch(res => {
  4621. this.notifyError(res);
  4622. });
  4623. }
  4624. },
  4625. startCheck(){
  4626. let self = this;
  4627. this.checkTimer = setTimeout(function (){
  4628. self.sendHeart();
  4629. self.startCheck();
  4630. },20000);
  4631. },
  4632. checkActive(){
  4633. let self = this;
  4634. setTimeout(function (){
  4635. if(self.publishMsg){
  4636. self.resetConn()
  4637. }
  4638. },3000);
  4639. },
  4640. sendHeart(){
  4641. console.log("发送心跳111")
  4642. let device = this.deviceInfo;
  4643. let self = this;
  4644. let topic = "/property-offline/post";
  4645. self.publishMsg = true;
  4646. self.checkActive();
  4647. this.$mqttTool.publish(topic, "ok", "heart").then(res => {
  4648. self.publishMsg = false;
  4649. }).catch(res => {
  4650. self.publishMsg = false;
  4651. });
  4652. },
  4653. resetConn(){
  4654. console.log("检测异常,重连")
  4655. this.$mqttTool.end();
  4656. this.$mqttTool.client = null;
  4657. this.connectMqtt();
  4658. this.getDetail();
  4659. }
  4660. }
  4661. }
  4662. </script>
  4663. <style>
  4664. .send_btn{
  4665. width: 160rpx !important;
  4666. height: 40rpx !important;
  4667. font-size: 10px !important;
  4668. margin-top: 5px;
  4669. }
  4670. uni-col{
  4671. width: 150px;
  4672. }
  4673. .header{
  4674. width: 100%;
  4675. background: white;
  4676. padding:0px 20rpx;
  4677. position: relative;
  4678. height: 100vh;
  4679. position: relative;
  4680. }
  4681. .content {
  4682. display: flex;
  4683. align-items: center;
  4684. justify-content: center;
  4685. color: #060B25;
  4686. }
  4687. .logo {
  4688. height: 200rpx;
  4689. width: 200rpx;
  4690. margin-top: 200rpx;
  4691. margin-left: auto;
  4692. margin-right: auto;
  4693. margin-bottom: 50rpx;
  4694. }
  4695. .text-area {
  4696. margin:10px;
  4697. padding-bottom: 10px;
  4698. justify-content: center;
  4699. width: 100%;
  4700. }
  4701. .grid-text {
  4702. font-size: 14px;
  4703. color: #909399;
  4704. padding: 10rpx 0 20rpx 0rpx;
  4705. /* #ifndef APP-PLUS */
  4706. box-sizing: border-box;
  4707. /* #endif */
  4708. }
  4709. .title {
  4710. font-size: 36rpx;
  4711. color: #8f8f94;
  4712. }
  4713. .item{
  4714. height: 80rpx;
  4715. line-height: 80rpx;
  4716. }
  4717. .bg{
  4718. position: relative;
  4719. }
  4720. .text-left{
  4721. color: #8A92A5;
  4722. }
  4723. .text-right{
  4724. color: #545454;
  4725. }
  4726. .prop-text{
  4727. position: relative;
  4728. margin:20rpx 0;
  4729. font-size: 26rpx;
  4730. }
  4731. .prop-card-area{
  4732. }
  4733. .prop-card{
  4734. width: 28%;
  4735. height: 100rpx;
  4736. text-align: center;
  4737. display: inline-block;
  4738. background: #F5FCFF;
  4739. box-shadow: 0px 9rpx 8rpx 0px rgba(0,0,0,0.09);
  4740. border-radius: 8rpx;
  4741. margin:0px 15rpx;
  4742. line-height: 48rpx;
  4743. }
  4744. .prop-card-top{
  4745. color: #3E9CFC;
  4746. }
  4747. .prop-card-bottom{
  4748. color: #8A92A5;
  4749. }
  4750. .tab-area {
  4751. background: white;
  4752. position: absolute;
  4753. left: 0px;
  4754. right: 0px;
  4755. top:480rpx;
  4756. bottom:-20px;
  4757. min-height: 200rpx;
  4758. box-shadow: 0rpx 5rpx 27rpx 0rpx rgba(195, 195, 195, 0.4);
  4759. border-radius: 40rpx;
  4760. overflow-y: auto;
  4761. padding-bottom:80rpx;
  4762. }
  4763. .prop-item{
  4764. position: relative;
  4765. display: flex;
  4766. flex-direction: row;
  4767. height: 100rpx;
  4768. line-height: 100rpx;
  4769. margin:0 20rpx;
  4770. }
  4771. .prop-item-left{
  4772. color: #545454;
  4773. width: 100%;
  4774. font-size: 16px;
  4775. border-bottom: 1px solid lightgray;
  4776. margin-left: 120rpx;
  4777. }
  4778. .prop-item-image{
  4779. width: 120rpx;
  4780. height: 120rpx;
  4781. position: absolute;
  4782. bottom:-10rpx;
  4783. }
  4784. .prop-item-right{
  4785. position: absolute;
  4786. right:10rpx;
  4787. top:5rpx;
  4788. }
  4789. input::-webkit-input-placeholder,textarea::-webkit-input-placeholder{
  4790. color:#666;
  4791. font-size:12px;
  4792. }
  4793. .clearfix::after {
  4794. content: "";
  4795. display: block;
  4796. clear: both;
  4797. }
  4798. .decoctControlHeader {
  4799. display: flex;
  4800. align-items: center;
  4801. font-weight: 600;
  4802. }
  4803. .decoctControlTop {
  4804. display: flex;
  4805. height: 240rpx;
  4806. border-bottom:1px #B2B2B2 dotted;
  4807. margin:0 40rpx;
  4808. }
  4809. .decoctControlTopLeft {
  4810. width:40%;
  4811. line-height: 2;
  4812. text-align: center;
  4813. margin: 0 15px;
  4814. position: relative;
  4815. }
  4816. .addTemperature {
  4817. border-radius:5px;
  4818. position:absolute;
  4819. background-color: dodgerblue;
  4820. color:white;
  4821. width: 30px;
  4822. height: 30px;
  4823. left:15px;
  4824. top:80px;
  4825. }
  4826. .addTemperatureBtn {
  4827. border-radius:10px;
  4828. position:absolute;
  4829. clip-path: polygon(50% 0,100% 100%,0 100%);
  4830. transform: scale(0.5);
  4831. left: 0;
  4832. top:0;
  4833. bottom: 0;
  4834. right: 0;
  4835. margin: auto;
  4836. }
  4837. .subTemperature {
  4838. border-radius:5px;
  4839. position:absolute;
  4840. background-color: dodgerblue;
  4841. color:white;
  4842. width: 30px;
  4843. height: 30px;
  4844. right:15px;
  4845. top:80px;
  4846. }
  4847. .subTemperatureBtn {
  4848. border-radius:10px;
  4849. position:absolute;
  4850. clip-path: polygon(50% 0,100% 100%,0 100%);
  4851. transform: scale(0.5);
  4852. left: 0;
  4853. top:0;
  4854. bottom: 0;
  4855. right: 0;
  4856. margin: auto;
  4857. }
  4858. .decoctControlTopRight {
  4859. width:40%;
  4860. line-height: 2;
  4861. text-align: center;
  4862. margin: 0 15px;
  4863. position: relative;
  4864. }
  4865. .decoctControlBottom {
  4866. border-bottom:1px #B2B2B2 dotted;
  4867. width:91vw;
  4868. margin:0 auto;
  4869. padding:10px;
  4870. display: flex;
  4871. justify-content:space-between;
  4872. align-items: center;
  4873. }
  4874. .addTime {
  4875. border-radius:5px;
  4876. position:absolute;
  4877. background-color: dodgerblue;
  4878. color:white;
  4879. width: 30px;
  4880. height: 30px;
  4881. left:15px;
  4882. top:80px;
  4883. }
  4884. .addTimeBtn {
  4885. border-radius:10px;
  4886. position:absolute;
  4887. clip-path: polygon(50% 0,100% 100%,0 100%);
  4888. transform: scale(0.5);
  4889. left: 0;
  4890. top:0;
  4891. bottom: 0;
  4892. right: 0;
  4893. margin: auto;
  4894. }
  4895. .subTime {
  4896. border-radius:5px;
  4897. position:absolute;
  4898. background-color: dodgerblue;
  4899. color:white;
  4900. width: 30px;
  4901. height: 30px;
  4902. right:15px;
  4903. top:80px;
  4904. }
  4905. .subTimeBtn {
  4906. border-radius:10px;
  4907. position:absolute;
  4908. clip-path: polygon(50% 0,100% 100%,0 100%);
  4909. transform: scale(0.5);
  4910. left: 0;
  4911. top:0;
  4912. bottom: 0;
  4913. right: 0;
  4914. margin: auto;
  4915. }
  4916. .packageControlBottomRight {
  4917. border-radius:5px;
  4918. padding:5px 10px;
  4919. margin-right: 15px;
  4920. background-color: #3c9cff;
  4921. color: #fff;
  4922. }
  4923. .packageControlBottomClear {
  4924. border-radius:5px;
  4925. padding:5px 10px;
  4926. background-color: #B2B2B2;
  4927. color: #fff;
  4928. }
  4929. .active_btn{
  4930. background-color: #3c9cff;
  4931. }
  4932. .baozhuang-sub{
  4933. right: 10rpx !important;
  4934. }
  4935. .baozhuang-add{
  4936. left: 6rpx !important;
  4937. }
  4938. .control-input-box{
  4939. display: flex;
  4940. flex-direction: row;
  4941. padding-left: 26rpx;
  4942. }
  4943. .control-input-box-danwei{
  4944. padding-top:12rpx;
  4945. margin-left:4rpx;
  4946. }
  4947. .tabs{
  4948. position: relative;
  4949. top:15vh;
  4950. }
  4951. .child_tab{
  4952. position: relative;
  4953. display: inline-block;
  4954. width: 25%;
  4955. height: 180rpx;
  4956. }
  4957. .child_img{
  4958. width: 50rpx;
  4959. height: 50rpx;
  4960. left: 66rpx;
  4961. top: 66rpx;
  4962. position: relative;
  4963. }
  4964. .child_title{
  4965. position: absolute;
  4966. left: 0px;
  4967. right: 0px;
  4968. text-align: center;
  4969. font-size: 12px;
  4970. bottom: -12rpx;
  4971. color: #060B25;
  4972. }
  4973. .control{
  4974. width: 100%;
  4975. position: relative;
  4976. }
  4977. .control_item{
  4978. position: relative;
  4979. width: 50%;
  4980. display: inline-block;
  4981. height: 150rpx;
  4982. }
  4983. .control_item_detail{
  4984. position: relative;
  4985. top:22rpx;
  4986. }
  4987. .control_item_left{
  4988. position:absolute;;
  4989. left:22%;
  4990. font-size: 55px;
  4991. z-index: 999;
  4992. top:-30rpx
  4993. }
  4994. .control_item_center{
  4995. position:absolute;;
  4996. left:34%;
  4997. top:0vh;
  4998. }
  4999. .control_item_right{
  5000. position:absolute;;
  5001. left:67%;
  5002. font-size: 34px;
  5003. z-index: 999;
  5004. }
  5005. .control_item_center_unit{
  5006. position: absolute;
  5007. left:26vw;
  5008. top: 0.8vh;
  5009. width:200rpx;
  5010. }
  5011. .control_item_title{
  5012. position: absolute;
  5013. bottom:34rpx;
  5014. font-size: 12px;
  5015. width: 100%;
  5016. text-align: center;
  5017. }
  5018. .bottom{
  5019. height: 190rpx;
  5020. position: absolute;
  5021. left: 0px;
  5022. width: 100%;
  5023. padding-top: 18rpx;
  5024. bottom: -8vh;
  5025. }
  5026. .bottom_item{
  5027. display: inline-block;
  5028. width: 20%;
  5029. font-size: 12px;
  5030. height: 100%;
  5031. position: relative;
  5032. text-align: center;
  5033. margin-top: 2vh;
  5034. }
  5035. .active_on{
  5036. color: #50ACFF;
  5037. }
  5038. .status_info{
  5039. position: absolute;
  5040. left: 5vw;
  5041. top: 10vh;
  5042. }
  5043. .status_detail{
  5044. display: flex;
  5045. flex-direction: row;
  5046. }
  5047. .status_text{
  5048. font-size: 16px;
  5049. }
  5050. .online_text{
  5051. font-size: 12px;
  5052. padding-top: 3px;
  5053. }
  5054. .online{
  5055. color: #017128;
  5056. }
  5057. .device_info{
  5058. font-size: 13px;
  5059. }
  5060. .control_area{
  5061. position: relative;
  5062. top:14vh;
  5063. }
  5064. .disabled_tab{
  5065. opacity: 0.4;
  5066. }
  5067. .roate{
  5068. transform: rotate(180deg);
  5069. }
  5070. </style>