main.html 166 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386338733883389339033913392339333943395339633973398339934003401340234033404340534063407340834093410341134123413341434153416341734183419342034213422342334243425342634273428342934303431343234333434343534363437343834393440344134423443344434453446344734483449345034513452345334543455345634573458345934603461346234633464346534663467346834693470347134723473347434753476347734783479348034813482348334843485348634873488348934903491349234933494349534963497349834993500350135023503350435053506350735083509351035113512351335143515351635173518351935203521352235233524352535263527352835293530353135323533353435353536353735383539354035413542354335443545354635473548354935503551355235533554355535563557355835593560356135623563356435653566356735683569357035713572357335743575
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="utf-8">
  5. <title></title>
  6. <link rel="stylesheet" type="text/css" href="css/main.css">
  7. <link rel="stylesheet" type="text/css" href="css/jquery-ui.css">
  8. </head>
  9. <body onclick="$('#imp_item,#date_select,#day_select').hide();$('#search_result').html('').hide();$('#search input').val('')">
  10. <div id="loading_a1"></div>
  11. <div id="loading">正在加载模型中...</div>
  12. <div for="FAC" id="top" class="top topfac">
  13. <div title="返回主视图"
  14. style="cursor: pointer;position: absolute;right: 10px;top: 25px;height: 38px;width: 38px;text-align: center;"
  15. onclick="backMasterView()"><img src="image/view.png"></div>
  16. </div>
  17. <div for="IN03" id="top" class="top top03 hideDiv">
  18. <div title="返回主视图"
  19. style="cursor: pointer;position: absolute;right: 10px;top: 25px;height: 38px;width: 38px;text-align: center;"
  20. onclick="backMasterView()"><img src="image/view.png"></div>
  21. </div>
  22. <div for="IN02" id="top" class="top top02 hideDiv">
  23. <div id="maogao_btn" title=""
  24. style="cursor: pointer;position: absolute;right: 176px;top: 25px;height: 38px;width: 38px;"><IMG
  25. src="image/menu1.png"></div>
  26. <div id="autoplayer_btn" title="切换自动漫游"
  27. style="cursor: pointer;position: absolute;right: 120px;top: 25px;height: 38px;width: 38px;"><IMG
  28. src="image/auto3d_stop.png"></div>
  29. <div id="imp_btn" title="导出数据"
  30. style="cursor: pointer;position: absolute;right: 65px;top: 25px;height: 38px;width: 38px;"><IMG
  31. src="image/imp_icon.png"></div>
  32. <div title="返回主视图"
  33. style="cursor: pointer;position: absolute;right: 10px;top: 25px;height: 38px;width: 38px;text-align: center;"
  34. onclick="backMasterView()"><img src="image/view.png"></div>
  35. </div>
  36. <div for="IN02" id="imp_item">
  37. <div itemcode="1"><span>生产数据</span><img src="image/imp2.png" style="float: right;margin-top: 7px;"></div>
  38. <div itemcode="2"><span>停机原因</span><img src="image/imp2.png" style="float: right;margin-top: 7px;"></div>
  39. <div itemcode="4"><span>断纱分析</span><img src="image/imp2.png" style="float: right;margin-top: 7px;"></div>
  40. <div itemcode="3"><span>并发叫料分析</span><img src="image/imp2.png" style="float: right;margin-top: 7px;"></div>
  41. <div itemcode="5"><span>并发下卷分析</span><img src="image/imp2.png" style="float: right;margin-top: 7px;"></div>
  42. <div itemcode="6"><span>告警分析</span><img src="image/imp2.png" style="float: right;margin-top: 7px;"></div>
  43. <div itemcode="7"><span>平方米克重</span><img src="image/imp2.png" style="float: right;margin-top: 7px;"></div>
  44. <div itemcode="8"><span>送经量</span><img src="image/imp2.png" style="float: right;margin-top: 7px;"></div>
  45. <div itemcode="9"><span>纱线规格</span><img src="image/imp2.png" style="float: right;margin-top: 7px;"></div>
  46. <div itemcode="10"><span>生产绩效日报</span><img src="image/imp2.png" style="float: right;margin-top: 7px;"></div>
  47. <div itemcode="11"><span>生产绩效月报</span><img src="image/imp2.png" style="float: right;margin-top: 7px;"></div>
  48. <div itemcode="12"><span>车间能耗日报</span><img src="image/imp2.png" style="float: right;margin-top: 7px;"></div>
  49. <div itemcode="13"><span>车间能耗月报</span><img src="image/imp2.png" style="float: right;margin-top: 7px;"></div>
  50. <!-- <div itemcode="1"><span>最近7天</span><img src="image/imp2.png" style="float: right;margin-top: 7px;"></div>-->
  51. <!-- <div itemcode="2"><span>自定义日期</span><img src="image/imp2.png" style="float: right;margin-top: 7px;"></div>-->
  52. </div>
  53. <div for="IN02" id="date_select">
  54. <div class="triangle"></div>
  55. <div style="margin-top: 5px;">
  56. <label for="datepicker1">开始:</label>
  57. <input type="text" id="datepicker1" readonly="readonly" style="pointer-events: none;">
  58. </div>
  59. <div style="margin-top: 5px;" class="hourPointSelect">
  60. <select id="hourP1" style="margin-left: 45px;width: 173px;border-radius: 4px;height: 24px;"></select>
  61. </div>
  62. <div style="margin-top: 5px;">
  63. <label for="datepicker2">结束:</label>
  64. <input type="text" id="datepicker2" readonly="readonly" style="pointer-events: none;">
  65. </div>
  66. <div style="margin-top: 5px;" class="hourPointSelect">
  67. <select id="hourP2" style="margin-left: 45px;width: 173px;border-radius: 4px;height: 24px;"></select>
  68. </div>
  69. <div style="margin-top: 5px;" class="hourAreaSelect">
  70. <label>时间:</label>
  71. <select id="hour1" style="margin-left: 5px;width: 63px;"></select>
  72. <label>到</label>
  73. <select id="hour2" style="width: 63px;"></select>
  74. </div>
  75. <div style="margin-top: 5px; display: none;">
  76. <span>设备:</span><input id="imp_devcode" type="text" placeholder="设备编号" maxlength="4"
  77. style="width: 140px;margin-left: 8px;font-size: 12px;">
  78. </div>
  79. <div class="dateSelected_ok">
  80. <button type=button>确定</button>
  81. </div>
  82. </div>
  83. <div for="IN02" id="day_select">
  84. <div class="triangle"></div>
  85. <div style="margin-top: 5px;">
  86. <label for="datepicker1">产能预期天数:</label>
  87. <input type="text" id="prev_day" style="width: 50%;" imeMode="disabled" value="7" maxlength="2" placeholder="请输入小于61的正整数">
  88. </div>
  89. <div class="daySelected_ok">
  90. <button type=button>确定</button>
  91. </div>
  92. </div>
  93. <div for="IN02" id="search" class="hideDiv"><input type="text" placeholder="请输入设备编号" maxlength="4"><img
  94. style="position: absolute;top: 20%;right: 5px;" src="image/search_icon.png" class="search_btn"></div>
  95. <div id="search_result"></div>
  96. <!-- 添加呈现的video标签或img标签,并设置必要的css来控制其大小 -->
  97. <video id="EngineContent" autoplay muted style="width: 1920px;height:1080px;">浏览器不支持</video>
  98. <!-- <img id="EngineContent"></img> -->
  99. <div for="IN02" id="dev_state" class="hideDiv" show="设备状态">
  100. <div class="title"></div>
  101. <div class="content">
  102. <div style="float: left;width: 100%;margin-top: 10px;">
  103. <div title="设备总数"
  104. style="float: left;width: 45%;margin-left: 4%;background: linear-gradient( 89deg, rgba(33,62,117,0.8) 0%, rgba(33,62,117,0) 100%);">
  105. <img src="image/total_icon.png" style="float: left;width: 58px;">
  106. <span style="float: left;font-weight: 500;font-size: 15px;color: #9ED1FF;line-height: 22px;text-align: left;width: 60%;margin-left: 5%;">设备总数</span>
  107. <span id="dev_state_total"
  108. style="float: left;font-family: Bebas Neue, Bebas Neue;font-weight: 400;font-size: 30px;line-height: 30px;text-align: left;font-style: normal;text-transform: none;margin-left: 5%;color: #FFFFFF;">130</span>
  109. <span style="float: left;font-size: 22px;color: #49A8FF;">(台)</span>
  110. </div>
  111. <div title="运行数量"
  112. style="float: left;width: 45%;margin-left: 4%;background: linear-gradient( 89deg, rgba(33,62,117,0.8) 0%, rgba(33,62,117,0) 100%);cursor: pointer;"
  113. onclick="window.open(SERVER_URL + '/export/stop')">
  114. <img src="image/total_icon.png" style="float: left;width: 58px;">
  115. <span style="float: left;font-weight: 500;font-size: 15px;color: #9ED1FF;line-height: 22px;text-align: left;width: 60%;margin-left: 5%;">运行数量</span>
  116. <span id="dev_state_runtotal"
  117. style="float: left;font-family: Bebas Neue, Bebas Neue;font-weight: 400;font-size: 30px;line-height: 30px;text-align: left;font-style: normal;text-transform: none;margin-left: 5%;color: #FFFFFF;">45</span>
  118. <span style="float: left;font-size: 22px;color: #49A8FF;">(台)</span>
  119. </div>
  120. </div>
  121. <div class="stat" style="float: left;width: 100%;margin-top: 10px;">
  122. <div title="落米停机数" style="float: left;width: 33%;color: #FFB342;">
  123. <img src="image/t1.png" style="float: left;width: 40px;">
  124. <span class="number" attr="stop6"
  125. style="float: left;font-family: Bebas Neue, Bebas Neue;font-weight: 400;font-size: 20px;line-height: 30px;text-align: left;font-style: normal;text-transform: none;margin-left: 1%;">-</span>
  126. <span style="float: left;font-size: 15px;margin-top: 6px;">(台)</span>
  127. <span style="float: left;font-weight: 500;font-size: 14px;color: #FFFFFF;line-height: 22px;text-align: left;width: 65%;margin-left: 1%;">落米停机数</span>
  128. </div>
  129. <div title="断纱停机数" style="float: left;width: 33%;color: #FFB342;">
  130. <img src="image/t1.png" style="float: left;width: 40px;">
  131. <span class="number" attr="stop2"
  132. style="float: left;font-family: Bebas Neue, Bebas Neue;font-weight: 400;font-size: 20px;line-height: 30px;text-align: left;font-style: normal;text-transform: none;margin-left: 1%;color: #FFB342;">-</span>
  133. <span style="float: left;font-size: 15px;margin-top: 6px;">(台)</span>
  134. <span style="float: left;font-weight: 500;font-size: 14px;color: #FFFFFF;line-height: 22px;text-align: left;width: 65%;margin-left: 1%;">断纱停机数</span>
  135. </div>
  136. <div title="停经片停机数" style="float: left;width: 33%;color: #FFB342;">
  137. <img src="image/t1.png" style="float: left;width: 40px;">
  138. <span class="number" attr="stop1"
  139. style="float: left;font-family: Bebas Neue, Bebas Neue;font-weight: 400;font-size: 20px;line-height: 30px;text-align: left;font-style: normal;text-transform: none;margin-left: 1%;color: #FFB342;">-</span>
  140. <span style="float: left;font-size: 15px;margin-top: 6px;">(台)</span>
  141. <span style="float: left;font-weight: 500;font-size: 14px;color: #FFFFFF;line-height: 22px;text-align: left;width: 65%;margin-left: 1%;">停经片停机数</span>
  142. </div>
  143. <div title="叫料数" style="float: left;width: 33%;margin-top: 7px;color: #FFB342;">
  144. <img src="image/t1.png" style="float: left;width: 40px;">
  145. <span class="number" attr="stop8"
  146. style="float: left;font-family: Bebas Neue, Bebas Neue;font-weight: 700;font-size: 22px;line-height: 30px;text-align: left;font-style: normal;text-transform: none;margin-left: 1%;color: red;">-</span>
  147. <span style="float: left;font-size: 15px;margin-top: 6px;">(台)</span>
  148. <span style="float: left;font-weight: 500;font-size: 14px;color: #FFFFFF;line-height: 22px;text-align: left;width: 65%;margin-left: 1%;">叫料数</span>
  149. </div>
  150. <div title="其他停机数" style="float: left;width: 33%;margin-top: 7px;color: #FFB342;">
  151. <img src="image/t1.png" style="float: left;width: 40px;">
  152. <span class="number" attr="alarm"
  153. style="float: left;font-family: Bebas Neue, Bebas Neue;font-weight: 700;font-size: 22px;line-height: 30px;text-align: left;font-style: normal;text-transform: none;margin-left: 1%;color: red;">-</span>
  154. <span style="float: left;font-size: 15px;margin-top: 6px;">(台)</span>
  155. <span style="float: left;font-weight: 500;font-size: 14px;color: #FFFFFF;line-height: 22px;text-align: left;width: 65%;margin-left: 1%;">其他停机数</span>
  156. </div>
  157. <div title="盘头小于200圈" style="float: left;width: 33%;margin-top: 7px;color: #FFB342;">
  158. <img src="image/t1.png" style="float: left;width: 40px;">
  159. <span class="number" attr="stopPan"
  160. style="float: left;font-family: Bebas Neue, Bebas Neue;font-weight: 700;font-size: 22px;line-height: 30px;text-align: left;font-style: normal;text-transform: none;margin-left: 1%;color: red;">-</span>
  161. <span style="float: left;font-size: 15px;margin-top: 6px;">(台)</span>
  162. <span style="float: left;font-weight: 500;font-size: 12px;color: #FFFFFF;line-height: 22px;text-align: left;width: 65%;margin-left: 1%;">盘头小于200圈</span>
  163. </div>
  164. <div title="开机率" style="float: left;width: 33%;margin-top: 7px;color: #FFB342;">
  165. <img src="image/t1.png" style="float: left;width: 40px;">
  166. <span class="runningRatio" style="float: left;font-family: Bebas Neue, Bebas Neue;font-weight: 700;font-size: 22px;line-height: 30px;text-align: left;font-style: normal;text-transform: none;margin-left: 1%;color: red;">-</span>
  167. <span style="float: left;font-size: 15px;margin-top: 6px;">(%)</span>
  168. <span style="float: left;font-weight: 500;font-size: 12px;color: #FFFFFF;line-height: 22px;text-align: left;width: 65%;margin-left: 1%;">开机率</span>
  169. </div>
  170. </div>
  171. </div>
  172. </div>
  173. <div for="IN02" id="dev_alarm" class="hideDiv" show="当前告警" style="color: #ffffff;font-size: 14px;">
  174. <div class="title">当前无告警</div>
  175. <div class="content">
  176. <table style="width: 100%;font-weight: bold;" cellspacing=0>
  177. <thead>
  178. <tr>
  179. <td style="width: 30%">设备编号</td>
  180. <td style="width: 70%">告警类型</td>
  181. </tr>
  182. </thead>
  183. </table>
  184. <div style="height: 128px;width: 100%;overflow: hidden;">
  185. <table id="dev_alarm_list" style="width: 100%;background: rgba(25,57,103,0.3);" cellspacing=0>
  186. <tbody>
  187. <tr>
  188. <td style="width: 30%;color:red">-</td>
  189. <td style="width: 70%">-</td>
  190. </tr>
  191. </tbody>
  192. </table>
  193. </div>
  194. <div style="margin-top: 15px;">
  195. <div style="text-align: center;"><img src="image/alarm_txt.png"></div>
  196. <div class="echarts_alarm" id="echarts_alarm" style="height: 122px;width: 100%;">
  197. </div>
  198. </div>
  199. </div>
  200. </div>
  201. <div for="IN02" id="dev_stop" class="hideDiv" show="停机原因" style="color: #ffffff;font-size: 14px;">
  202. <div class="title">当前无机器停机</div>
  203. <div class="content">
  204. <div style="margin-top: 15px;">
  205. <div class="echarts_stop" id="echarts_stop" style="height: 190px;width: 100%;">
  206. </div>
  207. </div>
  208. </div>
  209. </div>
  210. <div for="IN02" id="dev_xiaolv" class="hideDiv" show="生产效率" style="color: #ffffff;font-size: 14px;">
  211. <div class="title"></div>
  212. <div class="content">
  213. <div style="">
  214. <div style="text-align: center;font-size: 16px;margin:16px 0;">今日产量</div>
  215. <div style="text-align: center;">
  216. <span style="width: 160px;text-align: center;display: inline-block;height: 32px;line-height: 32px;margin: 0 12px;padding: 5px;"><span
  217. id="totay1" style="font-size: 30px">-</span><span
  218. style="color: #9ED1FF;font-size: 16px">(米)</span></span>
  219. <span style="width: 128px;text-align: center;display: inline-block;height: 32px;line-height: 32px;margin: 0 12px;padding: 5px;"><span
  220. id="totay2" style="font-size: 30px">-</span><span
  221. style="color: #9ED1FF;font-size: 16px">(吨)</span></span>
  222. </div>
  223. </div>
  224. <div style="max-height: 96px;width: 100%;overflow: hidden;margin-top: 25px;">
  225. <table style="width: 100%;" cellspacing=0>
  226. <thead>
  227. <tr>
  228. <td style="width: 10%">班组</td>
  229. <td style="width: 25%">生产时间(H)</td>
  230. <td style="width: 25%">已织造数(米)</td>
  231. <td style="width: 20%">总重量(T)</td>
  232. <td style="width: 20%">稼动率(%)</td>
  233. </tr>
  234. </thead>
  235. <tbody>
  236. <tr id="scxl_a">
  237. <td style="width: 10%;color: #9ED1FF">A组</td>
  238. <td style="width: 25%;font-size: 18px;font-weight: bold;">12</td>
  239. <td style="width: 25%;font-size: 18px;font-weight: bold;">12000</td>
  240. <td style="width: 20%;font-size: 18px;font-weight: bold;">5.4</td>
  241. <td style="width: 20%;font-size: 18px;font-weight: bold;">100</td>
  242. </tr>
  243. <tr id="scxl_b">
  244. <td style="width: 10%;color: #9ED1FF">B组</td>
  245. <td style="width: 25%;font-size: 18px;font-weight: bold;">6</td>
  246. <td style="width: 25%;font-size: 18px;font-weight: bold;">2000</td>
  247. <td style="width: 20%;font-size: 18px;font-weight: bold;">1.2</td>
  248. <td style="width: 20%;font-size: 18px;font-weight: bold;">43</td>
  249. </tr>
  250. </tbody>
  251. </table>
  252. </div>
  253. </div>
  254. </div>
  255. <div for="IN02" id="dev_jiadonglv" class="hideDiv" show="稼动率周曲线" style="color: #ffffff;font-size: 14px;">
  256. <div class="title"></div>
  257. <div class="content">
  258. <div style="margin-top: 15px;">
  259. <div class="echarts_jiadonglv" id="echarts_jiadonglv" style="height: 142px;width: 100%;">
  260. </div>
  261. </div>
  262. </div>
  263. </div>
  264. <div for="IN02" id="dev_sc_qushi" class="hideDiv" show="生产趋势" style="color: #ffffff;font-size: 14px;">
  265. <div class="title"></div>
  266. <div class="content">
  267. <div style="margin-top: 15px;">
  268. <div class="echarts_sc_qushi" id="echarts_sc_qushi" style="height: 142px;width: 100%;">
  269. </div>
  270. </div>
  271. </div>
  272. </div>
  273. <div for="IN02" id="dev_used_qushi" class="hideDiv" show="能耗趋势" style="color: #ffffff;font-size: 14px;">
  274. <div class="title"></div>
  275. <div class="content">
  276. <div style="margin-top: 15px;">
  277. <div class="echarts_used_qushi" id="echarts_used_qushi" style="height: 142px;width: 100%;">
  278. </div>
  279. </div>
  280. </div>
  281. </div>
  282. <div id="nodevice" class="showinfo">
  283. <div class="title">
  284. <img src="image/title_icon.png" style="margin: 7px;float: left;">
  285. <span class="text">基本信息</span>
  286. <img src="image/Close.png" style="margin: 7px;float: right;cursor: pointer;" onclick="HideInfo()">
  287. </div>
  288. <div class="content" style="text-align: center;margin-top: 150px;font-size: 24px;color: orange;"></div>
  289. </div>
  290. <div id="showinfo" class="showinfo">
  291. <div class="title">
  292. <img src="image/title_icon.png" style="margin: 7px;float: left;">
  293. <span class="text">基本信息</span>
  294. <img src="image/Close.png" style="margin: 7px;float: right;cursor: pointer;" onclick="HideInfo()">
  295. </div>
  296. <div class="content">
  297. <div>
  298. <table style="width: 100%;text-align: center;" cellspacing="0" cellpadding="0">
  299. <tbody>
  300. <tr>
  301. <td colspan="10" style="font-size: 20px;font-weight: bold;color: #7d7d7d;padding: 5px 0;">剩余时间
  302. </td>
  303. </tr>
  304. <tr>
  305. <td>GB1(分)</td>
  306. <td rowspan="2" class="td_splitLine"></td>
  307. <td>GB2(分)</td>
  308. <td rowspan="2" class="td_splitLine"></td>
  309. <td>GB3(分)</td>
  310. <td rowspan="2" class="td_splitLine"></td>
  311. <td>GB4(分)</td>
  312. <td rowspan="2" class="td_splitLine"></td>
  313. <td>GB5(分)</td>
  314. </tr>
  315. <tr style="color: #FFFFFF;font-size: 20px;">
  316. <td>-</td>
  317. <td>-</td>
  318. <td>-</td>
  319. <td>-</td>
  320. <td>-</td>
  321. </tr>
  322. </tbody>
  323. </table>
  324. </div>
  325. <div>
  326. <table style="width: 100%;text-align: center;" cellspacing="0" cellpadding="0">
  327. <tbody>
  328. <tr>
  329. <td colspan="10" style="font-size: 20px;font-weight: bold;color: #7d7d7d;padding: 5px 0;">
  330. 盘头剩余周长
  331. </td>
  332. </tr>
  333. <tr>
  334. <td>GB1(mm)</td>
  335. <td rowspan="2" class="td_splitLine"></td>
  336. <td>GB2(mm)</td>
  337. <td rowspan="2" class="td_splitLine"></td>
  338. <td>GB3(mm)</td>
  339. <td rowspan="2" class="td_splitLine"></td>
  340. <td>GB4(mm)</td>
  341. <td rowspan="2" class="td_splitLine"></td>
  342. <td>GB5(mm)</td>
  343. </tr>
  344. <tr style="color: #FFFFFF;font-size: 20px;">
  345. <td>-</td>
  346. <td>-</td>
  347. <td>-</td>
  348. <td>-</td>
  349. <td>-</td>
  350. </tr>
  351. </tbody>
  352. </table>
  353. </div>
  354. <div>
  355. <table style="width: 100%;text-align: center;" cellspacing="0" cellpadding="0">
  356. <tbody>
  357. <tr>
  358. <td colspan="10" style="font-size: 20px;font-weight: bold;color: #7d7d7d;padding: 5px 0;">
  359. 盘头剩余圈数
  360. </td>
  361. </tr>
  362. <tr>
  363. <td>GB1(圈)</td>
  364. <td rowspan="2" class="td_splitLine"></td>
  365. <td>GB2(圈)</td>
  366. <td rowspan="2" class="td_splitLine"></td>
  367. <td>GB3(圈)</td>
  368. <td rowspan="2" class="td_splitLine"></td>
  369. <td>GB4(圈)</td>
  370. <td rowspan="2" class="td_splitLine"></td>
  371. <td>GB5(圈)</td>
  372. </tr>
  373. <tr style="color: #FFFFFF;font-size: 20px;">
  374. <td>-</td>
  375. <td>-</td>
  376. <td>-</td>
  377. <td>-</td>
  378. <td>-</td>
  379. </tr>
  380. </tbody>
  381. </table>
  382. </div>
  383. <div>
  384. <table style="width: 100%;text-align: center;" cellspacing="0" cellpadding="0">
  385. <tbody>
  386. <tr>
  387. <td colspan="10" style="font-size: 20px;font-weight: bold;color: #7d7d7d;padding: 5px 0;">
  388. 盘头剩余比例
  389. </td>
  390. </tr>
  391. <tr>
  392. <td>GB1(%)</td>
  393. <td rowspan="2" class="td_splitLine"></td>
  394. <td>GB2(%)</td>
  395. <td rowspan="2" class="td_splitLine"></td>
  396. <td>GB3(%)</td>
  397. <td rowspan="2" class="td_splitLine"></td>
  398. <td>GB4(%)</td>
  399. <td rowspan="2" class="td_splitLine"></td>
  400. <td>GB5(%)</td>
  401. </tr>
  402. <tr style="color: #FFFFFF;font-size: 20px;">
  403. <td>-</td>
  404. <td>-</td>
  405. <td>-</td>
  406. <td>-</td>
  407. <td>-</td>
  408. </tr>
  409. </tbody>
  410. </table>
  411. </div>
  412. </div>
  413. </div>
  414. <div id="newwin" class="newwin">
  415. <div class="title"><img src="image/title_icon.png" style="margin: 7px;float: left;"><span class="text"></span><span
  416. class="text">#经编机-详细数据</span><img src="image/Close.png"
  417. style="margin: 7px;float: right;cursor: pointer;"
  418. onclick="CloseWin()"></div>
  419. <div class="content">
  420. <div style="text-align: center;"><span class="btn btn_active" style="margin-left: -220px;">告警</span><span
  421. class="btn">产能</span><span class="btn">产线及设备</span><span class="btn">配方</span><span
  422. class="btn">设备履历</span></div>
  423. <div class="dataContent">
  424. <div style="padding: 15px;display: none;width: 100%">
  425. <div class="no_alarm">当前无告警</div>
  426. <div class="has_alarm"></div>
  427. <div class="dev_alarm_echarts"></div>
  428. </div>
  429. <div style="padding: 15px;width: 100%">
  430. <div style="float: left;width: 25%;margin-right: 2%;">
  431. <table cellspacing="0" cellpadding="0">
  432. <tr style="background-color: #415683;height: 40px;">
  433. <td colspan="4">班组生产状态</td>
  434. </tr>
  435. <tr style="height: 1px;background-color: #5F6E8D;">
  436. <td colspan="4"></td>
  437. </tr>
  438. <tr>
  439. <td rowspan="2" width="20%">当前产量</td>
  440. <td rowspan="2" style="color: #817e7e">|</td>
  441. <td width="20%">A组</td>
  442. <td style="text-align: right;padding-right: 10px;" width="50%" class="value"
  443. attr="Capacity_data_39" unit="米">-
  444. </td>
  445. </tr>
  446. <tr>
  447. <td>B组</td>
  448. <td style="text-align: right;padding-right: 10px;" width="50%" class="value"
  449. attr="Capacity_data_44" unit="米">-
  450. </td>
  451. </tr>
  452. <tr style="height: 1px;background-color: #5F6E8D;">
  453. <td colspan="4"></td>
  454. </tr>
  455. <tr>
  456. <td rowspan="2" width="20%">开机时间</td>
  457. <td rowspan="2" style="color: #817e7e">|</td>
  458. <td width="20%">A组</td>
  459. <td style="text-align: right;padding-right: 10px;" width="50%" class="value"
  460. attr="Capacity_data_37" unit="H">-
  461. </td>
  462. </tr>
  463. <tr>
  464. <td>B组</td>
  465. <td style="text-align: right;padding-right: 10px;" width="50%" class="value"
  466. attr="Capacity_data_42" unit="H">-
  467. </td>
  468. </tr>
  469. <tr style="height: 1px;background-color: #5F6E8D;">
  470. <td colspan="4"></td>
  471. </tr>
  472. <tr>
  473. <td rowspan="2" width="20%">停机时间</td>
  474. <td rowspan="2" style="color: #817e7e">|</td>
  475. <td width="20%">A组</td>
  476. <td style="text-align: right; padding-right: 10px;" width="50%" class="value"
  477. attr="Capacity_data_38" unit="H">-
  478. </td>
  479. </tr>
  480. <tr>
  481. <td>B组</td>
  482. <td style="text-align: right;padding-right: 10px;" width="50%" class="value"
  483. attr="Capacity_data_43" unit="H">-
  484. </td>
  485. </tr>
  486. <tr style="height: 1px;background-color: #5F6E8D;">
  487. <td colspan="4"></td>
  488. </tr>
  489. <tr>
  490. <td rowspan="2" width="20%">停机率</td>
  491. <td rowspan="2" style="color: #817e7e">|</td>
  492. <td width="20%">A组</td>
  493. <td style="text-align: right; padding-right: 10px;" width="50%" class="value"
  494. attr="Capacity_data_40" unit="%">-
  495. </td>
  496. </tr>
  497. <tr>
  498. <td>B组</td>
  499. <td style="text-align: right;padding-right: 10px;" width="50%" class="value"
  500. attr="Capacity_data_45" unit="%">-
  501. </td>
  502. </tr>
  503. </table>
  504. </div>
  505. <div style="float: left;width: 25%;margin-right: 2%;">
  506. <table cellspacing="0" cellpadding="0">
  507. <tr style="background-color: #415683;height: 40px;">
  508. <td colspan="3">当前设备生产状态</td>
  509. </tr>
  510. <tr style="height: 1px;background-color: #5F6E8D;">
  511. <td colspan="3"></td>
  512. </tr>
  513. <tr style="height: 100px">
  514. <td>主轴运行转速</td>
  515. <td style="color: #817e7e">|</td>
  516. <td style="text-align: right;padding-right: 10px;" width="60%" class="value"
  517. attr="Capacity_data_1" unit="转/分钟">-
  518. </td>
  519. </tr>
  520. <tr style="height: 1px;background-color: #5F6E8D;">
  521. <td colspan="3"></td>
  522. </tr>
  523. <tr style="height: 100px">
  524. <td>已织造米数</td>
  525. <td style="color: #817e7e">|</td>
  526. <td style="text-align: right;padding-right: 10px;" width="60%" class="value"
  527. attr="Capacity_data_2" unit="米">-
  528. </td>
  529. </tr>
  530. <tr style="height: 1px;background-color: #5F6E8D;">
  531. <td colspan="3"></td>
  532. </tr>
  533. <tr style="height: 100px">
  534. <td>剩余落布时间</td>
  535. <td style="color: #817e7e">|</td>
  536. <td style="text-align: right;padding-right: 10px;" width="60%" class="value"
  537. attr="Capacity_data_3" unit="H">-
  538. </td>
  539. </tr>
  540. <tr style="height: 1px;background-color: #5F6E8D;">
  541. <td colspan="3"></td>
  542. </tr>
  543. <tr style="height: 100px">
  544. <td>设定落布米数</td>
  545. <td style="color: #817e7e">|</td>
  546. <td style="text-align: right;padding-right: 10px;" width="60%" class="value"
  547. attr="Capacity_data_4" unit="米">-
  548. </td>
  549. </tr>
  550. </table>
  551. </div>
  552. <div style="float: left;width: 44%;">
  553. <table cellspacing="0" cellpadding="0">
  554. <tr style="background-color: #415683;height: 40px;">
  555. <td colspan="6">供电</td>
  556. </tr>
  557. <tr style="height: 1px;background-color: #5F6E8D;">
  558. <td colspan="6"></td>
  559. </tr>
  560. <tr style="height: 80px">
  561. <td width="20%">AB相电压监控</td>
  562. <td style="color: #817e7e">|</td>
  563. <td width="20%" class="value" attr="Capacity_data_24" unit="U">-</td>
  564. <td width="20%">C相电流监控</td>
  565. <td style="color: #817e7e">|</td>
  566. <td width="20%" style="text-align: right;padding-right: 10px;" class="value"
  567. attr="Capacity_data_29" unit="V">-
  568. </td>
  569. </tr>
  570. <tr style="height: 1px;background-color: #5F6E8D;">
  571. <td colspan="6"></td>
  572. </tr>
  573. <tr style="height: 80px">
  574. <td width="20%">BC相电压监控</td>
  575. <td style="color: #817e7e">|</td>
  576. <td width="20%" class="value" attr="Capacity_data_25" unit="U">-</td>
  577. <td width="20%">A相功率监控</td>
  578. <td style="color: #817e7e">|</td>
  579. <td width="20%" style="text-align: right;padding-right: 10px;" class="value"
  580. attr="Capacity_data_30" unit="W">-
  581. </td>
  582. </tr>
  583. <tr style="height: 1px;background-color: #5F6E8D;">
  584. <td colspan="6"></td>
  585. </tr>
  586. <tr style="height: 80px">
  587. <td width="20%">AC相电压监控</td>
  588. <td style="color: #817e7e">|</td>
  589. <td width="20%" class="value" attr="Capacity_data_26" unit="U">-</td>
  590. <td width="20%">B相功率监控</td>
  591. <td style="color: #817e7e">|</td>
  592. <td width="20%" style="text-align: right;padding-right: 10px;" class="value"
  593. attr="Capacity_data_31" unit="W">-
  594. </td>
  595. </tr>
  596. <tr style="height: 1px;background-color: #5F6E8D;">
  597. <td colspan="6"></td>
  598. </tr>
  599. <tr style="height: 80px">
  600. <td width="20%">A相电流监控</td>
  601. <td style="color: #817e7e">|</td>
  602. <td width="20%" class="value" attr="Capacity_data_27" unit="V">-</td>
  603. <td width="20%">C相功率监控</td>
  604. <td style="color: #817e7e">|</td>
  605. <td width="20%" style="text-align: right;padding-right: 10px;" class="value"
  606. attr="Capacity_data_32" unit="W">-
  607. </td>
  608. </tr>
  609. <tr style="height: 1px;background-color: #5F6E8D;">
  610. <td colspan="6"></td>
  611. </tr>
  612. <tr style="height: 80px">
  613. <td width="20%">B相电流监控</td>
  614. <td style="color: #817e7e">|</td>
  615. <td width="20%" class="value" attr="Capacity_data_28" unit="V">-</td>
  616. <td width="20%">总功率监控</td>
  617. <td style="color: #817e7e">|</td>
  618. <td width="20%" style="text-align: right;padding-right: 10px;" class="value"
  619. attr="Capacity_data_33" unit="W">-
  620. </td>
  621. </tr>
  622. </table>
  623. </div>
  624. </div>
  625. <div style="padding: 15px;display: none;width: 100%">
  626. <div style="float: left;width: 23%;margin-right: 2%;">
  627. <table cellspacing="0" cellpadding="0">
  628. <tr style="height: 60px">
  629. <td>断纱检测开关</td>
  630. <td style="color: #817e7e">|</td>
  631. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  632. attr="Capacity_data_46" unit="">-
  633. </td>
  634. </tr>
  635. <tr style="height: 1px;background-color: #5F6E8D;">
  636. <td colspan="3"></td>
  637. </tr>
  638. <tr style="height: 60px">
  639. <td>断纱检测延时</td>
  640. <td style="color: #817e7e">|</td>
  641. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  642. attr="Capacity_data_47" unit="s">-
  643. </td>
  644. </tr>
  645. <tr style="height: 1px;background-color: #5F6E8D;">
  646. <td colspan="3"></td>
  647. </tr>
  648. <tr style="height: 60px">
  649. <td>牵拉罗拉辊周长</td>
  650. <td style="color: #817e7e">|</td>
  651. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  652. attr="System_data_15" unit="mm">-
  653. </td>
  654. </tr>
  655. <tr style="height: 1px;background-color: #5F6E8D;">
  656. <td colspan="3"></td>
  657. </tr>
  658. <tr style="height: 60px">
  659. <td>卷曲罗拉辊周长</td>
  660. <td style="color: #817e7e">|</td>
  661. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  662. attr="System_data_16" unit="mm">-
  663. </td>
  664. </tr>
  665. <tr style="height: 1px;background-color: #5F6E8D;">
  666. <td colspan="3"></td>
  667. </tr>
  668. <tr style="height: 60px">
  669. <td>主电机额定转速</td>
  670. <td style="color: #817e7e">|</td>
  671. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  672. attr="System_data_38" unit="">-
  673. </td>
  674. </tr>
  675. <tr style="height: 1px;background-color: #5F6E8D;">
  676. <td colspan="3"></td>
  677. </tr>
  678. <tr style="height: 60px">
  679. <td>主电机额定频率</td>
  680. <td style="color: #817e7e">|</td>
  681. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  682. attr="System_data_39" unit="">-
  683. </td>
  684. </tr>
  685. <tr style="height: 1px;background-color: #5F6E8D;">
  686. <td colspan="3"></td>
  687. </tr>
  688. <tr style="height: 60px">
  689. <td>电机传动比</td>
  690. <td style="color: #817e7e">|</td>
  691. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  692. attr="System_data_40" unit="">-
  693. </td>
  694. </tr>
  695. </table>
  696. </div>
  697. <div style="float: left;width: 23%;margin-right: 2%;">
  698. <table cellspacing="0" cellpadding="0">
  699. <tr style="height: 60px">
  700. <td>GB1减速机减速比</td>
  701. <td style="color: #817e7e">|</td>
  702. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  703. attr="System_data_17" unit="">-
  704. </td>
  705. </tr>
  706. <tr style="height: 1px;background-color: #5F6E8D;">
  707. <td colspan="3"></td>
  708. </tr>
  709. <tr style="height: 60px">
  710. <td>GB2减速机减速比</td>
  711. <td style="color: #817e7e">|</td>
  712. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  713. attr="System_data_18" unit="">-
  714. </td>
  715. </tr>
  716. <tr style="height: 1px;background-color: #5F6E8D;">
  717. <td colspan="3"></td>
  718. </tr>
  719. <tr style="height: 60px">
  720. <td>GB3减速机减速比</td>
  721. <td style="color: #817e7e">|</td>
  722. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  723. attr="System_data_19" unit="">-
  724. </td>
  725. </tr>
  726. <tr style="height: 1px;background-color: #5F6E8D;">
  727. <td colspan="3"></td>
  728. </tr>
  729. <tr style="height: 60px">
  730. <td>GB4减速机减速比</td>
  731. <td style="color: #817e7e">|</td>
  732. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  733. attr="System_data_20" unit="">-
  734. </td>
  735. </tr>
  736. <tr style="height: 1px;background-color: #5F6E8D;">
  737. <td colspan="3"></td>
  738. </tr>
  739. <tr style="height: 60px">
  740. <td>GB5减速机减速比</td>
  741. <td style="color: #817e7e">|</td>
  742. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  743. attr="System_data_21" unit="">-
  744. </td>
  745. </tr>
  746. <tr style="height: 1px;background-color: #5F6E8D;">
  747. <td colspan="3"></td>
  748. </tr>
  749. <tr style="height: 60px">
  750. <td>牵拉减速机减速比</td>
  751. <td style="color: #817e7e">|</td>
  752. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  753. attr="System_data_22" unit="">-
  754. </td>
  755. </tr>
  756. <tr style="height: 1px;background-color: #5F6E8D;">
  757. <td colspan="3"></td>
  758. </tr>
  759. <tr style="height: 60px">
  760. <td>卷曲减速机减速比</td>
  761. <td style="color: #817e7e">|</td>
  762. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  763. attr="System_data_23" unit="">-
  764. </td>
  765. </tr>
  766. </table>
  767. </div>
  768. <div style="float: left;width: 23%;margin-right: 2%;">
  769. <table cellspacing="0" cellpadding="0">
  770. <tr style="height: 60px">
  771. <td>GB1被动齿轮数</td>
  772. <td style="color: #817e7e">|</td>
  773. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  774. attr="System_data_24" unit="">-
  775. </td>
  776. </tr>
  777. <tr style="height: 1px;background-color: #5F6E8D;">
  778. <td colspan="3"></td>
  779. </tr>
  780. <tr style="height: 60px">
  781. <td>GB2被动齿轮数</td>
  782. <td style="color: #817e7e">|</td>
  783. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  784. attr="System_data_25" unit="">-
  785. </td>
  786. </tr>
  787. <tr style="height: 1px;background-color: #5F6E8D;">
  788. <td colspan="3"></td>
  789. </tr>
  790. <tr style="height: 60px">
  791. <td>GB3被动齿轮数</td>
  792. <td style="color: #817e7e">|</td>
  793. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  794. attr="System_data_26" unit="">-
  795. </td>
  796. </tr>
  797. <tr style="height: 1px;background-color: #5F6E8D;">
  798. <td colspan="3"></td>
  799. </tr>
  800. <tr style="height: 60px">
  801. <td>GB4被动齿轮数</td>
  802. <td style="color: #817e7e">|</td>
  803. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  804. attr="System_data_27" unit="">-
  805. </td>
  806. </tr>
  807. <tr style="height: 1px;background-color: #5F6E8D;">
  808. <td colspan="3"></td>
  809. </tr>
  810. <tr style="height: 60px">
  811. <td>GB5被动齿轮数</td>
  812. <td style="color: #817e7e">|</td>
  813. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  814. attr="System_data_28" unit="">-
  815. </td>
  816. </tr>
  817. <tr style="height: 1px;background-color: #5F6E8D;">
  818. <td colspan="3"></td>
  819. </tr>
  820. <tr style="height: 60px">
  821. <td>牵拉被动齿轮数</td>
  822. <td style="color: #817e7e">|</td>
  823. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  824. attr="System_data_29" unit="">-
  825. </td>
  826. </tr>
  827. <tr style="height: 1px;background-color: #5F6E8D;">
  828. <td colspan="3"></td>
  829. </tr>
  830. <tr style="height: 60px">
  831. <td>卷曲被动齿轮数</td>
  832. <td style="color: #817e7e">|</td>
  833. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  834. attr="System_data_30" unit="">-
  835. </td>
  836. </tr>
  837. </table>
  838. </div>
  839. <div style="float: left;width: 23%;margin-right: 2%;">
  840. <table cellspacing="0" cellpadding="0">
  841. <tr style="height: 60px">
  842. <td>GB1主动齿轮数</td>
  843. <td style="color: #817e7e">|</td>
  844. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  845. attr="System_data_31" unit="">-
  846. </td>
  847. </tr>
  848. <tr style="height: 1px;background-color: #5F6E8D;">
  849. <td colspan="3"></td>
  850. </tr>
  851. <tr style="height: 60px">
  852. <td>GB2主动齿轮数</td>
  853. <td style="color: #817e7e">|</td>
  854. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  855. attr="System_data_32" unit="">-
  856. </td>
  857. </tr>
  858. <tr style="height: 1px;background-color: #5F6E8D;">
  859. <td colspan="3"></td>
  860. </tr>
  861. <tr style="height: 60px">
  862. <td>GB3主动齿轮数</td>
  863. <td style="color: #817e7e">|</td>
  864. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  865. attr="System_data_33" unit="">-
  866. </td>
  867. </tr>
  868. <tr style="height: 1px;background-color: #5F6E8D;">
  869. <td colspan="3"></td>
  870. </tr>
  871. <tr style="height: 60px">
  872. <td>GB4主动齿轮数</td>
  873. <td style="color: #817e7e">|</td>
  874. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  875. attr="System_data_34" unit="">-
  876. </td>
  877. </tr>
  878. <tr style="height: 1px;background-color: #5F6E8D;">
  879. <td colspan="3"></td>
  880. </tr>
  881. <tr style="height: 60px">
  882. <td>GB5主动齿轮数</td>
  883. <td style="color: #817e7e">|</td>
  884. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  885. attr="System_data_35" unit="">-
  886. </td>
  887. </tr>
  888. <tr style="height: 1px;background-color: #5F6E8D;">
  889. <td colspan="3"></td>
  890. </tr>
  891. <tr style="height: 60px">
  892. <td>牵拉主动齿轮数</td>
  893. <td style="color: #817e7e">|</td>
  894. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  895. attr="System_data_36" unit="">-
  896. </td>
  897. </tr>
  898. <tr style="height: 1px;background-color: #5F6E8D;">
  899. <td colspan="3"></td>
  900. </tr>
  901. <tr style="height: 60px">
  902. <td>卷曲主动齿轮数</td>
  903. <td style="color: #817e7e">|</td>
  904. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  905. attr="System_data_37" unit="">-
  906. </td>
  907. </tr>
  908. </table>
  909. </div>
  910. </div>
  911. <div style="padding: 15px;display: none;width: 100%">
  912. <div style="float: left;width: 23%;margin-right: 2%;">
  913. <table cellspacing="0" cellpadding="0">
  914. <tr style="height: 48px">
  915. <td>配方号</td>
  916. <td style="color: #817e7e">|</td>
  917. <td style="text-align: right;padding-right: 10px;" width="40%" class="value"
  918. attr="Capacity_data_46" unit="">-
  919. </td>
  920. </tr>
  921. <tr style="height: 1px;background-color: #5F6E8D;">
  922. <td colspan="3"></td>
  923. </tr>
  924. <tr style="height: 48px">
  925. <td>机台号</td>
  926. <td style="color: #817e7e">|</td>
  927. <td style="text-align: right;padding-right: 10px;" width="40%" class="value"
  928. attr="Capacity_data_47" unit="">-
  929. </td>
  930. </tr>
  931. <tr style="height: 1px;background-color: #5F6E8D;">
  932. <td colspan="3"></td>
  933. </tr>
  934. <tr style="height: 48px">
  935. <td>米克重</td>
  936. <td style="color: #817e7e">|</td>
  937. <td style="text-align: right;padding-right: 10px;" width="40%" class="value"
  938. attr="System_data_15" unit="g/米">-
  939. </td>
  940. </tr>
  941. <tr style="height: 1px;background-color: #5F6E8D;">
  942. <td colspan="3"></td>
  943. </tr>
  944. <tr style="height: 48px">
  945. <td>L1、L5纱线规格D</td>
  946. <td style="color: #817e7e">|</td>
  947. <td style="text-align: right;padding-right: 10px;" width="40%" class="value"
  948. attr="System_data_16" unit="D">-
  949. </td>
  950. </tr>
  951. <tr style="height: 1px;background-color: #5F6E8D;">
  952. <td colspan="3"></td>
  953. </tr>
  954. <tr style="height: 48px">
  955. <td>L2、L4纱线规格D</td>
  956. <td style="color: #817e7e">|</td>
  957. <td style="text-align: right;padding-right: 10px;" width="40%" class="value"
  958. attr="System_data_38" unit="D">-
  959. </td>
  960. </tr>
  961. <tr style="height: 1px;background-color: #5F6E8D;">
  962. <td colspan="3"></td>
  963. </tr>
  964. <tr style="height: 48px">
  965. <td>L3纱线规格D</td>
  966. <td style="color: #817e7e">|</td>
  967. <td style="text-align: right;padding-right: 10px;" width="40%" class="value"
  968. attr="System_data_39" unit="D">-
  969. </td>
  970. </tr>
  971. <tr style="height: 1px;background-color: #5F6E8D;">
  972. <td colspan="3"></td>
  973. </tr>
  974. <tr style="height: 48px">
  975. <td>L1、L5纱线规格F</td>
  976. <td style="color: #817e7e">|</td>
  977. <td style="text-align: right;padding-right: 10px;" width="40%" class="value"
  978. attr="System_data_40" unit="F">-
  979. </td>
  980. </tr>
  981. <tr style="height: 1px;background-color: #5F6E8D;">
  982. <td colspan="3"></td>
  983. </tr>
  984. <tr style="height: 48px">
  985. <td>L2、L4纱线规格F</td>
  986. <td style="color: #817e7e">|</td>
  987. <td style="text-align: right;padding-right: 10px;" width="40%" class="value"
  988. attr="System_data_40" unit="F">-
  989. </td>
  990. </tr>
  991. <tr style="height: 1px;background-color: #5F6E8D;">
  992. <td colspan="3"></td>
  993. </tr>
  994. <tr style="height: 48px">
  995. <td>L3纱线规格F</td>
  996. <td style="color: #817e7e">|</td>
  997. <td style="text-align: right;padding-right: 10px;" width="40%" class="value"
  998. attr="System_data_40" unit="F">-
  999. </td>
  1000. </tr>
  1001. </table>
  1002. </div>
  1003. <div style="float: left;width: 23%;margin-right: 2%;">
  1004. <table cellspacing="0" cellpadding="0">
  1005. <tr style="height: 48px">
  1006. <td>L1、L5盘头根数</td>
  1007. <td style="color: #817e7e">|</td>
  1008. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  1009. attr="System_data_17" unit="根">-
  1010. </td>
  1011. </tr>
  1012. <tr style="height: 1px;background-color: #5F6E8D;">
  1013. <td colspan="3"></td>
  1014. </tr>
  1015. <tr style="height: 48px">
  1016. <td>L2、L4盘头根数</td>
  1017. <td style="color: #817e7e">|</td>
  1018. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  1019. attr="System_data_18" unit="根">-
  1020. </td>
  1021. </tr>
  1022. <tr style="height: 1px;background-color: #5F6E8D;">
  1023. <td colspan="3"></td>
  1024. </tr>
  1025. <tr style="height: 48px">
  1026. <td>L3盘头根数</td>
  1027. <td style="color: #817e7e">|</td>
  1028. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  1029. attr="System_data_19" unit="根">-
  1030. </td>
  1031. </tr>
  1032. <tr style="height: 1px;background-color: #5F6E8D;">
  1033. <td colspan="3"></td>
  1034. </tr>
  1035. <tr style="height: 48px">
  1036. <td>卷曲幅宽</td>
  1037. <td style="color: #817e7e">|</td>
  1038. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  1039. attr="System_data_20" unit="m">-
  1040. </td>
  1041. </tr>
  1042. <tr style="height: 1px;background-color: #5F6E8D;">
  1043. <td colspan="3"></td>
  1044. </tr>
  1045. <tr style="height: 48px">
  1046. <td>下布长度</td>
  1047. <td style="color: #817e7e">|</td>
  1048. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  1049. attr="System_data_21" unit="m">-
  1050. </td>
  1051. </tr>
  1052. <tr style="height: 1px;background-color: #5F6E8D;">
  1053. <td colspan="3"></td>
  1054. </tr>
  1055. <tr style="height: 48px">
  1056. <td>毛高</td>
  1057. <td style="color: #817e7e">|</td>
  1058. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  1059. attr="System_data_22" unit="m">-
  1060. </td>
  1061. </tr>
  1062. <tr style="height: 1px;background-color: #5F6E8D;">
  1063. <td colspan="3"></td>
  1064. </tr>
  1065. <tr style="height: 48px">
  1066. <td>成片长</td>
  1067. <td style="color: #817e7e">|</td>
  1068. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  1069. attr="System_data_23" unit="m">-
  1070. </td>
  1071. </tr>
  1072. <tr style="height: 1px;background-color: #5F6E8D;">
  1073. <td colspan="3"></td>
  1074. </tr>
  1075. <tr style="height: 48px">
  1076. <td>成品宽</td>
  1077. <td style="color: #817e7e">|</td>
  1078. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  1079. attr="System_data_23" unit="m">-
  1080. </td>
  1081. </tr>
  1082. <tr style="height: 1px;background-color: #5F6E8D;">
  1083. <td colspan="3"></td>
  1084. </tr>
  1085. <tr style="height: 48px">
  1086. <td>成品重</td>
  1087. <td style="color: #817e7e">|</td>
  1088. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  1089. attr="System_data_23" unit="kg">-
  1090. </td>
  1091. </tr>
  1092. </table>
  1093. </div>
  1094. <div style="float: left;width: 23%;margin-right: 2%;">
  1095. <table cellspacing="0" cellpadding="0">
  1096. <tr style="height: 48px">
  1097. <td>GB1送经量</td>
  1098. <td style="color: #817e7e">|</td>
  1099. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  1100. attr="System_data_24" unit="mm/腊克">-
  1101. </td>
  1102. </tr>
  1103. <tr style="height: 1px;background-color: #5F6E8D;">
  1104. <td colspan="3"></td>
  1105. </tr>
  1106. <tr style="height: 48px">
  1107. <td>GB2送经量</td>
  1108. <td style="color: #817e7e">|</td>
  1109. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  1110. attr="System_data_25" unit="mm/腊克">-
  1111. </td>
  1112. </tr>
  1113. <tr style="height: 1px;background-color: #5F6E8D;">
  1114. <td colspan="3"></td>
  1115. </tr>
  1116. <tr style="height: 48px">
  1117. <td>GB3送经量</td>
  1118. <td style="color: #817e7e">|</td>
  1119. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  1120. attr="System_data_26" unit="mm/腊克">-
  1121. </td>
  1122. </tr>
  1123. <tr style="height: 1px;background-color: #5F6E8D;">
  1124. <td colspan="3"></td>
  1125. </tr>
  1126. <tr style="height: 48px">
  1127. <td>GB4送经量</td>
  1128. <td style="color: #817e7e">|</td>
  1129. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  1130. attr="System_data_27" unit="mm/腊克">-
  1131. </td>
  1132. </tr>
  1133. <tr style="height: 1px;background-color: #5F6E8D;">
  1134. <td colspan="3"></td>
  1135. </tr>
  1136. <tr style="height: 48px">
  1137. <td>GB5送经量</td>
  1138. <td style="color: #817e7e">|</td>
  1139. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  1140. attr="System_data_28" unit="mm/腊克">-
  1141. </td>
  1142. </tr>
  1143. <tr style="height: 1px;background-color: #5F6E8D;">
  1144. <td colspan="3"></td>
  1145. </tr>
  1146. <tr style="height: 48px">
  1147. <td>奉拉密度</td>
  1148. <td style="color: #817e7e">|</td>
  1149. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  1150. attr="System_data_29" unit="r/cm">-
  1151. </td>
  1152. </tr>
  1153. <tr style="height: 1px;background-color: #5F6E8D;">
  1154. <td colspan="3"></td>
  1155. </tr>
  1156. <tr style="height: 48px">
  1157. <td>卷曲张力系数</td>
  1158. <td style="color: #817e7e">|</td>
  1159. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  1160. attr="System_data_30" unit="%">-
  1161. </td>
  1162. </tr>
  1163. <tr style="height: 1px;background-color: #5F6E8D;">
  1164. <td colspan="3"></td>
  1165. </tr>
  1166. <tr style="height: 48px">
  1167. <td>GB1盘头最大圈数</td>
  1168. <td style="color: #817e7e">|</td>
  1169. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  1170. attr="System_data_30" unit="r">-
  1171. </td>
  1172. </tr>
  1173. <tr style="height: 1px;background-color: #5F6E8D;">
  1174. <td colspan="3"></td>
  1175. </tr>
  1176. <tr style="height: 48px">
  1177. <td>GB2盘头最大圈数</td>
  1178. <td style="color: #817e7e">|</td>
  1179. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  1180. attr="System_data_30" unit="r">-
  1181. </td>
  1182. </tr>
  1183. </table>
  1184. </div>
  1185. <div style="float: left;width: 23%;margin-right: 2%;">
  1186. <table cellspacing="0" cellpadding="0">
  1187. <tr style="height: 48px">
  1188. <td>GB3盘头最大圈数</td>
  1189. <td style="color: #817e7e">|</td>
  1190. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  1191. attr="System_data_31" unit="r">-
  1192. </td>
  1193. </tr>
  1194. <tr style="height: 1px;background-color: #5F6E8D;">
  1195. <td colspan="3"></td>
  1196. </tr>
  1197. <tr style="height: 48px">
  1198. <td>GB4盘头最大圈数</td>
  1199. <td style="color: #817e7e">|</td>
  1200. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  1201. attr="System_data_32" unit="r">-
  1202. </td>
  1203. </tr>
  1204. <tr style="height: 1px;background-color: #5F6E8D;">
  1205. <td colspan="3"></td>
  1206. </tr>
  1207. <tr style="height: 48px">
  1208. <td>GB5盘头最大圈数</td>
  1209. <td style="color: #817e7e">|</td>
  1210. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  1211. attr="System_data_33" unit="r">-
  1212. </td>
  1213. </tr>
  1214. <tr style="height: 1px;background-color: #5F6E8D;">
  1215. <td colspan="3"></td>
  1216. </tr>
  1217. <tr style="height: 48px">
  1218. <td>GB1盘头最大外周长</td>
  1219. <td style="color: #817e7e">|</td>
  1220. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  1221. attr="System_data_34" unit="mm">-
  1222. </td>
  1223. </tr>
  1224. <tr style="height: 1px;background-color: #5F6E8D;">
  1225. <td colspan="3"></td>
  1226. </tr>
  1227. <tr style="height: 48px">
  1228. <td>GB2盘头最大外周长</td>
  1229. <td style="color: #817e7e">|</td>
  1230. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  1231. attr="System_data_35" unit="mm">-
  1232. </td>
  1233. </tr>
  1234. <tr style="height: 1px;background-color: #5F6E8D;">
  1235. <td colspan="3"></td>
  1236. </tr>
  1237. <tr style="height: 48px">
  1238. <td>GB3盘头最大外周长</td>
  1239. <td style="color: #817e7e">|</td>
  1240. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  1241. attr="System_data_36" unit="mm">-
  1242. </td>
  1243. </tr>
  1244. <tr style="height: 1px;background-color: #5F6E8D;">
  1245. <td colspan="3"></td>
  1246. </tr>
  1247. <tr style="height: 48px">
  1248. <td>GB4盘头最大外周长</td>
  1249. <td style="color: #817e7e">|</td>
  1250. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  1251. attr="System_data_37" unit="mm">-
  1252. </td>
  1253. </tr>
  1254. <tr style="height: 1px;background-color: #5F6E8D;">
  1255. <td colspan="3"></td>
  1256. </tr>
  1257. <tr style="height: 48px">
  1258. <td>GB5盘头最大外周长</td>
  1259. <td style="color: #817e7e">|</td>
  1260. <td style="text-align: right;padding-right: 10px;" width="45%" class="value"
  1261. attr="System_data_37" unit="mm">-
  1262. </td>
  1263. </tr>
  1264. </table>
  1265. </div>
  1266. </div>
  1267. <div style="padding: 15px;display: none;width: 100%">
  1268. <img src="image/dev_log.png" style="width: 1300px;height: 459px;display: none;">
  1269. </div>
  1270. </div>
  1271. </div>
  1272. </div>
  1273. <!--毛高占比窗口-->
  1274. <div id="maogaoWin" class="showinfo">
  1275. <div class="title">
  1276. <img src="image/title_icon.png" style="margin: 7px;float: left;">
  1277. <span class="text">生产工艺总览</span>
  1278. <img src="image/Close.png" style="margin: 7px;float: right;cursor: pointer;" onclick="$('#maogaoWin').hide()">
  1279. </div>
  1280. <div class="content">
  1281. <div style="height: 50px;width: 100%;">
  1282. <table style="width: 100%;text-align: center;" cellspacing="0" cellpadding="0">
  1283. <thead>
  1284. <tr style="height: 50px;">
  1285. <td width="33%">毛高</td>
  1286. <td width="1px" style="color: #817e7e">|</td>
  1287. <td width="33%">设备数量</td>
  1288. <td width="1px" style="color: #817e7e">|</td>
  1289. <td width="33%">占比</td>
  1290. </tr>
  1291. </thead>
  1292. </table>
  1293. </div>
  1294. <div style="height: 340px;overflow: auto;width: 100%;">
  1295. <table style="width: 100%;text-align: center;" cellspacing="0" cellpadding="0">
  1296. <tbody>
  1297. </tbody>
  1298. </table>
  1299. </div>
  1300. </div>
  1301. </div>
  1302. <!--毛高占比详情窗口-->
  1303. <div id="maogaoDetailWin" class="newwin">
  1304. <div class="title">
  1305. <img src="image/title_icon.png" style="margin: 7px;float: left;">
  1306. <span class="text">生产工艺详情</span>
  1307. <img src="image/Close.png" style="margin: 7px;float: right;cursor: pointer;"
  1308. onclick="$('#maogaoDetailWin').hide()">
  1309. </div>
  1310. <div class="content">
  1311. <div style="position: relative;height: 50px">
  1312. <div id="imp_btn_maogaodetail" title="导出数据"
  1313. style="cursor: pointer;position: absolute;right: 5px;top: 5px;height: 38px;width: 38px;"><IMG
  1314. src="image/imp_icon.png"></div>
  1315. </div>
  1316. <div style="height: 64px;">
  1317. <table style="width: 100%;text-align: center;" cellspacing="0" cellpadding="0">
  1318. <thead>
  1319. <tr style="height: 32px;">
  1320. <td rowspan="2" width="60" style="border-right: 1px solid #76549b !important;">设备名称</td>
  1321. <td rowspan="2" width="60" style="border-right: 1px solid #76549b !important;">机台号</td>
  1322. <td rowspan="2" width="60" style="border-right: 1px solid #76549b !important;">毛高</td>
  1323. <td rowspan="2" width="60" style="border-right: 1px solid #76549b !important;">配方号</td>
  1324. <td rowspan="2" width="60" style="border-right: 1px solid #76549b !important;">米克重</td>
  1325. <td colspan="5" width="300"
  1326. style="border-right: 1px solid #76549b !important;border-bottom: 1px solid #76549b !important;">
  1327. 送经量
  1328. </td>
  1329. <td colspan="3" width="180" style="border-bottom: 1px solid #76549b !important;">线纱规格D</td>
  1330. </tr>
  1331. <tr style="height: 32px;">
  1332. <td width="60" style="border-right: 1px solid #76549b !important;">GB1</td>
  1333. <td width="60" style="border-right: 1px solid #76549b !important;">GB2</td>
  1334. <td width="60" style="border-right: 1px solid #76549b !important;">GB3</td>
  1335. <td width="60" style="border-right: 1px solid #76549b !important;">GB4</td>
  1336. <td width="60" style="border-right: 1px solid #76549b !important;">GB5</td>
  1337. <td width="60" style="border-right: 1px solid #76549b !important;">L1、L5</td>
  1338. <td width="60" style="border-right: 1px solid #76549b !important;">L2、L4</td>
  1339. <td width="60">L3</td>
  1340. </tr>
  1341. </thead>
  1342. </table>
  1343. </div>
  1344. <div style="height: 420px;overflow: auto;">
  1345. <table style="width: 100%;text-align: center;" cellspacing="0" cellpadding="0">
  1346. <tbody>
  1347. </tbody>
  1348. </table>
  1349. </div>
  1350. </div>
  1351. </div>
  1352. </body>
  1353. <script type="text/html" id="maogodetail_tpl">
  1354. {{each data}}
  1355. <tr>
  1356. <td width="60">{{$value.device}}</td>
  1357. <td width="60">{{$value.formula_data_2}}</td>
  1358. <td width="60">{{$value.formula_data_15}}</td>
  1359. <td width="60">{{$value.formula_data_1}}</td>
  1360. <td width="60">{{$value.formula_data_3}}</td>
  1361. <td width="60">{{$value.formula_data_19}}</td>
  1362. <td width="60">{{$value.formula_data_20}}</td>
  1363. <td width="60">{{$value.formula_data_21}}</td>
  1364. <td width="60">{{$value.formula_data_22}}</td>
  1365. <td width="60">{{$value.formula_data_23}}</td>
  1366. <td width="60">{{$value.formula_data_4}}</td>
  1367. <td width="60">{{$value.formula_data_5}}</td>
  1368. <td width="60">{{$value.formula_data_6}}</td>
  1369. </tr>
  1370. {{/each}}
  1371. </script>
  1372. </html>
  1373. <!-- 引入qwebchannel.js、Player.js、PlayerUtils.js -->
  1374. <script type="text/javascript" src="jquery-3.4.1.js"></script>
  1375. <script type="text/javascript" src="jquery-ui.min.js"></script>
  1376. <script type="text/javascript" src="echarts.min.js"></script>
  1377. <script src="qwebchannel.js"></script>
  1378. <script src="global.js"></script>
  1379. <script src="Player.js"></script>
  1380. <script src="PlayerUtils.js"></script>
  1381. <script src="lottie.min.js"></script>
  1382. <script src="Loading.json.js"></script>
  1383. <script src="animation.js"></script>
  1384. <script type="text/javascript" src="template.js"></script>
  1385. <!--本地模拟测试数据,正式部署时需删除该2个js
  1386. <script src="test-data.js"></script>
  1387. <script src="device-data.js"></script>
  1388. -->
  1389. <script>
  1390. lottie.loadAnimation({
  1391. // 选取一个容器,用于渲染动画
  1392. container: $("#loading_a1")[0],
  1393. // 定义JSON文件路径
  1394. animationData: lottiedata,
  1395. // 是否循环播放
  1396. loop: true,
  1397. // 渲染的格式svg/canvas/html,svg性能更优,兼容性更好
  1398. renderer: "svg",
  1399. });
  1400. var currentTargetType="FAC";//当前视图对象类型。FAC:厂房 IN02:2号楼内部 IN03:3号楼内部
  1401. //切换点列表
  1402. var inPoints={
  1403. "IN02":{"Text001_002":1,"x1":-28.07801,"y1":37.95126,"x2":-23.32394,"y2":31.16921},
  1404. "IN03":{"Text001_006":1,"x1":46.86921,"y1":24.87041,"x2":51.91054,"y2":17.87417},
  1405. "IN04":{"Text001_004":1,"x1":-38.46275,"y1":35.65208,"x2":-44.94122,"y2":28.22142},
  1406. "IN05":{"Text001_005":1,"x1":102.43050,"y1":38.96248,"x2":108.99212,"y2":30.86295}
  1407. }
  1408. var sam0023;
  1409. var modelsMap = {}
  1410. var modelsAlarmColorMap = {};
  1411. var MODEL_LOADED = 0; //模型是否加载完成
  1412. var ALARM_DEVS = []; //未提醒的告警设备,将在模型加载完成时提醒
  1413. var OFFLINE_DEVS = {}; //未接入设备列表
  1414. var LoadServerDataTimer = null;
  1415. var zoomCount=0;//放大、缩小次数。为正表示放大次数,为负表示缩小次数
  1416. var DataFill = {
  1417. devStopAutoLoadTimter: null,//停机原因自动切计时器
  1418. devAlarmAutoLoadTimter: null,//告警自动切计时器
  1419. AlarmData: null,
  1420. Pan: null,//盘头数据
  1421. PanAlarm: {},//盘头告警记录
  1422. AlarmType: {
  1423. "1": "GB1伺服通讯故障",
  1424. "2": "GB2伺服通讯故障",
  1425. "3": "GB3伺服通讯故障",
  1426. "4": "GB4伺服通讯故障",
  1427. "5": "GB5伺服通讯故障",
  1428. "6": "牵引伺服通讯故障",
  1429. "7": "卷曲伺服通讯故障",
  1430. "8": "断纱故障",
  1431. "9": "电源故障",
  1432. "10": "联动未完全啮合",
  1433. "11": "米长到达",
  1434. "12": "GB1剩余圈数报警",
  1435. "13": "GB2剩余圈数报警",
  1436. "14": "GB3剩余圈数报警",
  1437. "15": "GB4剩余圈数报警",
  1438. "16": "GB5剩余圈数报警",
  1439. "17": "主轴变频掉线",
  1440. "18": "主轴变频故障",
  1441. "19": "GB1伺服故障",
  1442. "20": "GB2伺服故障",
  1443. "21": "GB3伺服故障",
  1444. "22": "GB4伺服故障",
  1445. "23": "GB5伺服故障",
  1446. "24": "牵引伺服故障",
  1447. "25": "卷曲伺服故障",
  1448. "26": "拍照自停",
  1449. "27": "CCD位置报警信息显示",
  1450. "1000": "", //盘头比例低于20%
  1451. "1001": "", //盘头比例低于50%
  1452. "10001": "停经片停机",
  1453. "10002": "CCD断纱停机",
  1454. "10006": "落布米数到达停机",
  1455. "10008": "叫料停机"
  1456. },
  1457. //告警指示灯颜色
  1458. AlarmColorTypeCode: {
  1459. "1": "FF0000", //红色
  1460. "2": "FF0000",
  1461. "3": "FF0000",
  1462. "4": "FF0000",
  1463. "5": "FF0000",
  1464. "6": "FF0000",
  1465. "7": "FF0000",
  1466. "8": "FF0000",
  1467. "9": "FF0000",
  1468. "10": "FFFF00", //黄色
  1469. "11": "FFFF00", //黄色
  1470. "12": "FFFF00", //黄色
  1471. "13": "FFFF00", //黄色
  1472. "14": "FFFF00", //黄色
  1473. "15": "FFFF00", //黄色
  1474. "16": "FFFF00", //黄色
  1475. "17": "FF0000", //红色
  1476. "18": "FF0000", //红色
  1477. "19": "FF0000", //红色
  1478. "20": "FF0000", //红色
  1479. "21": "FF0000", //红色
  1480. "22": "FF0000", //红色
  1481. "23": "FF0000", //红色
  1482. "24": "FF0000", //红色
  1483. "25": "FF0000",
  1484. "26": "FFFF00",
  1485. "27": "FFFF00",
  1486. "1000": "", //盘头比例低于20%
  1487. "1001": "", //盘头比例低于50%
  1488. "10001": "FFFF00", //黄色
  1489. "10002": "FFFF00", //黄色
  1490. "10006": "FFFF00", //黄色
  1491. "10008": "FFFF00" //黄色
  1492. },
  1493. //停机原因类型
  1494. StopType: {
  1495. "stop1": "停经片停机",
  1496. "stop2": "CCD停机",
  1497. "stop3": "人工停机",
  1498. "stop4": "断电停机",
  1499. "stop5": "设备故障停机",
  1500. "stop6": "落布米数达到停机",
  1501. "stop7": "盘头剩余圈数达到停机",
  1502. },
  1503. LastAlarmDevs: {},
  1504. //告警设备列表数据
  1505. AlarmTable: function (data) {
  1506. this.AlarmData = data;
  1507. var t = $("#dev_alarm_list>tbody").html("")
  1508. if (data == null || data.length == 0) {
  1509. $("#dev_alarm .content").hide();
  1510. $("#dev_alarm .title").html("当前无告警");
  1511. for (var devcode in modelsMap) {
  1512. this.LastAlarmDevs[devcode] = null;
  1513. if (this.PanAlarm[devcode] == null) {
  1514. //还原设备状态
  1515. ChangeModelColor(devcode);
  1516. ChangeModelAlarmState2(devCode); //"00ff00" 绿色
  1517. }
  1518. }
  1519. return
  1520. }
  1521. var alarmDev = {};
  1522. for (var i = 0; i < this.AlarmData.length; i++) {
  1523. alarmDev[this.AlarmData[i].code] = this.AlarmData[i].type;
  1524. }
  1525. $("#dev_alarm .title").html("");
  1526. $("#dev_alarm .content").show();
  1527. var tpl = '<tr style="font-weight:bold" devno="{1}"><td style="width: 30%;">{1}#</td><td style="width: 70%;color:{COLOR}">{2}</td></tr>';
  1528. var lst = [];
  1529. for (var devcode in alarmDev) {
  1530. var alarmInfo = alarmDev[devcode];
  1531. var color = "rgb(206,161,94)" //默认告警文本颜色
  1532. var typeName = this.AlarmType[alarmInfo];
  1533. if (typeName.indexOf("故障") > -1 || typeName.indexOf("掉线") > -1) color = "rgb(195,70,76)" //红色提醒
  1534. lst.push(tpl.replace(/\{1\}/gi, devcode.replace(/C_/g, "")).replace(/\{2\}/g, typeName).replace('{COLOR}', color))
  1535. }
  1536. t.html(lst.join(''));
  1537. var noAlarmDevs = [];
  1538. if (MODEL_LOADED == 1) {
  1539. for (var devcode in modelsMap) {
  1540. if (OFFLINE_DEVS[devcode] == 1) continue;
  1541. var alarmInfo = alarmDev[devcode];
  1542. //上一次没有告警,本次有告警,需要设置成告警状态
  1543. if (alarmInfo != null) {
  1544. if (this.LastAlarmDevs[devcode] == null) {
  1545. var typeName = this.AlarmType[alarmInfo];
  1546. if (MODEL_LOADED == 1) {
  1547. //机器告警提示
  1548. //ChangeModelColor(devcode, DEV_ALAR_COLOR, typeName)
  1549. ChangeModelAlarmState2(devcode, DataFill.AlarmColorTypeCode[alarmInfo]);
  1550. } else {
  1551. //记录下来,等待模型加载完成时处理
  1552. //ALARM_DEVS.push(devcode + ">"+DEV_ALAR_COLOR+">" + typeName)
  1553. ALARM_DEVS.push(devcode + ">" + DataFill.AlarmColorTypeCode[alarmInfo] + ">" + typeName)
  1554. }
  1555. }
  1556. this.LastAlarmDevs[devcode] = 1;
  1557. } else {
  1558. //上一次有告警,并且没有盘头告警时,本次未告警,需要恢复成未告警状态
  1559. if (this.LastAlarmDevs[devcode] == 1 && this.PanAlarm[devcode] == null) {
  1560. noAlarmDevs.push(devcode);
  1561. }
  1562. this.LastAlarmDevs[devcode] = null;
  1563. }
  1564. }
  1565. }
  1566. t.find("tr").off().on('click', function () {
  1567. //点击告警行
  1568. var devno = $.trim($(this).attr('devno'))
  1569. if (devno == '') return;
  1570. ShowInfo("C_" + devno)
  1571. });
  1572. var tb = $("#dev_alarm_list");
  1573. if (tb.height() > tb.parent().height()) {
  1574. if (this.devAlarmAutoLoadTimter != null) {
  1575. clearInterval(this.devAlarmAutoLoadTimter);
  1576. }
  1577. tb.css({"top": "0px", "position": "relative"});
  1578. this.devAlarmAutoLoadTimter = window.setInterval(function () {
  1579. var tb = $("#dev_alarm_list");
  1580. var tbtop = tb.css("top").replace("px", "") * 1;
  1581. if (Math.abs(tbtop) >= (tb.height() - 32)) {
  1582. tb.css("top", "0px");
  1583. } else {
  1584. tb.css("top", (tbtop - 32) + "px");
  1585. }
  1586. }, 3000);
  1587. } else {
  1588. clearInterval(this.devAlarmAutoLoadTimter)
  1589. tb.css("top", "0px");
  1590. }
  1591. if (noAlarmDevs.length > 0) {
  1592. for (var i = 0; i < noAlarmDevs.length; i++) {
  1593. //还原设备的无告警状态
  1594. ChangeModelColor(noAlarmDevs[i])
  1595. ChangeModelAlarmState2(noAlarmDevs[i]) //00ff00
  1596. }
  1597. }
  1598. },
  1599. //告警趋势数据填充
  1600. AlarmLine: function (data) {
  1601. //只获取数据中的alarm数据
  1602. var t = $("#echarts_alarm");
  1603. var alarmWeek = [];
  1604. var times = [];
  1605. var v_series = [];
  1606. for (var i = 0; i < data.length; i++) {
  1607. var v = data[i]['alarm'];
  1608. var tv = data[i]['time'].split("-")
  1609. times.push(tv[1] + "-" + tv[2])
  1610. if (v != null) alarmWeek.push(v)
  1611. }
  1612. if (alarmWeek.length == 0) {
  1613. t.parent().hide();
  1614. } else {
  1615. v_series.push({
  1616. name: "",
  1617. type: 'line',
  1618. smooth: true,
  1619. //symbol: 'none',
  1620. data: alarmWeek,
  1621. itemStyle: {
  1622. normal: {
  1623. color: '#F0F275', // 这里设置折线的颜色
  1624. lineStyle: {
  1625. color: '#F0F27560' // 这里同时设置线头的颜色
  1626. }
  1627. }
  1628. },
  1629. });
  1630. var opt = {
  1631. title: {
  1632. show: false, //不显示标题
  1633. text: '',
  1634. textStyle: {
  1635. color: "rgb(89, 151, 229)",
  1636. fontWeight: "bold"
  1637. },
  1638. top: "0px",
  1639. left: "30px"
  1640. },
  1641. tooltip: {
  1642. trigger: 'axis',
  1643. formatter: function (params) {
  1644. let xv='';
  1645. let result = '';
  1646. params.forEach(function (item) {
  1647. xv=`${item.name}<br/>`;
  1648. result += ` ${item.marker} ${item.value}(次)<br/>`;
  1649. });
  1650. return xv+result;
  1651. }
  1652. },
  1653. legend: {
  1654. show: false, //不显示图例
  1655. inactiveColor: "#04417A",
  1656. data: "",
  1657. textStyle: {color: "#fff"},
  1658. top: "0px"
  1659. },
  1660. grid: {
  1661. left: '1%',
  1662. right: '1%',
  1663. bottom: '2%',
  1664. top: '5%',
  1665. containLabel: true
  1666. },
  1667. xAxis: {
  1668. type: 'category',
  1669. boundaryGap: false,
  1670. axisLabel: {
  1671. rotate: 45,
  1672. color: "#fff"
  1673. },
  1674. data: times
  1675. },
  1676. yAxis: {
  1677. type: 'value',
  1678. nameTextStyle: {
  1679. color: "#fff"
  1680. },
  1681. axisLabel: {
  1682. color: "rgb(203,215,235)"
  1683. },
  1684. splitLine: {
  1685. lineStyle: {
  1686. color: "#7DA7CD",
  1687. type: "dashed",
  1688. width: 1
  1689. }
  1690. }
  1691. },
  1692. series: v_series
  1693. };
  1694. var echartsEle = echarts.init(t[0]);
  1695. echartsEle.setOption(opt);
  1696. }
  1697. //动态设置停机原因的top
  1698. $("#dev_stop").css("top", ($("#dev_alarm").offset().top * 1 + $("#dev_alarm").height() + 15) + "px");
  1699. },
  1700. DevInfo: function (data) {
  1701. $("#dev_state_total").html(data.total);
  1702. $("#dev_state_runtotal").html(data.online);
  1703. $("#dev_state .content .stat .number").each(function () {
  1704. var attr = $(this).attr("attr");
  1705. $(this).html(data[attr])
  1706. })
  1707. },
  1708. StopLine: function (data, typecode) {
  1709. var t = $("#dev_stop");
  1710. var week = {"stop1A": [], "stop2A": [], "stop3A": [], "stop1B": [], "stop2B": [], "stop3B": []};
  1711. var times = [];
  1712. var v_series = [];
  1713. for (var i = 0; i < data.length; i++) {
  1714. var tv = data[i]['time'].split("-")
  1715. times.push(tv[1] + "-" + tv[2])
  1716. for (var k1 in week) {
  1717. week[k1].push(data[i][k1])
  1718. }
  1719. }
  1720. if ((week.stop1A.length + week.stop2A.length + week.stop3A.length + week.stop1B.length + week.stop2B.length + week.stop3B.length) == 0) {
  1721. t.find(".content").hide();
  1722. t.find(".title").html("无机器停机");
  1723. $("#echarts_stop").html("");
  1724. return;
  1725. }
  1726. t.find(".content").show();
  1727. t.find(".title").html("");
  1728. var option = {
  1729. title: {
  1730. show: false,
  1731. text: '',
  1732. left: 'center',
  1733. top: '1%',
  1734. bottom: '0'
  1735. },
  1736. color: ["#37A2DA", "#32C5E9", "#67E0E3", "#9FE6B8",],
  1737. tooltip: {
  1738. trigger: 'axis',
  1739. formatter: function (params) {
  1740. let xv='';
  1741. let result = '';
  1742. params.forEach(function (item) {
  1743. xv=`${item.name}<br/>`;
  1744. result += ` ${item.marker} ${item.seriesName}: ${item.value}(次)<br/>`;
  1745. });
  1746. return xv+result;
  1747. }
  1748. },
  1749. legend: {
  1750. data: ['停经片A班', 'CCD断纱A班', '人工停机A班', '停经片B班', 'CCD断纱B班', '人工停机B班',],
  1751. button: '5%',
  1752. textStyle: {color: "#fff"},
  1753. top: "0",
  1754. },
  1755. grid: {
  1756. containLabel: true,
  1757. top: '25%',
  1758. bottom: '0',
  1759. right: '1%',
  1760. left: '1%'
  1761. },
  1762. xAxis: [{
  1763. type: 'category',
  1764. boundaryGap: true,
  1765. data: times,
  1766. axisLabel: {
  1767. rotate: 45,
  1768. color: "#fff"
  1769. },
  1770. axisPointer: {snap: false}
  1771. }],
  1772. yAxis: [{
  1773. type: 'value',
  1774. axisPointer: {snap: false},
  1775. axisLabel: {
  1776. color: "rgb(203,215,235)"
  1777. },
  1778. splitLine: {
  1779. lineStyle: {
  1780. color: "#7DA7CD",
  1781. type: "dashed",
  1782. width: 1
  1783. }
  1784. }
  1785. }],
  1786. series: [{
  1787. name: '停经片A班',
  1788. type: 'bar',
  1789. barWidth: 5,
  1790. stack: 'jp',
  1791. data: week.stop1A
  1792. }, {
  1793. name: '停经片B班',
  1794. type: 'bar',
  1795. stack: 'jp',
  1796. data: week.stop2A
  1797. }, {
  1798. name: 'CCD断纱A班',
  1799. type: 'bar',
  1800. barWidth: 5,
  1801. stack: 'ccd',
  1802. data: week.stop3A
  1803. }, {
  1804. name: 'CCD断纱B班',
  1805. type: 'bar',
  1806. stack: 'ccd',
  1807. data: week.stop1B
  1808. }, {
  1809. name: '人工停机A班',
  1810. type: 'bar',
  1811. barWidth: 5,
  1812. stack: 'r',
  1813. data: week.stop2B
  1814. }, {
  1815. name: '人工停机B班',
  1816. type: 'bar',
  1817. stack: 'r',
  1818. data: week.stop3B
  1819. }]
  1820. };
  1821. var echartsEle = echarts.init($("#echarts_stop")[0]);
  1822. echartsEle.setOption(option);
  1823. },
  1824. LoadSCXL: function (data) {
  1825. //生产效率
  1826. $("#totay1").html(data.totalLength.toFixed(2))
  1827. $("#totay2").html(data.totalWeight.toFixed(2))
  1828. $("#scxl_a>td:eq(1)").html(data.atime.toFixed(2))
  1829. $("#scxl_a>td:eq(2)").html(data.alength.toFixed(2))
  1830. $("#scxl_a>td:eq(3)").html(data.aweight.toFixed(2))
  1831. $("#scxl_a>td:eq(4)").html(data.aefficiency.toFixed(2))
  1832. $("#scxl_b>td:eq(1)").html(data.btime.toFixed(2))
  1833. $("#scxl_b>td:eq(2)").html(data.blength.toFixed(2))
  1834. $("#scxl_b>td:eq(3)").html(data.bweight.toFixed(2))
  1835. $("#scxl_b>td:eq(4)").html(data.befficiency.toFixed(2))
  1836. },
  1837. LoadJDL: function (data) {
  1838. //稼动率
  1839. //获取数据中efficiency、aefficiency、befficiency
  1840. var t = $("#echarts_jiadonglv")
  1841. var week_efficiency = [];
  1842. var week_aefficiency = [];
  1843. var week_befficiency = [];
  1844. var times = [];
  1845. var v_series = [];
  1846. for (var i = 0; i < data.length; i++) {
  1847. var v = data[i]['efficiency'];
  1848. var tv = data[i]['time'].split("-")
  1849. times.push(tv[1] + "-" + tv[2])
  1850. if (v != null) week_efficiency.push(v);
  1851. week_aefficiency.push(data[i]['aefficiency'])
  1852. week_befficiency.push(data[i]['befficiency'])
  1853. }
  1854. if (week_efficiency.length == 0) {
  1855. return
  1856. }
  1857. v_series.push({
  1858. name: "总稼动率", type: 'line', smooth: true, //symbol: 'none',
  1859. data: week_efficiency, itemStyle: {
  1860. normal: {
  1861. color: '#F0F275', // 这里设置折线的颜色
  1862. lineStyle: {
  1863. color: '#F0F275' // 这里同时设置线头的颜色
  1864. }
  1865. }
  1866. },
  1867. });
  1868. v_series.push({
  1869. name: "A组稼动率", type: 'line', smooth: true, //symbol: 'none',
  1870. data: week_aefficiency, itemStyle: {
  1871. normal: {
  1872. color: '#1EFFFF', // 这里设置折线的颜色
  1873. lineStyle: {
  1874. color: '#1EFFFF' // 这里同时设置线头的颜色
  1875. }
  1876. }
  1877. },
  1878. });
  1879. v_series.push({
  1880. name: "B组稼动率", type: 'line', smooth: true, //symbol: 'none',
  1881. data: week_befficiency, itemStyle: {
  1882. normal: {
  1883. color: '#295589', // 这里设置折线的颜色
  1884. lineStyle: {
  1885. color: '#295589' // 这里同时设置线头的颜色
  1886. }
  1887. }
  1888. },
  1889. });
  1890. var opt = {
  1891. title: {
  1892. show: false, //不显示标题
  1893. text: '',
  1894. textStyle: {
  1895. color: "rgb(89, 151, 229)",
  1896. fontWeight: "bold"
  1897. },
  1898. top: "0px",
  1899. left: "30px"
  1900. },
  1901. tooltip: {
  1902. trigger: 'axis',
  1903. formatter: function (params) {
  1904. let xv='';
  1905. let result = '';
  1906. params.forEach(function (item) {
  1907. xv=`${item.name}<br/>`;
  1908. result += ` ${item.marker} ${item.seriesName}: ${item.value} %<br/>`;
  1909. });
  1910. return xv+result;
  1911. }
  1912. },
  1913. legend: {
  1914. show: true, //不显示图例
  1915. inactiveColor: "#04417A",
  1916. data: "",
  1917. textStyle: {color: "#fff"},
  1918. top: "5",
  1919. },
  1920. grid: {
  1921. left: '3%',
  1922. right: '1%',
  1923. bottom: '0',
  1924. top: '25%',
  1925. containLabel: true
  1926. },
  1927. xAxis: {
  1928. type: 'category',
  1929. boundaryGap: false,
  1930. axisLabel: {
  1931. rotate: 45,
  1932. color: "#fff"
  1933. },
  1934. data: times
  1935. },
  1936. yAxis: {
  1937. type: 'value',
  1938. nameTextStyle: {
  1939. color: "#fff"
  1940. },
  1941. axisLabel: {
  1942. color: "rgb(203,215,235)"
  1943. },
  1944. splitLine: {
  1945. lineStyle: {
  1946. color: "#7DA7CD",
  1947. type: "dashed",
  1948. width: 1
  1949. }
  1950. }
  1951. },
  1952. series: v_series
  1953. };
  1954. var echartsEle = echarts.init(t[0]);
  1955. echartsEle.setOption(opt);
  1956. },
  1957. LoadSCLine: function (data) {
  1958. //生产趋势
  1959. //获取数据中weight、aweight、bweight
  1960. var t = $("#echarts_sc_qushi")
  1961. var week_efficiency = [];
  1962. var week_aefficiency = [];
  1963. var week_befficiency = [];
  1964. var times = [];
  1965. var v_series = [];
  1966. for (var i = 0; i < data.length; i++) {
  1967. var v = data[i]['weight'];
  1968. var tv = data[i]['time'].split("-")
  1969. times.push(tv[1] + "-" + tv[2])
  1970. if (v != null) week_efficiency.push(v);
  1971. week_aefficiency.push(data[i]['aweight'])
  1972. week_befficiency.push(data[i]['bweight'])
  1973. }
  1974. if (week_efficiency.length == 0) {
  1975. return
  1976. }
  1977. v_series.push({
  1978. name: "白坯布总产量", type: 'line', smooth: false, //symbol: 'none',
  1979. data: week_efficiency, itemStyle: {
  1980. normal: {
  1981. color: '#F0F275', // 这里设置折线的颜色
  1982. lineStyle: {
  1983. color: '#F0F275' // 这里同时设置线头的颜色
  1984. }
  1985. }
  1986. },
  1987. });
  1988. v_series.push({
  1989. name: "A组产量", type: 'bar', stack: '1', smooth: true, //symbol: 'none',
  1990. data: week_aefficiency, itemStyle: {
  1991. normal: {
  1992. color: '#1EFFFF', // 这里设置折线的颜色
  1993. lineStyle: {
  1994. color: '#1EFFFF' // 这里同时设置线头的颜色
  1995. }
  1996. }
  1997. },
  1998. barWidth: "15",
  1999. itemStyle: {
  2000. color: new echarts.graphic.LinearGradient(
  2001. 0, 0, 0, 1, // 这四个参数分别表示渐变的起点 (x1, y1) 与终点 (x2, y2)
  2002. [
  2003. {offset: 0, color: '#1EFFFF'}, // 0% 处的颜色
  2004. {offset: 1, color: '#1D7777'} // 100% 处的颜色
  2005. ]
  2006. )
  2007. }
  2008. });
  2009. v_series.push({
  2010. name: "B组产量", type: 'bar', stack: '1', smooth: true, //symbol: 'none',
  2011. data: week_befficiency, itemStyle: {
  2012. normal: {
  2013. color: '#295589', // 这里设置折线的颜色
  2014. lineStyle: {
  2015. color: '#295589' // 这里同时设置线头的颜色
  2016. }
  2017. }
  2018. },
  2019. barWidth: "15",
  2020. itemStyle: {
  2021. barBorderRadius: [3, 3, 0, 0,],
  2022. color: new echarts.graphic.LinearGradient(
  2023. 0, 0, 0, 1, // 这四个参数分别表示渐变的起点 (x1, y1) 与终点 (x2, y2)
  2024. [
  2025. {offset: 0, color: '#32A9FF'}, // 0% 处的颜色
  2026. {offset: 1, color: '#2B5A7C'} // 100% 处的颜色
  2027. ]
  2028. )
  2029. }
  2030. });
  2031. var opt = {
  2032. title: {
  2033. show: false, //不显示标题
  2034. text: '',
  2035. textStyle: {
  2036. color: "rgb(89, 151, 229)",
  2037. fontWeight: "bold"
  2038. },
  2039. top: "0px",
  2040. left: "30px"
  2041. },
  2042. legend: {
  2043. show: true, //不显示图例
  2044. inactiveColor: "#04417A",
  2045. data: "",
  2046. textStyle: {color: "#fff"},
  2047. top: "5",
  2048. },
  2049. tooltip: {
  2050. trigger: 'axis',
  2051. axisPointer: {
  2052. label: {
  2053. show: true,
  2054. backgroundColor: '#fff',
  2055. color: '#556677',
  2056. borderColor: 'rgba(0,0,0,0)',
  2057. shadowColor: 'rgba(0,0,0,0)',
  2058. shadowOffsetY: 0
  2059. },
  2060. lineStyle: {
  2061. width: 0
  2062. }
  2063. },
  2064. backgroundColor: '#fff',
  2065. textStyle: {
  2066. color: '#5c6c7c'
  2067. },
  2068. padding: [10, 10],
  2069. extraCssText: 'box-shadow: 1px 0 2px 0 rgba(163,163,163,0.5)',
  2070. formatter: function (params) {
  2071. let xv='';
  2072. let result = '';
  2073. params.forEach(function (item) {
  2074. xv=`${item.name}<br/>`;
  2075. result += ` ${item.marker} ${item.seriesName}: ${item.value}(米/日)<br/>`;
  2076. });
  2077. return xv+result;
  2078. }
  2079. },
  2080. grid: {
  2081. left: '3%',
  2082. right: '1%',
  2083. bottom: '0',
  2084. top: '25%',
  2085. containLabel: true
  2086. },
  2087. xAxis: {
  2088. type: 'category',
  2089. boundaryGap: false,
  2090. axisLabel: {
  2091. rotate: 45,
  2092. color: "#fff"
  2093. },
  2094. data: times
  2095. },
  2096. yAxis: {
  2097. type: 'value',
  2098. nameTextStyle: {
  2099. color: "#fff"
  2100. },
  2101. axisLabel: {
  2102. color: "rgb(203,215,235)"
  2103. },
  2104. splitLine: {
  2105. lineStyle: {
  2106. color: "#7DA7CD",
  2107. type: "dashed",
  2108. width: 1
  2109. }
  2110. }
  2111. },
  2112. series: v_series
  2113. };
  2114. var echartsEle = echarts.init(t[0]);
  2115. echartsEle.setOption(opt);
  2116. },
  2117. LoadUsedLine: function (data) {
  2118. //能耗趋势
  2119. //获取数据中kwh、akwh、bkwh
  2120. var t = $("#echarts_used_qushi")
  2121. var week_efficiency = [];
  2122. var week_aefficiency = [];
  2123. var week_befficiency = [];
  2124. var times = [];
  2125. var v_series = [];
  2126. for (var i = 0; i < data.length; i++) {
  2127. var v = data[i]['kwh'];
  2128. var tv = data[i]['time'].split("-")
  2129. times.push(tv[1] + "-" + tv[2])
  2130. if (v != null) week_efficiency.push(v);
  2131. week_aefficiency.push(data[i]['akwh'])
  2132. week_befficiency.push(data[i]['bkwh'])
  2133. }
  2134. if (week_efficiency.length == 0) {
  2135. return
  2136. }
  2137. v_series.push({
  2138. name: "总电量", type: 'line', smooth: true, //symbol: 'none',
  2139. data: week_efficiency, itemStyle: {
  2140. normal: {
  2141. color: '#F0F275', // 这里设置折线的颜色
  2142. lineStyle: {
  2143. color: '#F0F275' // 这里同时设置线头的颜色
  2144. }
  2145. }
  2146. },
  2147. });
  2148. v_series.push({
  2149. name: "A组电量", type: 'line', smooth: true, //symbol: 'none',
  2150. data: week_aefficiency, itemStyle: {
  2151. normal: {
  2152. color: '#1EFFFF', // 这里设置折线的颜色
  2153. lineStyle: {
  2154. color: '#1EFFFF' // 这里同时设置线头的颜色
  2155. }
  2156. }
  2157. },
  2158. });
  2159. v_series.push({
  2160. name: "B组电量", type: 'line', smooth: true, //symbol: 'none',
  2161. data: week_befficiency, itemStyle: {
  2162. normal: {
  2163. color: '#295589', // 这里设置折线的颜色
  2164. lineStyle: {
  2165. color: '#295589' // 这里同时设置线头的颜色
  2166. }
  2167. }
  2168. },
  2169. });
  2170. var opt = {
  2171. title: {
  2172. show: false, //不显示标题
  2173. text: '',
  2174. textStyle: {
  2175. color: "rgb(89, 151, 229)",
  2176. fontWeight: "bold"
  2177. },
  2178. top: "0px",
  2179. left: "30px"
  2180. },
  2181. tooltip: {
  2182. trigger: 'axis',
  2183. formatter: function (params) {
  2184. let xv='';
  2185. let result = '';
  2186. params.forEach(function (item) {
  2187. xv=`${item.name}<br/>`;
  2188. result += ` ${item.marker} ${item.seriesName}: ${item.value}(kWh)<br/>`;
  2189. });
  2190. return xv+result;
  2191. }
  2192. },
  2193. legend: {
  2194. show: true, //不显示图例
  2195. inactiveColor: "#04417A",
  2196. data: "",
  2197. textStyle: {color: "#fff"},
  2198. top: "5",
  2199. },
  2200. grid: {
  2201. left: '3%',
  2202. right: '1%',
  2203. bottom: '0',
  2204. top: '25%',
  2205. containLabel: true
  2206. },
  2207. xAxis: {
  2208. type: 'category',
  2209. boundaryGap: false,
  2210. axisLabel: {
  2211. rotate: 45,
  2212. color: "#fff"
  2213. },
  2214. data: times
  2215. },
  2216. yAxis: {
  2217. type: 'value',
  2218. nameTextStyle: {
  2219. color: "#fff"
  2220. },
  2221. axisLabel: {
  2222. color: "rgb(203,215,235)"
  2223. },
  2224. splitLine: {
  2225. lineStyle: {
  2226. color: "#7DA7CD",
  2227. type: "dashed",
  2228. width: 1
  2229. }
  2230. }
  2231. },
  2232. series: v_series
  2233. };
  2234. var echartsEle = echarts.init(t[0]);
  2235. echartsEle.setOption(opt);
  2236. },
  2237. LoadPan(data) {
  2238. //盘头数据处理
  2239. this.Pan = {};//先存储,设备详情时需要使用到
  2240. if (data == null || data.length == 0) return;
  2241. /*
  2242. var alarmDev = {};
  2243. for (var i = 0; i < this.AlarmData.length; i++) {
  2244. alarmDev[this.AlarmData[i].code] = 1;
  2245. }
  2246. */
  2247. for (var i = 0; i < data.length; i++) {
  2248. var devCode = data[i].code;
  2249. this.Pan[devCode] = data[i].panPercent
  2250. /*
  2251. if (alarmDev[devCode] == 1) {
  2252. continue; //该设备有告警,不处理盘头
  2253. }
  2254. //判断盘头中是否有低于20的
  2255. var panTmp = data[i].panPercent;
  2256. var is20 = false;//是否是小于20%的
  2257. for (var p = 0; p < panTmp.length; p++) {
  2258. if (panTmp[p] < 20) {
  2259. if (this.PanAlarm[devCode] != 20) {
  2260. //该设备进行告警
  2261. if (MODEL_LOADED == 1) {
  2262. //机器告警提示
  2263. console.log('设备', devCode, '盘头小于20%')
  2264. //ChangeModelColor(devCode, DEV_ALAR_COLOR, this.AlarmType["1000"])
  2265. } else {
  2266. //记录下来,等待模型加载完成时处理
  2267. //ALARM_DEVS.push(devCode + ">"+DEV_ALAR_COLOR+">"+this.AlarmType["1000"])
  2268. }
  2269. }
  2270. is20 = true
  2271. //this.PanAlarm[devCode] = 20
  2272. break
  2273. }
  2274. }
  2275. if (is20) {
  2276. //当前盘头有小于20%的,则不再做其他判断了
  2277. continue
  2278. }
  2279. //判断盘头中是否有低于50的,但大于20%的
  2280. var is50 = false;
  2281. for (var p = 0; p < panTmp.length; p++) {
  2282. if (panTmp[p] < 50 && panTmp[p] >= 20) {
  2283. if (this.PanAlarm[devCode] != 50) {
  2284. //该设备进行提醒
  2285. if (MODEL_LOADED == 1) {
  2286. //机器提醒提示
  2287. console.log('设备', devCode, '盘头小于50%大于20%')
  2288. //ChangeModelColor(devCode, DEV_HINT_COLOR, this.AlarmType["1001"])
  2289. } else {
  2290. //记录下来,等待模型加载完成时处理
  2291. //ALARM_DEVS.push(devCode + ">"+DEV_HINT_COLOR+">"+this.AlarmType["1001"])
  2292. }
  2293. }
  2294. is50 = true
  2295. //this.PanAlarm[devCode] = 50
  2296. break
  2297. }
  2298. }
  2299. if (is50) {
  2300. continue
  2301. }
  2302. this.PanAlarm[devCode] = null;
  2303. if (MODEL_LOADED == 1) {
  2304. //盘头剩余比例正常,隐藏提示标签
  2305. ChangeModelColor(devCode)
  2306. }
  2307. */
  2308. }
  2309. }
  2310. }
  2311. //汉化日期控件
  2312. $.datepicker.regional['zh-CN'] = {
  2313. clearText: '清除',
  2314. clearStatus: '清除已选日期',
  2315. closeText: '关闭',
  2316. closeStatus: '不改变当前选择',
  2317. prevText: '<上月',
  2318. prevStatus: '显示上月',
  2319. prevBigText: '<<',
  2320. prevBigStatus: '显示上一年',
  2321. nextText: '下月>',
  2322. nextStatus: '显示下月',
  2323. nextBigText: '>>',
  2324. nextBigStatus: '显示下一年',
  2325. currentText: '今天',
  2326. currentStatus: '显示本月',
  2327. monthNames: ['一月', '二月', '三月', '四月', '五月', '六月', '七月', '八月', '九月', '十月', '十一月', '十二月'],
  2328. monthNamesShort: ['一', '二', '三', '四', '五', '六', '七', '八', '九', '十', '十一', '十二'],
  2329. monthStatus: '选择月份',
  2330. yearStatus: '选择年份',
  2331. weekHeader: '周',
  2332. weekStatus: '年内周次',
  2333. dayNames: ['星期日', '星期一', '星期二', '星期三', '星期四', '星期五', '星期六'],
  2334. dayNamesShort: ['周日', '周一', '周二', '周三', '周四', '周五', '周六'],
  2335. dayNamesMin: ['日', '一', '二', '三', '四', '五', '六'],
  2336. dayStatus: '设置 DD 为一周起始',
  2337. dateStatus: '选择 m月 d日, DD',
  2338. dateFormat: 'yy-mm-dd',
  2339. firstDay: 1,
  2340. initStatus: '请选择日期',
  2341. isRTL: false
  2342. };
  2343. $(document).ready(function () {
  2344. $(window).on('wheel', function(event) {
  2345. // 检查 event.originalEvent.deltaY 来判断滚动方向
  2346. if (event.originalEvent.deltaY > 0) {
  2347. console.log('向下滚动:缩小'+zoomCount);
  2348. zoomCount = zoomCount-1
  2349. if(zoomCount<=-3 && currentTargetType!="FAC"){
  2350. zoomCount=0;
  2351. //切换在全厂视图
  2352. loadFacModel(playerNative);
  2353. backMasterViewByFac();
  2354. }
  2355. } else {
  2356. console.log('向上滚动:放大');
  2357. zoomCount = zoomCount+1
  2358. }
  2359. });
  2360. $.datepicker.setDefaults($.datepicker.regional['zh-CN']); //设置日期控制语言
  2361. $("#datepicker1").datepicker({
  2362. dateFormat: "yy-mm-dd",
  2363. showOn: "button",
  2364. buttonText: "选择日期",
  2365. changeMonth: true,
  2366. changeYear: true,
  2367. numberOfMonths: 1,
  2368. rangeSelect: true,
  2369. onClose: function (selectedDate) {
  2370. $("#datepicker2").datepicker("option", "minDate", selectedDate);
  2371. $("#datepicker2").val('');
  2372. var isNowDay = selectedDate==new Date().Format("yyyy-MM-dd");
  2373. var hour1Opts = [];
  2374. var nowHour = new Date().Format("h");
  2375. for (var i = 0; i < 24; i++) {
  2376. if( !isNowDay || (isNowDay && i<=nowHour)) hour1Opts.push('<option value="' + i + '">' + i + ' 时</option>');
  2377. }
  2378. $("#hour1,#hourP1").html(hour1Opts.join(''))
  2379. }
  2380. });
  2381. $("#datepicker2").datepicker({
  2382. dateFormat: "yy-mm-dd",
  2383. showOn: "button",
  2384. buttonText: "选择日期",
  2385. changeMonth: true,
  2386. changeYear: true,
  2387. numberOfMonths: 1,
  2388. rangeSelect: true,
  2389. defaultDate: new Date().Format("yyyy-MM-dd"),
  2390. onClose:function(selectedDate){
  2391. var isNowDay = selectedDate==new Date().Format("yyyy-MM-dd");
  2392. var hour2Opts = [];
  2393. var nowHour = new Date().Format("h");
  2394. for (var i = 0; i < 24; i++) {
  2395. if( !isNowDay || (isNowDay && i<=nowHour)) hour2Opts.push('<option value="' + i + '">' + i + ' 时</option>');
  2396. }
  2397. $("#hour2,#hourP2").html(hour2Opts.join(''))
  2398. }
  2399. });
  2400. //日期不能超过当前日期
  2401. $("#datepicker1,#datepicker2").datepicker("option", "maxDate", new Date().Format("yyyy-MM-dd"));
  2402. $("#date_select,#ui-datepicker-div,#day_select").on("click", function (e) {
  2403. e.stopPropagation();
  2404. });
  2405. var ua = navigator.userAgent;
  2406. var isIE=false;
  2407. if (ua.indexOf('MSIE') != -1 || ua.indexOf('Trident') != -1) {
  2408. isIE=true;
  2409. }
  2410. //纱线规格导出生产预期天数输入控制处理
  2411. $('#prev_day').on('dblclick',function(event) {
  2412. event.preventDefault();
  2413. event.stopPropagation();
  2414. return false;
  2415. });
  2416. $("#prev_day").on("keydown",function(event){
  2417. var v = $(this).val();
  2418. if (isIE) {
  2419. if ( ((event.keyCode > 47) && (event.keyCode < 58)) || (event.keyCode == 8) ) {  // 判断键值
  2420. if(event.keyCode != 8 && (v+String.fromCharCode(event.keyCode))*1>60){
  2421. return false;
  2422. }
  2423. return true;
  2424. } else {
  2425. return false;
  2426. }
  2427. } else {
  2428. if ( ((event.which > 47) && (event.which < 58)) || (event.which == 8) || (event.keyCode == 17) ) {
  2429. if(event.keyCode != 17 && event.which != 8 && (v+String.fromCharCode(event.which))*1>60){
  2430. return false;
  2431. }
  2432. return true;
  2433. } else {
  2434. return false;
  2435. }
  2436. }
  2437. }).focus(function() {
  2438. this.style.imeMode='disabled'; // 禁用输入法,禁止输入中文字符
  2439. });
  2440. //纱线规格导出确定按钮事件处理
  2441. $("#day_select .daySelected_ok>button").on('click',function(){
  2442. var v=$("#prev_day").val();
  2443. if(isNaN(v)){
  2444. $("#prev_day").val('');
  2445. return;
  2446. }
  2447. window.open(SERVER_URL + "/export/yarn-specifications?day="+(v*1));
  2448. })
  2449. $("#dev_stop").css("top", ($("#dev_alarm").offset().top * 1 + $("#dev_alarm").height() + 15) + "px");
  2450. $("#search input:eq(0)").off().on('keypress', function (e) {
  2451. if (e.keyCode == 13) {
  2452. search()
  2453. }
  2454. });
  2455. $("#imp_btn").on('click', function (e) {
  2456. e.stopPropagation();
  2457. $('#imp_item').show();
  2458. $('#search_result').hide()
  2459. })
  2460. $("#search .search_btn").on('click', function (e) {
  2461. e.stopPropagation();
  2462. search();
  2463. })
  2464. //导出数据项选择
  2465. $("#imp_item>div").on('click', function (e) {
  2466. $(this).parent().find(".active").removeClass("active");
  2467. //导出数据
  2468. var code = $(this).addClass("active").attr("itemcode");
  2469. var $date_select = $("#date_select").attr("itemcode",code);
  2470. var $day_select=$("#day_select").hide();
  2471. var day = new Date();
  2472. if(day.getHours()<7){
  2473. day=day.setDate(day.getDate()-2);
  2474. }else{
  2475. day=day.setDate(day.getDate()-1);
  2476. }
  2477. var day1 = new Date().setDate(new Date(day).getDate() - 7);
  2478. $("#datepicker1").val(new Date(day1).Format("yyyy-MM-dd"))
  2479. $("#datepicker2").datepicker("option", "minDate", new Date(day1).Format("yyyy-MM-dd"));
  2480. $("#datepicker2").val(new Date(day).Format("yyyy-MM-dd"))
  2481. $("#hour1,#hourP1").val("7")
  2482. $("#hour2,#hourP2").val("19");
  2483. $("#datepicker2").parent().show();//显示结束日期选择
  2484. switch (parseInt(code)) {
  2485. case 1:
  2486. //alert("生产");
  2487. e.stopPropagation();
  2488. $("#date_select .hourAreaSelect").hide();
  2489. $("#date_select .hourPointSelect").hide();
  2490. $date_select.show().css({
  2491. "top": $(this).offset().top-10 + "px",
  2492. "left": $("#imp_item").offset().left- $("#date_select").width()-20 + "px"
  2493. })
  2494. //window.open(SERVER_URL + "/export/production");
  2495. break;
  2496. case 2:
  2497. // alert("停机原因");
  2498. e.stopPropagation();
  2499. $("#date_select .hourAreaSelect").hide();
  2500. $("#date_select .hourPointSelect").show();
  2501. $date_select.show().css({
  2502. "top": $(this).offset().top-10 + "px",
  2503. "left": $("#imp_item").offset().left- $("#date_select").width()-20 + "px"
  2504. })
  2505. break;
  2506. case 3:
  2507. // alert("并发叫料分析");
  2508. e.stopPropagation();
  2509. $("#date_select .hourAreaSelect").show();
  2510. $("#date_select .hourPointSelect").hide();
  2511. $date_select.show().css({
  2512. "top": $(this).offset().top-10 + "px",
  2513. "left": $(this).offset().left - $("#date_select").width()-20 + "px"
  2514. })
  2515. break;
  2516. case 4:
  2517. // alert("断纱分析");
  2518. e.stopPropagation();
  2519. $("#date_select .hourAreaSelect").hide();
  2520. $("#date_select .hourPointSelect").hide();
  2521. $date_select.show().css({
  2522. "top": $(this).offset().top-10 + "px",
  2523. "left": $(this).offset().left - $("#date_select").width()-20 + "px"
  2524. })
  2525. $("#datepicker2").parent().hide();//隐藏结束日期选择
  2526. var preday=new Date();
  2527. preday = preday.setDate(new Date().getDate()-1);
  2528. $("#datepicker1,#datepicker2").val(new Date(preday).Format("yyyy-MM-dd"));//默认为前一天
  2529. break;
  2530. case 5:
  2531. // alert("并发下卷分析");
  2532. e.stopPropagation();
  2533. $("#date_select .hourAreaSelect").show();
  2534. $("#date_select .hourPointSelect").hide();
  2535. $date_select.show().css({
  2536. "top": $(this).offset().top-10 + "px",
  2537. "left": $(this).offset().left - $("#date_select").width()-20 + "px"
  2538. })
  2539. break;
  2540. case 6:
  2541. // alert("告警");
  2542. e.stopPropagation();
  2543. $("#date_select .hourAreaSelect").hide();
  2544. $("#date_select .hourPointSelect").show();
  2545. $date_select.show().css({
  2546. "top": $(this).offset().top-10 + "px",
  2547. "left": $(this).offset().left - $("#date_select").width()-20 + "px"
  2548. })
  2549. break;
  2550. case 7:
  2551. // alert("平方米克重")
  2552. window.open(SERVER_URL + "/export/gram-mass");
  2553. break;
  2554. case 8:
  2555. // alert("送经量");
  2556. window.open(SERVER_URL + "/export/warp-run-in");
  2557. break;
  2558. case 9:
  2559. e.stopPropagation();
  2560. $("#prev_day").val('7');
  2561. // alert("纱线规格");
  2562. $date_select.hide();
  2563. //打开预期天数窗口
  2564. $day_select.show().css({
  2565. "top": $(this).offset().top-10 + "px",
  2566. "left": $("#imp_item").offset().left- $("#day_select").width()-20 + "px"
  2567. });
  2568. //window.open(SERVER_URL + "/export/yarn-specifications");
  2569. break;
  2570. case 10:
  2571. case 11:
  2572. case 12:
  2573. case 13:
  2574. e.stopPropagation();
  2575. $("#date_select .hourAreaSelect").hide();
  2576. $("#date_select .hourPointSelect").hide();
  2577. $date_select.show().css({
  2578. "top": $(this).offset().top-10 + "px",
  2579. "left": $(this).offset().left - $("#date_select").width()-20 + "px"
  2580. })
  2581. $("#datepicker2").parent().hide();//隐藏结束日期选择
  2582. var preday=new Date();
  2583. preday = preday.setDate(new Date().getDate()-1);
  2584. $("#datepicker1,#datepicker2").val(new Date(preday).Format("yyyy-MM-dd"));//默认为前一天
  2585. break;
  2586. }
  2587. })
  2588. //自定义导出日期确定
  2589. $("#date_select .dateSelected_ok").on('click', function () {
  2590. var s1 = $("#datepicker1").val()
  2591. var s2 = $("#datepicker2").val()
  2592. //var devcode = $.trim($("#imp_devcode").val())
  2593. var itemcode = $("#date_select").attr("itemcode");
  2594. if (s1 == "" || (s2 == ""&&itemcode!=4&&itemcode!=10&&itemcode!=11)) return;
  2595. switch (parseInt(itemcode)) {
  2596. case 1:
  2597. window.open(SERVER_URL + "/export/production?start="+s1+"&end="+s2);
  2598. break;
  2599. case 2:
  2600. var h1 = $("#hourP1").val();
  2601. var h2 = $("#hourP2").val();
  2602. s1 = s1 +" "+h1+":00:00"
  2603. s2 = s2 +" "+h2+":00:00"
  2604. window.open(SERVER_URL + "/export/stops?start="+s1+"&end="+s2);
  2605. break;
  2606. case 3:
  2607. var h1 = $("#hour1").val();
  2608. var h2 = $("#hour2").val();
  2609. window.open(SERVER_URL + "/export/stops/type/7?start="+s1+"&end="+s2+"&st="+h1+"&et="+h2);
  2610. break;
  2611. case 4:
  2612. window.open(SERVER_URL + "/export/broken-yarn?date="+s1);
  2613. break;
  2614. case 5:
  2615. var h1 = $("#hour1").val();
  2616. var h2 = $("#hour2").val();
  2617. window.open(SERVER_URL + "/export/stops/type/6?start="+s1+"&end="+s2+"&st="+h1+"&et="+h2);
  2618. break;
  2619. case 6:
  2620. var h1 = $("#hourP1").val();
  2621. var h2 = $("#hourP2").val();
  2622. s1 = s1 +" "+h1+":00:00"
  2623. s2 = s2 +" "+h2+":00:00"
  2624. window.open(SERVER_URL + "/export/alarms?start="+s1+"&end="+s2);
  2625. break;
  2626. case 10:
  2627. window.open(SERVER_URL + "/export/productivity-day?date="+s1);
  2628. break;
  2629. case 11:
  2630. window.open(SERVER_URL + "/export/productivity-month?date="+s1);
  2631. break;
  2632. case 12:
  2633. window.open(SERVER_URL + "/export/energy-day?date="+s1);
  2634. break;
  2635. case 13:
  2636. window.open(SERVER_URL + "/export/energy-month?date="+s1);
  2637. break;
  2638. }
  2639. $("body").trigger('click')
  2640. });
  2641. $("#autoplayer_btn").off().on('click', function () {
  2642. var img = $(this).find("img");
  2643. AutoPlayer = !AutoPlayer
  2644. if (AutoPlayer) {
  2645. img.attr("src", "image/auto3d_start.png");
  2646. try {
  2647. //循环播放
  2648. player.Native.CameraAnimation.setLoop(true);
  2649. // 播放动画
  2650. player.Native.CameraAnimation.start();
  2651. } catch (e) {
  2652. }
  2653. } else {
  2654. img.attr("src", "image/auto3d_stop.png");
  2655. try {
  2656. player.Native.CameraAnimation.stop();
  2657. } catch (e) {
  2658. }
  2659. }
  2660. })
  2661. $("#imp_btn_maogaodetail").off().on('click', function () {
  2662. var v = $("#maogaoDetailWin").attr("maogao")
  2663. window.open(SERVER_URL + "/formula/export/" + v)
  2664. })
  2665. //毛高比重
  2666. $("#maogao_btn").on('click', function () {
  2667. $.getJSON(SERVER_URL + "/formula/total", {}, function (data) {
  2668. if (data.code != 0) {
  2669. alert(data.msg)
  2670. return;
  2671. }
  2672. var data = data.data;
  2673. var tbody = $("#maogaoWin table:last>tbody");
  2674. tbody.html('');
  2675. tbody.find("tr:gt(0)").remove();
  2676. var ls = [];
  2677. var tpl = '<tr maogao="{height}" style="color: #FFFFFF;font-size: 20px;cursor: pointer;" title="点击可查看详情"><td width="33%">{height}</td><td width="1px" style="color: transparent">|</td><td width="33%">{num}</td><td width="1px" style="color: transparent">|</td><td width="33%">{percent}</td></tr>';
  2678. for (var i = 0; i < data.length; i++) {
  2679. var item = data[i];
  2680. ls.push(tpl.replace(/(\{height\})/gi, item.height).replace(/(\{num\})/gi, item.num).replace(/(\{percent\})/gi, item.percent))
  2681. }
  2682. tbody.append(ls.join(''));
  2683. $("#maogaoWin").show();
  2684. $("#maogaoWin table:last>tbody>tr").off().on('click', function () {
  2685. var v = $(this).attr('maogao')
  2686. //毛高详情
  2687. $.getJSON(SERVER_URL + "/formula/detail/" + v, {}, function (r) {
  2688. if (r.code == 0) {
  2689. var tplHtml = template("maogodetail_tpl", r)
  2690. $("#maogaoDetailWin table:last>tbody").html(tplHtml);
  2691. $("#maogaoDetailWin").attr("maogao", v).show();
  2692. }
  2693. })
  2694. })
  2695. })
  2696. })
  2697. //初始化小时选择项
  2698. var hour1Opts = [];
  2699. var hour2Opts = [];
  2700. var nowHour = new Date().Format("h");
  2701. for (var i = 0; i < 24; i++) {
  2702. hour1Opts.push('<option value="' + i + '">' + i + ' 时</option>');
  2703. if(i<=nowHour) hour2Opts.push('<option value="' + i + '">' + i + ' 时</option>');
  2704. }
  2705. $("#hour1,#hourP1").html(hour1Opts.join(''))
  2706. $("#hour2,#hourP2").html(hour2Opts.join(''))
  2707. });
  2708. function GetData() {
  2709. $.getJSON(SERVER_URL + "/index", {}, function (res) {
  2710. setTimeout(function () {
  2711. //每60秒主动查询一次数据
  2712. GetData()
  2713. }, INDEX_TIMEOUT);
  2714. if (res == null || res.code != 0) {
  2715. return
  2716. }
  2717. var jsondata = res.data;
  2718. $("#dev_state .content .stat .runningRatio").html(jsondata.device.runningRatio);
  2719. DataFill.AlarmLine(jsondata.weekData)
  2720. DataFill.StopLine(jsondata.weekData)
  2721. DataFill.LoadSCXL(jsondata.efficiency)
  2722. DataFill.LoadJDL(jsondata.weekData)
  2723. DataFill.LoadSCLine(jsondata.weekData)
  2724. DataFill.LoadUsedLine(jsondata.weekData)
  2725. })
  2726. }
  2727. function GetAlarmData() {
  2728. $.getJSON(SERVER_URL + "/alarm", {}, function (res) {
  2729. setTimeout(function () {
  2730. //每10秒主动查询一次数据
  2731. GetAlarmData()
  2732. }, ALARM_TIMEOUT);
  2733. if (res == null || res.code != 0) {
  2734. return
  2735. }
  2736. var jsondata = res.data;
  2737. DataFill.DevInfo(jsondata.device)
  2738. DataFill.AlarmTable(jsondata.alarm);
  2739. DataFill.LoadPan(jsondata.pan);
  2740. })
  2741. }
  2742. //获取已接入平台设备列表.将在设备模型加载完成后进行初始调用
  2743. function GetOnlineDev() {
  2744. $.getJSON(SERVER_URL + "/device/online", {}, function (res) {
  2745. setTimeout(function () {
  2746. //每5分钟主动查询一次数据
  2747. GetOnlineDev()
  2748. }, ONLIME_TIMEOUT);
  2749. if (res == null || res.code != 0) {
  2750. return
  2751. }
  2752. var jsondata = "," + res.data.join(",") + ",";
  2753. for (var devcode in modelsMap) {
  2754. //判断当前设备是否在在线设备列表中
  2755. //设备原来未接入,现在接入了才恢复正常颜色
  2756. if (jsondata.indexOf("," + devcode + ",") > -1) {
  2757. //设备已接入
  2758. if (OFFLINE_DEVS[devcode] != null) {
  2759. ChangeModelColor(devcode); //恢复原颜色
  2760. ChangeModelAlarmState2(devcode);//"00ff00"
  2761. OFFLINE_DEVS[devcode] = null;
  2762. console.log('设备上线:', devcode)
  2763. }
  2764. } else {
  2765. if (OFFLINE_DEVS[devcode] == null) {
  2766. //设备未接入
  2767. ChangeModelColor(devcode, DEV_OFFLINE_COLOR);
  2768. ChangeModelAlarmState2(devcode);
  2769. OFFLINE_DEVS[devcode] = 1
  2770. //console.log('离线设备:',devcode)
  2771. }
  2772. }
  2773. }
  2774. })
  2775. }
  2776. function backMasterView() {
  2777. zoomCount=0;
  2778. switch(currentTargetType){
  2779. case "FAC":
  2780. backMasterViewByFac();
  2781. break;
  2782. case "IN02":
  2783. backMasterViewBy02();
  2784. break;
  2785. case "IN03":
  2786. backMasterViewBy03();
  2787. break;
  2788. }
  2789. }
  2790. //全局厂房最佳视图
  2791. function backMasterViewByFac(){
  2792. if (AutoPlayer) {
  2793. const img = $("#autoplayer_btn").find("img");
  2794. img.attr("src", "image/auto3d_stop.png");
  2795. try {
  2796. player.Native.CameraAnimation.stop();
  2797. } catch (e) {
  2798. }
  2799. }
  2800. player.Native.Camera.moveTo([235.678127000173, 13.38107286701451, 74.13573809425804], [-1248.3191825020908, -262.59031050373517, -409.93944372657353], [-0.30023176822741604, -0.055832565112502126, 0.9522308596238611], 1);
  2801. }
  2802. //2号楼内部最佳视图
  2803. function backMasterViewBy02() {
  2804. if (AutoPlayer) {
  2805. const img = $("#autoplayer_btn").find("img");
  2806. img.attr("src", "image/auto3d_stop.png");
  2807. try {
  2808. player.Native.CameraAnimation.stop();
  2809. } catch (e) {
  2810. }
  2811. }
  2812. player.Native.Camera.moveTo([-60.91624261330108, -39.68511717426356, 85.99570940739352], [-61.26059834308166, -0.225858934410347, -0.5930273740619612], [-0.007940809332449061, 0.9099266223396253, 0.41469324265623975], 1);
  2813. }
  2814. //2号楼内部最佳视图
  2815. function backMasterViewBy03() {
  2816. if (AutoPlayer) {
  2817. const img = $("#autoplayer_btn").find("img");
  2818. img.attr("src", "image/auto3d_stop.png");
  2819. try {
  2820. player.Native.CameraAnimation.stop();
  2821. } catch (e) {
  2822. }
  2823. }
  2824. player.Native.Camera.moveTo([59.56050392473782, -16.715593393512307, 33.88405960390085], [-225.90035917394823, 266.6367338252189, -87.93132661854877], [-0.2057201109308161, 0.20420057431057317, 0.9570691518431909], 1);
  2825. }
  2826. function backMasterView180() {
  2827. if (AutoPlayer) {
  2828. const img = $("#autoplayer_btn").find("img");
  2829. img.attr("src", "image/auto3d_stop.png");
  2830. try {
  2831. player.Native.CameraAnimation.stop();
  2832. } catch (e) {
  2833. }
  2834. }
  2835. player.Native.Camera.moveTo([-61.71380071610987, 51.07810751258113, 79.71750535252107], [-61.26763429787266, -0.047500086249613105, -0.5366793501724771], [0.00735988539091022, -0.8433593320509241, 0.5372996083468254], 1);
  2836. }
  2837. //1.创建RemotePlayer对象
  2838. var player = new RemotePlayer({
  2839. video: document.getElementById("EngineContent"), //绑定视频标签或图片标签
  2840. signalServer: PLAYER3D_URL, //云渲染服务器,发布时需要改为实际地址
  2841. engineId: "" + Date.now(), // 引擎会话id,如果已存在则连接,没有则创建,会话在断开连接后超时自动关闭
  2842. rtcIni: 'rtc.ini', // 可指定webrtc配置文件,默认为rtc.ini,相对目录为集群节点的enginePath目录
  2843. autoResize: true, // 引擎是否跟跟随标签尺寸
  2844. limtMoveCPS: 10, // 限制每秒鼠标移动的消息个数
  2845. userTimeout: 1000 * 60 * 60 * 5, // 用户操作超时设置,毫秒
  2846. exitTimeout: 1000 * 60 * 60 * 999999, // 用户超时后多久断开会话
  2847. maxTimeout: 1000, // 会话超时时间,允许掉线后引擎保存多久,在该时间内可重新连接到会话,否则会创建新的会话
  2848. debug: false // 是否启用调试,开启后调用Native接口时会使用console.log进行记录
  2849. });
  2850. var modelLoadState={};//模型加载状态
  2851. var playerNative = null;
  2852. var playerConnState = false;
  2853. var reconntimer = null;
  2854. //2.[可选]监听连接成功消息
  2855. player.on("Connected", () => {
  2856. console.log("Has connected to engine")
  2857. playerConnState = true
  2858. if (reconntimer != null) clearTimeout(reconntimer);
  2859. });
  2860. //3.[可选]监听连接失败消息
  2861. player.on("Disconnected", (e) => {
  2862. console.log("Disconnected from engine", e);
  2863. playerConnState = false
  2864. //4.[推荐]尝试重新连接
  2865. reconntimer = setTimeout(function () {
  2866. console.log('尝试自动重连:', playerConnState)
  2867. if (playerConnState) return
  2868. player.reconnect();
  2869. }, 10000)
  2870. });
  2871. //5. [推荐] 响应UserTimeOut消息,引擎接收用户鼠标触屏事件超时发出通知
  2872. player.on("UserTimeOut", () => {
  2873. console.info(`用户长时间没有操作三维视图,会话即将退出,可调用player.resetTimer()取消退出`);
  2874. if (!AutoPlayer) $("#autoplayer_btn").trigger('click') //开启自动漫游
  2875. });
  2876. async function loadFacModel(Native){
  2877. $("body>div.hideDiv[for='FAC']").show();
  2878. $("body>div.hideDiv[for!='FAC']").hide();
  2879. await player.Native.Model.setModelVisible("IN02",false);
  2880. await player.Native.Model.setModelVisible("IN03",false);
  2881. await player.Native.Model.setModelVisible("IN04",false);
  2882. await player.Native.Model.setModelVisible("IN05",false);
  2883. currentTargetType="FAC";
  2884. if(modelLoadState[currentTargetType]==null){
  2885. var cf = "data://models/T_ALL.pr";
  2886. var errStr = await PlayerUtils.call(Native.Model.loadModel, currentTargetType, cf);
  2887. modelLoadState[currentTargetType] = true;
  2888. }
  2889. await player.Native.Model.setModelVisible(currentTargetType,true);
  2890. player.Native.CameraAnimation.clearKeyFrame();
  2891. }
  2892. async function loadIn05Model(Native){
  2893. currentTargetType="IN05";
  2894. currentTargetType="FAC";//还未实现,默认停在工厂视图
  2895. }
  2896. async function loadIn04Model(Native){
  2897. currentTargetType="IN04";
  2898. currentTargetType="FAC"; //还未实现,默认停在工厂视图
  2899. }
  2900. async function loadIn03Model(Native){
  2901. currentTargetType="IN03";
  2902. await player.Native.Model.setModelVisible("FAC",false);
  2903. $("body>div.hideDiv[for='FAC']").hide();
  2904. $("body>div.hideDiv[for='"+currentTargetType+"']").show();
  2905. if(modelLoadState[currentTargetType]==null){
  2906. var cf = "data://models/T_03.pr";
  2907. var errStr = await PlayerUtils.call(Native.Model.loadModel, currentTargetType, cf);
  2908. modelLoadState[currentTargetType] = true;
  2909. }
  2910. await player.Native.Model.setModelVisible(currentTargetType,true);
  2911. player.Native.CameraAnimation.clearKeyFrame();
  2912. }
  2913. async function loadIn02Model(Native){
  2914. currentTargetType="IN02";
  2915. await player.Native.Model.setModelVisible("FAC",false);
  2916. $("body>div.hideDiv[for='FAC']").hide();
  2917. $("body>div.hideDiv[for='"+currentTargetType+"']").show();
  2918. if(modelLoadState[currentTargetType]==null){
  2919. var cf = "data://models/T_02.pr";
  2920. var errStr = await PlayerUtils.call(Native.Model.loadModel, currentTargetType, cf);
  2921. modelLoadState[currentTargetType]=true;
  2922. //let cfInfo=await player.Native.Model.getInfo("all");
  2923. //player.Native.NodeProxy.setNodeRotation(cfInfo.nodePtr, [0,0,90]);
  2924. var rootItem = await player.Native.ModelTree.getRootItems();
  2925. var rootObj=null;
  2926. for (var i = 0; i < rootItem.length; i++) {
  2927. if(rootItem[i].name=="T_02"){
  2928. rootObj = rootItem[i]
  2929. break;
  2930. }
  2931. }
  2932. if(rootObj==null){
  2933. console.log('未找到该模型的根节点')
  2934. return;
  2935. }
  2936. var rowItems = await player.Native.ModelTree.getSubItems(rootObj.item)
  2937. for (var row = 0; row < rowItems.length; row++) {
  2938. if (rowItems[row].name.length < 2 || rowItems[row].name.substr(0, 1) != "R") continue;
  2939. var devItems = await player.Native.ModelTree.getSubItems(rowItems[row].item)
  2940. for (var i = 0; i < devItems.length; i++) {
  2941. if (devItems[i].name.length < 2 || devItems[i].name.substr(0, 2) != 'C_') continue
  2942. var tmp = devItems[i];// await player.Native.ModelTree.findItemByName(name,0,true,3);
  2943. //计算当前设备在世界坐标
  2944. var xyz = await player.Native.ModelTree.calcItemAabb(tmp.item)
  2945. var xyz2 = [(xyz.aabb.max[0] + xyz.aabb.min[0]) * 0.5, (xyz.aabb.max[1] + xyz.aabb.min[1]) * 0.5, (xyz.aabb.max[2] + xyz.aabb.min[2]) * 0.5];
  2946. // 创建设备编号标记
  2947. /*
  2948. var options = {
  2949. "text": devItems[i].name.replace("C_", "") + "#",
  2950. "visible": true,
  2951. "maxLod": 110,
  2952. "minLod": 0.1,
  2953. "textColor": parseInt("0xffffffff")
  2954. };
  2955. options.pos = [xyz2[0] - 1.5, xyz2[1] - 3, 0]
  2956. var markPtr = await player.Native.GisMarker.create(options);
  2957. player.Native.GisMarker.update(markPtr, options);
  2958. */
  2959. modelsMap[tmp.name] = {item: tmp.item, xyz: xyz2, rowno: rowItems[row].name.substr(1)}
  2960. //初始化设备状态颜色
  2961. ChangeModelAlarmState2(tmp.name);
  2962. //创建指示灯标记
  2963. /*
  2964. var alarmColorMarker = {
  2965. "text": "●",
  2966. "visible": true,
  2967. "maxLod": 110,
  2968. "minLod": 0.1,
  2969. "textFontSize": 14,
  2970. "textColor": parseInt("0xffffff00") //透明色
  2971. }
  2972. alarmColorMarker.pos = [xyz2[0] + 0.7, xyz2[1] - 3, 0]
  2973. var colormarkPtr = await player.Native.GisMarker.create(alarmColorMarker);
  2974. player.Native.GisMarker.update(colormarkPtr, alarmColorMarker);
  2975. modelsAlarmColorMap[tmp.name] = {itemPtr: colormarkPtr, options: alarmColorMarker}
  2976. */
  2977. }
  2978. }
  2979. //loadedcnt.innerText=totalcnt.innerText;
  2980. MODEL_LOADED = 1;
  2981. }
  2982. for (var i in ANIMATION_DATA) {
  2983. // 添加关键帧
  2984. player.Native.CameraAnimation.addKeyFrames([ANIMATION_DATA[i]]);
  2985. }
  2986. await player.Native.Model.setModelVisible(currentTargetType,true);
  2987. if (ALARM_DEVS.length > 0) {
  2988. for (var i = 0; i < ALARM_DEVS.length; i++) {
  2989. var s = ALARM_DEVS[i].split(">")
  2990. //ChangeModelColor(s[0],s[1] , s[2]);
  2991. ChangeModelAlarmState2(s[0], s[1]);
  2992. }
  2993. ALARM_DEVS = [];//清除
  2994. }
  2995. //获取数据
  2996. GetData();
  2997. //获取数据
  2998. GetAlarmData();
  2999. //获取在线设备列表
  3000. GetOnlineDev();
  3001. }
  3002. //6.监听远程过程调用加载完成消息
  3003. player.on("NativeLoad", async (Native) => {
  3004. playerNative =Native;
  3005. var devAllCount = 6 * 12 * 2 - 4 //设备总数
  3006. //var loadedcnt = document.getElementById("loadedcnt")
  3007. //var totalcnt = document.getElementById("totalcnt")
  3008. //totalcnt.innerText = devAllCount;
  3009. //loadedcnt.innerText="0";
  3010. loadFacModel(Native);
  3011. setTimeout(function(){
  3012. if (document.getElementById("loading") != null) document.getElementById("loading").remove(true) //加载完成,移除Loading
  3013. if (document.getElementById("loading_a1") != null) document.getElementById("loading_a1").remove(true)
  3014. },4000);
  3015. //调整视角,使其达到最佳初始效果
  3016. backMasterView();
  3017. //player.Native.Camera.moveToItem(lastPtr,1);
  3018. // // 选择Pickup工具
  3019. player.Native.Tools.setCurrentTool("system.Pickup");
  3020. //不显示提示框
  3021. player.Native.Settings.set("tips.enabled", "bool", false);
  3022. // //点选高亮显示
  3023. player.Native.Settings.set("pickUp.highlight", "bool", false);
  3024. //点选包围盒
  3025. player.Native.Settings.set("show.select.box", "bool", false);
  3026. player.Native.Settings.set("skybox.select", "string", "blue");
  3027. //点选背景虚化
  3028. player.Native.Settings.set("color.pickup.bkAlpha", "float", 0.8);
  3029. // 选中展示节点
  3030. // sam0023 = await player.Native.ModelTree.findItemByName("CYLINDER 3 of EQUIPMENT /C1101", 0, true, 3);
  3031. player.Native.Settings.set('ambientIndenty', 'float', 0.39);//初始化环境光补偿
  3032. player.Native.Settings.set('diffuseIntensity', 'float', 0.8);//初始化光线强度
  3033. player.Native.Settings.set('specularIntensity', 'float', 0.64);//初始化高光强度
  3034. player.Native.Settings.set('searchLightIntensity', 'float', 0.5);//初始化探照灯强度
  3035. // 点击事件一般仅用于浏览工具,在点选工具下无效
  3036. Native.Tools.setCurrentTool("system.Browse");
  3037. Native.ModelTree.EventBrowseLClick.connect((event) => {
  3038. if(currentTargetType=="FAC"){
  3039. var inTxt = "";
  3040. if(inPoints[event.object.name]!=null){
  3041. //进入楼层内部
  3042. inTxt = txt;
  3043. }else {
  3044. for (var txt in inPoints) {
  3045. var item = inPoints[txt];
  3046. if(event.pos[1]>= item["x1"] && event.pos[2]<= item["y1"] &&event.pos[1]<= item["x2"] && event.pos[2]>= item["y2"]){
  3047. inTxt = txt;
  3048. break;
  3049. }
  3050. }
  3051. }
  3052. if(inTxt!=""){
  3053. currentTargetType=inTxt;
  3054. switch(inTxt){
  3055. case "IN02":
  3056. loadIn02Model(Native);
  3057. break;
  3058. case "IN03":
  3059. loadIn03Model(Native);
  3060. break;
  3061. case "IN04":
  3062. loadIn04Model(Native);
  3063. break;
  3064. case "IN05":
  3065. loadIn05Model(Native);
  3066. break;
  3067. default:
  3068. break;
  3069. }
  3070. backMasterView();
  3071. }
  3072. return;
  3073. }
  3074. updateInfo("LClick", event)
  3075. });
  3076. Native.ModelTree.EventBrowseRClick.connect((event) => {
  3077. updateInfo("RClick", event)
  3078. });
  3079. })
  3080. async function updateSettings(object, type) {
  3081. console.log(object)
  3082. if (object.id) {
  3083. if (type == "bool") {
  3084. player.Native.Settings.set(object.id, type, object.checked);
  3085. } else if (type == "red") {
  3086. //参数前3个为RGB值,最后一个为透明度?,有点问题,好像不是正常的RGB?
  3087. const xx = document.getElementById("color.value");
  3088. player.Native.Settings.set(object.id, "string", xx.value);
  3089. } else {
  3090. player.Native.Settings.set(object.id, type, object.value);
  3091. }
  3092. // 更新span值
  3093. if (type == "float") {
  3094. var showValueStr = object.id + "Value";
  3095. if (document.getElementById(showValueStr))
  3096. document.getElementById(showValueStr).innerText = object.value;
  3097. }
  3098. }
  3099. }
  3100. //修改模型
  3101. async function updateModel(object) {
  3102. // sam0023 = await player.Native.ModelTree.getSelectedItem();
  3103. sam0023 = await player.Native.ModelTree.getItemBySelfId(2433);
  3104. console.log("0023", sam0023);
  3105. if (object.id === "selectItem") {
  3106. // if (object.checked) {
  3107. player.Native.ModelTree.setSelectItem(sam0023.item);
  3108. // } else {
  3109. // player.Native.ModelTree.setSelectItem(0);
  3110. // }
  3111. } else if (object.id == "itemColor") {
  3112. console.log("瓦特?", JSON.stringify(sam0023))
  3113. // if (object.checked) {
  3114. const xx = document.getElementById("color.value");
  3115. player.Native.ModelTree.setItemColor(sam0023.item, parseInt(xx.value));
  3116. // } else {
  3117. // player.Native.ModelTree.restoreItemColor(sam0023.item);
  3118. // }
  3119. } else if (object.id == "itemColorClean") {
  3120. player.Native.ModelTree.restoreItemColor(sam0023.item);
  3121. } else if (object.id == "itemVisible") {
  3122. player.Native.ModelTree.setItemVisible(sam0023.item, object.checked);
  3123. }
  3124. }
  3125. var MarkerMap = {};//标记记录
  3126. var MarkerOptMap = {};
  3127. //设置设置名称或者模型id的颜色
  3128. async function ChangeModelColor(name, color, hinttxt) {
  3129. var iteminfo = modelsMap[name]
  3130. if (iteminfo == null) return
  3131. //var tmp = await player.Native.ModelTree.findItemByName(name,0,true,3);
  3132. if (color == null || color == "") {
  3133. if (OFFLINE_DEVS[name] == 1) return; //离线设备无需处理
  3134. //还原
  3135. await player.Native.ModelTree.restoreItemColor(iteminfo.item)
  3136. //隐藏已有标签
  3137. await player.Native.GisMarker.update(MarkerMap[name], {"visible": false});
  3138. MarkerMap[name] = null;
  3139. } else {
  3140. await player.Native.ModelTree.setItemColor(iteminfo.item, parseInt("0x" + color + "ff"), true)
  3141. if (hinttxt != null && hinttxt != "") {
  3142. var srcPosition = iteminfo.xyz // await player.Native.NodeProxy.getNodePosition(temp.item);
  3143. //console.log("posio",srcPosition)
  3144. // 创建标记
  3145. var options = {};
  3146. if (MarkerOptMap[name] == null) {
  3147. var imgid = await player.Native.GisMarker.loadImage("rgba:255,0,0,255");
  3148. options = {
  3149. "text": hinttxt,
  3150. "visible": true,
  3151. "maxLod": 130,
  3152. "minLod": 0.1,
  3153. "textColor": parseInt("0xffffffff")
  3154. };
  3155. options.pos = [srcPosition[0] - 1, srcPosition[1] - 2, srcPosition[2]];
  3156. //options.parentNode=tmp.item;
  3157. options.imgId = imgid
  3158. options.imgSize = [-1, -1];
  3159. MarkerOptMap[name] = options;
  3160. } else {
  3161. options = MarkerOptMap[name]
  3162. options.text = hinttxt;
  3163. }
  3164. if (MarkerMap[name] != null) {
  3165. await player.Native.GisMarker.update(MarkerMap[name], options);
  3166. } else {
  3167. var markPtr = await player.Native.GisMarker.create(options);
  3168. await player.Native.GisMarker.update(markPtr, options);
  3169. MarkerMap[name] = markPtr;
  3170. }
  3171. } else {
  3172. await player.Native.GisMarker.update(MarkerMap[name], {"visible": false});
  3173. }
  3174. }
  3175. }
  3176. //更改指示灯状态。需求变更,已废弃
  3177. async function ChangeModelAlarmState(name, color) {
  3178. var iteminfo = modelsAlarmColorMap[name]
  3179. if (iteminfo == null) return
  3180. var colormarkPtr = iteminfo.itemPtr;
  3181. var alarmColorMarker = iteminfo.options;
  3182. if (color == null || color == "") {
  3183. if (OFFLINE_DEVS[name] == 1) return; //离线设备无需处理
  3184. //还原为透明
  3185. alarmColorMarker["textColor"] = parseInt("0xffffff00");
  3186. player.Native.GisMarker.update(colormarkPtr, alarmColorMarker);
  3187. return;
  3188. }
  3189. alarmColorMarker["textColor"] = parseInt("0x" + color + "ff");
  3190. player.Native.GisMarker.update(colormarkPtr, alarmColorMarker);
  3191. }
  3192. //更改指示灯状态.版本2:更改设备标号牌旁边的指示灯模型
  3193. //绿灯为G 红灯为R 黄灯为Y
  3194. //如果没有告警和停机,显示绿灯另外2个隐藏
  3195. //CCD 叫料 停经片停机显示黄灯另外2个隐藏
  3196. //有故障和掉线二字的显示红灯,其他都显示黄灯
  3197. async function ChangeModelAlarmState2(name, color) {
  3198. color = color==null ? "" : color.toUpperCase();
  3199. var iteminfo = modelsMap[name]
  3200. if (iteminfo == null) return
  3201. var t = (!color ||color=="00FF00"||color=="FFFFFF")?"g":(color=="FF0000"?"r":"y");
  3202. var y_itemid = await player.Native.ModelTree.findItemByName(name+"Y",iteminfo.item,true,1)
  3203. var g_itemid = await player.Native.ModelTree.findItemByName(name+"G",iteminfo.item,true,1)
  3204. var r_itemid = await player.Native.ModelTree.findItemByName(name+"R",iteminfo.item,true,1)
  3205. player.Native.ModelTree.setItemVisible([y_itemid.item,g_itemid.item,r_itemid.item],false)
  3206. if(t=='g'){
  3207. player.Native.ModelTree.setItemVisible([g_itemid.item],true);
  3208. return;
  3209. }
  3210. if(t=='r'){
  3211. player.Native.ModelTree.setItemVisible([r_itemid.item],true);
  3212. return;
  3213. }
  3214. if(t=='y'){
  3215. player.Native.ModelTree.setItemVisible([y_itemid.item],true);
  3216. return;
  3217. }
  3218. }
  3219. var LastClickObj = null;
  3220. var openState = false;
  3221. var dbClickTimer = null;
  3222. async function updateInfo(name, event) {
  3223. if (AutoPlayer) $("#autoplayer_btn").trigger('click') //停止 自动漫游
  3224. if (name != "LClick") {
  3225. CloseWin()
  3226. HideInfo();
  3227. return
  3228. }
  3229. //console.log(event)
  3230. var ty = event.object.nodePtr != null ? 'NODE' : 'ITEM';
  3231. var modelsId = ty == 'NODE' ? event.object.nodePtr : event.object.item;
  3232. if (modelsId == null || modelsId == "") {
  3233. CloseWin()
  3234. HideInfo();
  3235. return
  3236. }
  3237. var devName = null;
  3238. var cnt = 0;
  3239. var p = null;
  3240. while (devName == null) {
  3241. if (cnt > 5) break //最多查找5层
  3242. if (ty == 'NODE') p = await player.Native.NodeProxy.getNodeParent(modelsId) //节点类型的node
  3243. else p = await player.Native.ModelTree.getItemInfo(modelsId)
  3244. if (p.name != null && p.name.substr(0, 2) == "C_") {
  3245. devName = p.name
  3246. break
  3247. }
  3248. modelsId = ty == 'NODE' ? p.nodePtr : p.parentItem;
  3249. cnt++
  3250. }
  3251. if (devName == null) {
  3252. CloseWin()
  3253. HideInfo();
  3254. return
  3255. }
  3256. console.log(name, devName)
  3257. if (devName == LastClickObj) {
  3258. if (dbClickTimer != null) clearTimeout(dbClickTimer)
  3259. HideInfo();
  3260. //双击
  3261. if (openState) return //窗口已经打开
  3262. OpenWin(devName)
  3263. return
  3264. }
  3265. CloseWin();
  3266. HideInfo();
  3267. LastClickObj = devName
  3268. dbClickTimer = setTimeout(function (n) {
  3269. ShowInfo(n)
  3270. LastClickObj = null
  3271. }, 200, devName)
  3272. }
  3273. function search() {
  3274. var v = $.trim($("#search input:eq(0)").val());
  3275. var s2 = $("#search_result")
  3276. if (v == "") {
  3277. s2.html("").hide();
  3278. return
  3279. }
  3280. var lst = [];
  3281. for (var k in modelsMap) {
  3282. if (k.indexOf(v) > -1) {
  3283. lst.push('<div class="item" devno="' + k + '">' + k.replace("C_", "") + '</div>')
  3284. }
  3285. }
  3286. s2.html(lst.join("")).show();
  3287. if (lst.length == 0) {
  3288. s2.html('未搜索到任何设备')
  3289. return
  3290. }
  3291. s2.find(".item").off().on('click', function () {
  3292. ShowInfo($(this).attr('devno'))
  3293. })
  3294. }
  3295. //打开单设备窗口
  3296. function OpenWin(name) {
  3297. if (LastClickObj != null && name != LastClickObj) return;
  3298. openState = true
  3299. name = name.replace("C_", "")
  3300. $("#newwin .content .btn").removeClass("btn_active");
  3301. $("#newwin .content .btn:eq(0)").addClass("btn_active");
  3302. $("#newwin .content .btn").off().on("click", function () {
  3303. if ($(this).hasClass("btn_active")) return
  3304. $("#newwin .content .btn").removeClass("btn_active");
  3305. $(this).addClass("btn_active");
  3306. LoadDevDetail(name, window.Device_Data, $(this).index())
  3307. })
  3308. $.getJSON(SERVER_URL + "/query/C_" + name + "?week=1", {}, function (res) {
  3309. if (res.code == 500) {
  3310. NoneDevice(name)
  3311. return
  3312. }
  3313. $("#newwin .title .text:eq(0)").html(name)
  3314. $("#newwin").show();
  3315. window.Device_Data = res.data
  3316. LoadDevDetail(name, window.Device_Data, "0")
  3317. })
  3318. }
  3319. //设备还未接入
  3320. function NoneDevice(name) {
  3321. $("#nodevice .title .text").html(name + "#经编机-基本信息")
  3322. $("#nodevice").show().find(".content").html('该设备还未接入数据平台');
  3323. }
  3324. //关闭窗口
  3325. function CloseWin() {
  3326. LastClickObj = null
  3327. openState = false
  3328. window.Device_Data = null;
  3329. $("#newwin,#nodevice").hide();
  3330. }
  3331. //显示设备基本信息
  3332. async function ShowInfo(name) {
  3333. var se = modelsMap[name];// await player.Native.ModelTree.findItemByName(name,0,true,3);
  3334. //选中
  3335. player.Native.ModelTree.setSelectItem(se.item);
  3336. var calcInfo = await PlayerUtils.call(player.Native.ModelTree.calcItemAabb, se.item);
  3337. //调整目标对象的视角和角度
  3338. if(se.rowno%2==0){
  3339. // 面索引,0表示不定位视角,可设置一个面,也可设置两个或三个面进行组合
  3340. // Top = 1
  3341. // Bottom = 2
  3342. // Front = 4
  3343. // Back = 8
  3344. // Left = 16
  3345. // Right = 32,
  3346. //移动到目标并放大
  3347. player.Native.Camera.moveToAabbWithDistance([calcInfo.localAabb.min, [calcInfo.localAabb.max[0],calcInfo.localAabb.max[1],calcInfo.localAabb.max[2]-1]], 0.2, 9, 0.5);
  3348. }else{
  3349. //backMasterView();
  3350. player.Native.Camera.moveToAabbWithDistance([calcInfo.localAabb.min, [calcInfo.localAabb.max[0],calcInfo.localAabb.max[1],calcInfo.localAabb.max[2]-1]], 0.2, 5, 0.5);
  3351. }
  3352. //player.Native.Camera.moveToAabbWithDistance([calcInfo.localAabb.min, calcInfo.localAabb.max], 0.2, 21, 4);
  3353. name = name.replace("C_", "")
  3354. $.getJSON(SERVER_URL + "/query/C_" + name, {}, function (res) {
  3355. if (res.code == 500) {
  3356. NoneDevice(name)
  3357. return
  3358. }
  3359. $("#showinfo .title .text").html(name + "#经编机-基本信息")
  3360. $("#showinfo").show();
  3361. LoadDevBaseData(res.data.data, "C_" + name)
  3362. })
  3363. }
  3364. //隐藏设备基本信息
  3365. function HideInfo() {
  3366. $("#showinfo,#nodevice").hide();
  3367. }
  3368. function LoadDevBaseData(data, devno) {
  3369. var t = $("#showinfo .content");
  3370. //盘头剩余时间
  3371. var tb = t.find("table:eq(0)>tbody>tr:eq(2)");
  3372. tb.find("td:eq(0)").html(data.Capacity_data_5);
  3373. tb.find("td:eq(1)").html(data.Capacity_data_6);
  3374. tb.find("td:eq(2)").html(data.Capacity_data_7);
  3375. tb.find("td:eq(3)").html(data.Capacity_data_8);
  3376. tb.find("td:eq(4)").html(data.Capacity_data_9);
  3377. //盘头剩余周长
  3378. tb = t.find("table:eq(1)>tbody>tr:eq(2)");
  3379. tb.find("td:eq(0)").html(data.Capacity_data_10);
  3380. tb.find("td:eq(1)").html(data.Capacity_data_11);
  3381. tb.find("td:eq(2)").html(data.Capacity_data_12);
  3382. tb.find("td:eq(3)").html(data.Capacity_data_13);
  3383. tb.find("td:eq(4)").html(data.Capacity_data_14);
  3384. //盘头剩余圈数
  3385. tb = t.find("table:eq(2)>tbody>tr:eq(2)");
  3386. tb.find("td:eq(0)").html(data.Capacity_data_15);
  3387. tb.find("td:eq(1)").html(data.Capacity_data_16);
  3388. tb.find("td:eq(2)").html(data.Capacity_data_17);
  3389. tb.find("td:eq(3)").html(data.Capacity_data_18);
  3390. tb.find("td:eq(4)").html(data.Capacity_data_19);
  3391. //盘头剩余比例
  3392. tb = t.find("table:eq(3)>tbody>tr:eq(2)");
  3393. var paninfo = DataFill.Pan[devno]
  3394. for (var i = 0; i < 5; i++) {
  3395. var v = paninfo != null ? paninfo[i] : "-";
  3396. tb.find("td:eq(" + i + ")").html(v).css("color", getPantaoColor(v));
  3397. }
  3398. }
  3399. function getPantaoColor(v) {
  3400. if (v == null || v == "-") return "";
  3401. v = v * 1;
  3402. if (v < 20) return "#" + DEV_ALAR_COLOR;
  3403. else if (v < 50) return "#" + DEV_HINT_COLOR;
  3404. return "";
  3405. }
  3406. function LoadDevDetail(name, data, typecode) {
  3407. if (typecode == null) typecode = "0";
  3408. $("#newwin .dataContent>div").hide()
  3409. var t = $("#newwin .dataContent>div:eq(" + typecode + ")").show();
  3410. if (typecode == "0") {
  3411. //告警周趋势
  3412. t = t.find(".dev_alarm_echarts");
  3413. var alarmWeek = [];
  3414. var times = [];
  3415. var v_series = [];
  3416. for (var i = 0; i < data.alarms.length; i++) {
  3417. var v = data.alarms[i]['value'];
  3418. var tv = data.alarms[i]['time'].split("-")
  3419. times.push(tv[1] + "-" + tv[2])
  3420. if (v != null) alarmWeek.push(v)
  3421. }
  3422. if (alarmWeek.length == 0) {
  3423. t.html('未获取到告警趋势数据')
  3424. } else {
  3425. v_series.push({
  3426. name: "",
  3427. type: 'line',
  3428. smooth: true,
  3429. //symbol: 'none',
  3430. data: alarmWeek,
  3431. itemStyle: {
  3432. normal: {
  3433. color: '#F0F275', // 这里设置折线的颜色
  3434. lineStyle: {
  3435. color: '#F0F27560' // 这里同时设置线头的颜色
  3436. }
  3437. }
  3438. },
  3439. });
  3440. var opt = {
  3441. title: {
  3442. show: false, //不显示标题
  3443. text: '',
  3444. textStyle: {
  3445. color: "rgb(89, 151, 229)",
  3446. fontWeight: "bold"
  3447. },
  3448. top: "0px",
  3449. left: "30px"
  3450. },
  3451. tooltip: {
  3452. trigger: 'axis',
  3453. formatter: function (params) {
  3454. let xv='';
  3455. let result = '';
  3456. params.forEach(function (item) {
  3457. xv=`${item.name}<br/>`;
  3458. result += ` ${item.marker} ${item.value}(次)<br/>`;
  3459. });
  3460. return xv+result;
  3461. }
  3462. },
  3463. legend: {
  3464. show: false, //不显示图例
  3465. inactiveColor: "#04417A",
  3466. data: "",
  3467. textStyle: {color: "#fff"},
  3468. top: "0px"
  3469. },
  3470. grid: {
  3471. left: '1%',
  3472. right: '1%',
  3473. bottom: '2%',
  3474. top: '5%',
  3475. containLabel: true
  3476. },
  3477. xAxis: {
  3478. type: 'category',
  3479. boundaryGap: false,
  3480. axisLabel: {
  3481. rotate: 45,
  3482. color: "#fff"
  3483. },
  3484. data: times
  3485. },
  3486. yAxis: {
  3487. type: 'value',
  3488. nameTextStyle: {
  3489. color: "#fff"
  3490. },
  3491. axisLabel: {
  3492. color: "rgb(203,215,235)"
  3493. },
  3494. splitLine: {
  3495. lineStyle: {
  3496. color: "#7DA7CD",
  3497. type: "dashed",
  3498. width: 1
  3499. }
  3500. }
  3501. },
  3502. series: v_series
  3503. };
  3504. var echartsEle = echarts.init(t[0]);
  3505. echartsEle.setOption(opt);
  3506. }
  3507. //当前告警数据加载
  3508. if (DataFill.AlarmData == null || DataFill.AlarmData.length == 0) {
  3509. $(".newwin .dataContent .no_alarm").show();
  3510. $(".newwin .dataContent .has_alarm").hide();
  3511. return
  3512. }
  3513. var t1 = [];
  3514. for (var i = 0; i < DataFill.AlarmData.length; i++) {
  3515. if (DataFill.AlarmData[i].code == 'C_' + name) {
  3516. t1.push(DataFill.AlarmType[DataFill.AlarmData[i].type])
  3517. }
  3518. }
  3519. if (t1.length == 0) {
  3520. $(".newwin .dataContent .no_alarm").show();
  3521. $(".newwin .dataContent .has_alarm").hide();
  3522. return
  3523. }
  3524. $(".newwin .dataContent .no_alarm").hide();
  3525. var a1 = $(".newwin .dataContent .has_alarm").show().html("");
  3526. for (var i = 0; i < t1.length; i++) {
  3527. a1.append('<span class="alarm_span"><img src="image/alarm_icon.png" style="vertical-align: middle;"><b>' + t1[i] + '</b></span>')
  3528. }
  3529. } else {
  3530. t.find(".value").each(function () {
  3531. var th = $(this), attrname = th.attr("attr"), unit = th.attr("unit"), v = data.data[attrname];
  3532. if (v == "true") v = "开";
  3533. if (v == "false") v = "关";
  3534. if (unit != "") th.html(v + "(" + th.attr("unit") + ")")
  3535. else th.html(v)
  3536. })
  3537. }
  3538. }
  3539. </script>