| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265 |
- <!doctype html>
- <html lang="en">
- <head>
- <meta charset="utf-8">
- <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
- <link rel="shortcut icon" href="/img/logo.png" />
- <link rel="bookmark" href="/img/logo.png" />
- <link href="/Plugins/animate/animate.min.css" rel="stylesheet" />
- <link rel="stylesheet" href="../DashBoard.css?v3" />
- <script src="/Plugins/jquery-3.4.1/jquery-3.4.1.min.js"></script>
- <script src="/Plugins/animate/xanimate.js"></script>
- <script src="/Plugins/xrequest/xrequest.min.js"></script>
- <title>东科软件</title>
- </head>
- <body style="background-color:black;">
- <div class="box_1920_1080">
- <div class="box_title" style="display:flex;flex-direction:row;">
- <div style="width:30%;text-align:left;"></div>
- <div style="width:40%;text-align:center;font-size:38px;font-weight:700">设备运行状态看板</div>
- <div style="width:30%;text-align:right;"><span class="box_title_loading" style="font-size:32px;display:none;" id="报表加载"></span></div>
- </div>
- <div class="box_body" style="display: flex; flex-direction: column;">
- <!--测漏气-->
- <div style="width:1840px;height:960px;display:flex;flex-direction:row;">
- <div style="width: 920px; height: 960px; padding-right: 20px; display: flex; flex-direction: row; ">
- <table cellspacing="0" cellpadding="0" border="0" style="width:100%;height:100%;">
- <!--<tr class="tr_title_warning">
- <td colspan="9" style="color:white;">测漏气产量合格率</td>
- </tr>-->
- <tr class="tr_title_warning">
- <td>设备名称</td>
- <td>日生产量</td>
- <!--<td>日合格数</td>
- <td>日合格率</td>-->
- <td>工作时间</td>
- <td>等待时间</td>
- <td>故障时间</td>
- </tr>
- <tr class="tr_bg_light_warning" style="height:30px;" id="tr1">
- <td style="font-size: 18px; width: 11%">A线-智能测漏机</td>
- <td style="font-size: 18px; width: 11%" id="pd1">--</td>
- <!--<td style="font-size: 18px; width: 11%" id="pg1">--</td>
- <td style="font-size: 18px; width: 11%" id="gp1">--</td>-->
- <td style="font-size: 18px; width: 11%" id="yx1">--</td>
- <td style="font-size: 18px; width: 11%" id="dd1">--</td>
- <td style="font-size: 18px; width: 11%" id="gz1">--</td>
- </tr>
- <tr class="tr_bg_light_warning" style="height:30px;" id="tr2">
- <td style="font-size: 18px; width: 11%">B线-智能测漏机</td>
- <td style="font-size: 18px; width: 11%" id="pd2">--</td>
- <!--<td style="font-size: 18px; width: 11%" id="pg2">--</td>
- <td style="font-size: 18px; width: 11%" id="gp2">--</td>-->
- <td style="font-size: 18px; width: 11%" id="yx2">--</td>
- <td style="font-size: 18px; width: 11%" id="dd2">--</td>
- <td style="font-size: 18px; width: 11%" id="gz2">--</td>
- </tr>
- <tr class="tr_bg_light_warning" style="height:30px;" id="tr3">
- <td style="font-size: 18px; width: 11%">C线-连体测漏机</td>
- <td style="font-size: 18px; width: 11%" id="pd3">--</td>
- <!--<td style="font-size: 18px; width: 11%" id="pg3">--</td>
- <td style="font-size: 18px; width: 11%" id="gp3">--</td>-->
- <td style="font-size: 18px; width: 11%" id="yx3">--</td>
- <td style="font-size: 18px; width: 11%" id="dd3">--</td>
- <td style="font-size: 18px; width: 11%" id="gz3">--</td>
- </tr>
- <tr class="tr_bg_light_warning" style="height:30px;" id="tr4">
- <td style="font-size: 18px; width: 11%">D线-连体测漏机</td>
- <td style="font-size: 18px; width: 11%" id="pd4">--</td>
- <!--<td style="font-size: 18px; width: 11%" id="pg4">--</td>
- <td style="font-size: 18px; width: 11%" id="gp4">--</td>-->
- <td style="font-size: 18px; width: 11%" id="yx4">--</td>
- <td style="font-size: 18px; width: 11%" id="dd4">--</td>
- <td style="font-size: 18px; width: 11%" id="gz4">--</td>
- </tr>
- <tr class="tr_bg_light_warning" style="height:30px;" id="tr5">
- <td style="font-size: 18px; width: 11%">E线-连体测漏机</td>
- <td style="font-size: 18px; width: 11%" id="pd5">--</td>
- <!--<td style="font-size: 18px; width: 11%" id="pg5">--</td>
- <td style="font-size: 18px; width: 11%" id="gp5">--</td>-->
- <td style="font-size: 18px; width: 11%" id="yx5">--</td>
- <td style="font-size: 18px; width: 11%" id="dd5">--</td>
- <td style="font-size: 18px; width: 11%" id="gz5">--</td>
- </tr>
- <tr class="tr_bg_light_warning" style="height:30px;" id="tr6">
- <td style="font-size: 18px; width: 11%">F线-连体测漏机</td>
- <td style="font-size: 18px; width: 11%" id="pd6">--</td>
- <!--<td style="font-size: 18px; width: 11%" id="pg6">--</td>
- <td style="font-size: 18px; width: 11%" id="gp6">--</td>-->
- <td style="font-size: 18px; width: 11%" id="yx6">--</td>
- <td style="font-size: 18px; width: 11%" id="dd6">--</td>
- <td style="font-size: 18px; width: 11%" id="gz6">--</td>
- </tr>
- <tr class="tr_bg_light_warning" style="height:30px;" id="tr7">
- <td style="font-size: 18px; width: 11%">G线-连体测漏机</td>
- <td style="font-size: 18px; width: 11%" id="pd7">--</td>
- <!--<td style="font-size: 18px; width: 11%" id="pg7">--</td>
- <td style="font-size: 18px; width: 11%" id="gp7">--</td>-->
- <td style="font-size: 18px; width: 11%" id="yx7">--</td>
- <td style="font-size: 18px; width: 11%" id="dd7">--</td>
- <td style="font-size: 18px; width: 11%" id="gz7">--</td>
- </tr>
- <tr class="tr_bg_light_warning" style="height:30px;" id="tr8">
- <td style="font-size: 18px; width: 11%">H线-智能测漏机</td>
- <td style="font-size: 18px; width: 11%" id="pd8">--</td>
- <!--<td style="font-size: 18px; width: 11%" id="pg8">--</td>
- <td style="font-size: 18px; width: 11%" id="gp8">--</td>-->
- <td style="font-size: 18px; width: 11%" id="yx8">--</td>
- <td style="font-size: 18px; width: 11%" id="dd8">--</td>
- <td style="font-size: 18px; width: 11%" id="gz8">--</td>
- </tr>
- <tr class="tr_bg_light_warning" style="height:30px;" id="str1">
- <td style="font-size: 18px; width: 11%">A线-倒水机</td>
- <td style="font-size: 18px; width: 11%" id="spd1">--</td>
- <td style="font-size: 18px; width: 11%" id="syx1">--</td>
- <td style="font-size: 18px; width: 11%" id="sdd1">--</td>
- <td style="font-size: 18px; width: 11%" id="sgz1">--</td>
- </tr>
- <tr class="tr_bg_light_warning" style="height:30px;" id="str2">
- <td style="font-size: 18px; width: 11%">B线-倒水机</td>
- <td style="font-size: 18px; width: 11%" id="spd2">--</td>
- <td style="font-size: 18px; width: 11%" id="syx2">--</td>
- <td style="font-size: 18px; width: 11%" id="sdd2">--</td>
- <td style="font-size: 18px; width: 11%" id="sgz2">--</td>
- </tr>
- <tr class="tr_bg_light_warning" style="height:30px;" id="str3">
- <td style="font-size: 18px; width: 11%">C线-倒水机</td>
- <td style="font-size: 18px; width: 11%" id="spd3">--</td>
- <td style="font-size: 18px; width: 11%" id="syx3">--</td>
- <td style="font-size: 18px; width: 11%" id="sdd3">--</td>
- <td style="font-size: 18px; width: 11%" id="sgz3">--</td>
- </tr>
- <tr class="tr_bg_light_warning" style="height:30px;" id="str4">
- <td style="font-size: 18px; width: 11%">D线-倒水机</td>
- <td style="font-size: 18px; width: 11%" id="spd4">--</td>
- <td style="font-size: 18px; width: 11%" id="syx4">--</td>
- <td style="font-size: 18px; width: 11%" id="sdd4">--</td>
- <td style="font-size: 18px; width: 11%" id="sgz4">--</td>
- </tr>
- </table>
- </div>
- <div style="width: 920px; height: 960px; padding-right: 20px; display: flex; flex-direction: column; ">
- <div style="width: 100%; height: 320px; padding-right: 20px; display: flex; flex-direction: row; ">
- <div style="width: 25%; height: 320px;">
- <div style="color: white; font-size: 19px; padding-top: 10px; font-weight: 600; text-align: center">A线-智能测漏机</div>
- <canvas id="canvasDefectA1" style="-moz-user-select: none; -webkit-user-select: none; -ms-user-select: none; height: 218px; width: 100%"></canvas>
- <div id="currentA1" style="width: 30px; height: 30px; margin: 10px 0 0 96px; border-radius: 50%; "></div>
- </div>
- <div style="width: 25%; height: 320px;">
- <div style="color: white; font-size: 19px; padding-top: 10px; font-weight: 600; text-align: center ">B线-智能测漏机</div>
- <canvas id="canvasDefectA2" style="-moz-user-select: none; -webkit-user-select: none; -ms-user-select: none; height: 218px; width: 100% "></canvas>
- <div id="currentA2" style="width: 30px; height: 30px; margin: 10px 0 0 96px; border-radius: 50%; "></div>
- </div>
- <div style="width: 25%; height: 320px;">
- <div style="color: white; font-size: 19px; padding-top: 10px; font-weight: 600; text-align: center ">C线-连体测漏机</div>
- <canvas id="canvasDefectA3" style="-moz-user-select: none; -webkit-user-select: none; -ms-user-select: none; height: 218px; width: 100% "></canvas>
- <div id="currentA3" style="width: 30px; height: 30px; margin: 10px 0 0 96px; border-radius: 50%; "></div>
- </div>
- <div style="width: 25%; height: 320px;">
- <div style="color: white; font-size: 19px; padding-top: 10px; font-weight: 600; text-align: center ">D线-连体测漏机</div>
- <canvas id="canvasDefectA4" style="-moz-user-select: none; -webkit-user-select: none; -ms-user-select: none; height: 218px; width: 100% "></canvas>
- <div id="currentA4" style="width: 30px; height: 30px; margin: 10px 0 0 96px; border-radius: 50%; "></div>
- </div>
- </div>
- <div style="width: 100%; height: 320px; padding-right: 20px; display: flex; flex-direction: row; ">
- <div style="width: 25%; height: 320px;">
- <div style="color: white; font-size: 19px; padding-top: 20px; font-weight: 600; text-align: center ">E线-连体测漏机</div>
- <canvas id="canvasDefectA5" style="-moz-user-select: none; -webkit-user-select: none; -ms-user-select: none; height: 218px; width: 100% "></canvas>
- <div id="currentA5" style="width: 30px; height: 30px; margin: 10px 0 0 96px; border-radius: 50%; "></div>
- </div>
- <div style="width: 25%; height: 320px;">
- <div style="color: white; font-size: 19px; padding-top: 20px; font-weight: 600; text-align: center ">F线-连体测漏机</div>
- <canvas id="canvasDefectA6" style="-moz-user-select: none; -webkit-user-select: none; -ms-user-select: none; height: 218px; width: 100% "></canvas>
- <div id="currentA6" style="width: 30px; height: 30px; margin: 10px 0 0 96px; border-radius: 50%; "></div>
- </div>
- <div style="width: 25%; height: 320px;">
- <div style="color: white; font-size: 19px; padding-top: 20px; font-weight: 600; text-align: center ">G线-连体测漏机</div>
- <canvas id="canvasDefectA7" style="-moz-user-select: none; -webkit-user-select: none; -ms-user-select: none; height: 218px; width: 100% "></canvas>
- <div id="currentA7" style="width: 30px; height: 30px; margin: 10px 0 0 96px; border-radius: 50%; "></div>
- </div>
- <div style="width: 25%; height: 320px;">
- <div style="color: white; font-size: 19px; padding-top: 20px; font-weight: 600; text-align: center ">H线-智能测漏机</div>
- <canvas id="canvasDefectA8" style="-moz-user-select: none; -webkit-user-select: none; -ms-user-select: none; height: 218px; width: 100% "></canvas>
- <div id="currentA8" style="width: 30px; height: 30px; margin: 10px 0 0 96px; border-radius: 50%; "></div>
- </div>
- </div>
- <div style="width: 100%; height: 320px; padding-right: 20px; display: flex; flex-direction: row; ">
- <div style="width: 25%; height: 320px;">
- <div style="color: white; font-size: 19px; padding-top: 30px; font-weight: 600; text-align: center ">A线-倒水机</div>
- <canvas id="canvasDefectA9" style="-moz-user-select: none; -webkit-user-select: none; -ms-user-select: none; height: 218px; width: 100% "></canvas>
- <div id="currentA9" style="width: 30px; height: 30px; margin: 10px 0 0 96px; border-radius: 50%; "></div>
- </div>
- <div style="width: 25%; height: 320px;">
- <div style="color: white; font-size: 19px; padding-top: 30px; font-weight: 600; text-align: center ">B线-倒水机</div>
- <canvas id="canvasDefectA10" style="-moz-user-select: none; -webkit-user-select: none; -ms-user-select: none; height: 218px; width: 100% "></canvas>
- <div id="currentA10" style="width: 30px; height: 30px; margin: 10px 0 0 96px; border-radius: 50%; "></div>
- </div>
- <div style="width: 25%; height: 320px;">
- <div style="color: white; font-size: 19px; padding-top: 30px; font-weight: 600; text-align: center ">C线-倒水机</div>
- <canvas id="canvasDefectA11" style="-moz-user-select: none; -webkit-user-select: none; -ms-user-select: none; height: 218px; width: 100% "></canvas>
- <div id="currentA11" style="width: 30px; height: 30px; margin: 10px 0 0 96px; border-radius: 50%; "></div>
- </div>
- <div style="width: 25%; height: 320px;">
- <div style="color: white; font-size: 19px; padding-top: 30px; font-weight: 600; text-align: center ">D线-倒水机</div>
- <canvas id="canvasDefectA12" style="-moz-user-select: none; -webkit-user-select: none; -ms-user-select: none; height: 218px; width: 100% "></canvas>
- <div id="currentA12" style="width: 30px; height: 30px; margin: 10px 0 0 96px; border-radius: 50%; "></div>
- </div>
- </div>
- </div>
- </div>
- <!--试水-->
- <!--<div style="width: 1840px; height: 480px; display: flex; flex-direction: row;">
- <div style="width: 920px; height: 480px; padding-right: 20px; display: flex; flex-direction: row; ">
- <table cellspacing="0" cellpadding="0" border="0" style="width:100%;">
- <tr class="tr_title_warning">
- <td colspan="9" style="color:white;">试水产量合格率</td>
- </tr>
- <tr class="tr_title_warning">
- <td>试水线号</td>
- <td>日生产量</td>
- <td>日合格数</td>
- <td>日合格率</td>
- </tr>
- <tr class="tr_bg_light_warning" style="height:30px;">
- <td style="font-size: 18px; width: 11%">1</td>
- <td style="font-size: 18px; width: 11%">--</td>
- <td style="font-size: 18px; width: 11%">--</td>
- <td style="font-size: 18px; width: 11%">--</td>
- </tr>
- <tr class="tr_bg_light_warning" style="height:30px;">
- <td style="font-size: 18px; width: 11%">2</td>
- <td style="font-size: 18px; width: 11%">--</td>
- <td style="font-size: 18px; width: 11%">--</td>
- <td style="font-size: 18px; width: 11%">--</td>
- </tr>
- <tr class="tr_bg_light_warning" style="height:30px;">
- <td style="font-size: 18px; width: 11%">3</td>
- <td style="font-size: 18px; width: 11%">--</td>
- <td style="font-size: 18px; width: 11%">--</td>
- <td style="font-size: 18px; width: 11%">--</td>
- </tr>
- <tr class="tr_bg_light_warning" style="height:30px;">
- <td style="font-size: 18px; width: 11%">4</td>
- <td style="font-size: 18px; width: 11%">--</td>
- <td style="font-size: 18px; width: 11%">--</td>
- <td style="font-size: 18px; width: 11%">--</td>
- </tr>
- </table>
- </div>
- <div style="width: 920px; height: 480px; padding-right: 20px; display: flex; flex-direction: column; ">
- <div style="width: 100%; height: 480px; padding-right: 20px; display: flex; flex-direction: row; ">
- <div style="width: 50%; height: 250px;">
- <div style="color:white;font-size:20px;font-weight:600; text-align:center">试水1</div>
- <canvas id="canvasDefectB1" style="-moz-user-select: none; -webkit-user-select: none; -ms-user-select: none; height: 240px; width: 100%"></canvas>
- </div>
- <div style="width: 50%; height: 250px;">
- <div style="color:white;font-size:20px;font-weight:600; text-align:center">试水2</div>
- <canvas id="canvasDefectB2" style="-moz-user-select: none; -webkit-user-select: none; -ms-user-select: none; height: 240px; width: 100%"></canvas>
- </div>
- </div>
- <div style="width: 100%; height: 480px; padding-right: 20px; display: flex; flex-direction: row; ">
- <div style="width: 50%; height: 250px;">
- <div style="color:white;font-size:20px;font-weight:600; text-align:center">试水3</div>
- <canvas id="canvasDefectB3" style="-moz-user-select: none; -webkit-user-select: none; -ms-user-select: none; height: 240px; width: 100%"></canvas>
- </div>
- <div style="width: 50%; height: 250px;">
- <div style="color:white;font-size:20px;font-weight:600; text-align:center">试水4</div>
- <canvas id="canvasDefectB4" style="-moz-user-select: none; -webkit-user-select: none; -ms-user-select: none; height: 240px; width: 100%"></canvas>
- </div>
- </div>
- </div>
- </div>-->
- </div>
- </div>
- <script>
- var refreshTime1 = 80000;
- var refreshTime2 = 3000;
- var currentTime1 = 0;
- var currentTime2 = 0;
- var doGetData;
- var doGetTime;
- $(document).ready(function () {
- initData();
- clearData();
- doGetData = setInterval(function () { timeUpdate(); }, 1000);
- });
- function clearData() {
- //清除数据
- }
- function timeUpdate() {
- if (currentTime1 <= 0) {
- //clearData();
- setTimeout(loadData(), 1000);
- //loadData();
- currentTime1 = refreshTime1;
- }
- else {
- if (currentTime1 > 0) {
- //$('#报表加载').html('刷新:' + currentTime1 / 1000 + ' 秒');
- currentTime1 = currentTime1 - 1000;
- }
- }
- //if (currentTime2 <= 0) {
- // //clearData();
- // setTimeout(loadDataCurrentStatus(), 1000);
- // //loadData();
- // currentTime2 = refreshTime2;
- //}
- //else {
- // if (currentTime2 > 0) {
- // $('#报表加载').html('刷新:' + currentTime2 / 1000 + ' 秒');
- // currentTime2 = currentTime2 - 1000;
- // }
- //}
- }
- function loadDataCurrentStatus() {
- $.get("rpt.ashx?m=pieCurrent", function (data) {
- var json = JSON.parse(data);
- if (json["success"] == true) {
- for (var i = 0; i < json["rows"].length; i++) {
- if (json["rows"][i]["状态"] == '1') {
- $('#currentA' + (i + 1).toString()).addClass("isGreen");
- } else if (json["rows"][i]["状态"] == '2') {
- $('#currentA' + (i + 1).toString()).addClass("isOrange");
- } else if (json["rows"][i]["状态"] == '3') {
- $('#currentA' + (i + 1).toString()).addClass("isRed");
- } else {
- $('#currentA' + (i + 1).toString()).addClass("isWhite");
- }
- }
- }
- });
- }
- function loadData() {
- $.get("rpt.ashx?m=table", function (data) {
- var json = JSON.parse(data);
- if (json["success"] == true) {
- for (var i = 0; i < json["rows"].length; i++) {
- if (json["rows"][i]["产量"] == "0") {
- $('#tr' + (i + 1).toString()).remove();
- } else {
- $('#pd' + (i + 1).toString()).text(json["rows"][i]["产量"]);
- //$('#pg' + (i + 1).toString()).text(json["rows"][i]["合格数"]);
- //$('#gp' + (i + 1).toString()).text(json["rows"][i]["合格率"]);
- $('#yx' + (i + 1).toString()).text(json["rows"][i]["工作时间"]);
- $('#dd' + (i + 1).toString()).text(json["rows"][i]["等待时间"]);
- $('#gz' + (i + 1).toString()).text(json["rows"][i]["故障时间"]);
- //$('#pd' + (i + 1).toString()).text(json["rows"][i]["产量"]);
- //$('#pg' + (i + 1).toString()).text(json["rows"][i]["合格数"]);
- //$('#gp' + (i + 1).toString()).text(json["rows"][i]["合格率"]);
- }
- }
- }
- });
- $.get("rpt.ashx?m=table1", function (data) {
- var json = JSON.parse(data);
- if (json["success"] == true) {
- for (var i = 0; i < json["rows"].length; i++) {
- if (json["rows"][i]["产量"] == "0") {
- $('#str' + (i + 1).toString()).remove();
- } else {
- $('#spd' + (i + 1).toString()).text(json["rows"][i]["产量"]);
- $('#syx' + (i + 1).toString()).text(json["rows"][i]["工作时间"]);
- $('#sdd' + (i + 1).toString()).text(json["rows"][i]["等待时间"]);
- $('#sgz' + (i + 1).toString()).text(json["rows"][i]["故障时间"]);
- }
- }
- }
- });
- $.get("rpt.ashx?m=pie1", function (data) {
- var json = JSON.parse(data);
- if (json["success"] == true) {
- window.DefectA1.data.datasets[0].data = [(json["rows"][0]["NUM1"]), (json["rows"][0]["NUM2"]), (json["rows"][0]["NUM3"])];
- window.DefectA1.update();
- }
- });
- $.get("rpt.ashx?m=pie2", function (data) {
- var json = JSON.parse(data);
- if (json["success"] == true) {
- window.DefectA2.data.datasets[0].data = [(json["rows"][0]["NUM1"]), (json["rows"][0]["NUM2"]), (json["rows"][0]["NUM3"])];
- window.DefectA2.update();
- }
- });
- $.get("rpt.ashx?m=pie3", function (data) {
- var json = JSON.parse(data);
- if (json["success"] == true) {
- window.DefectA3.data.datasets[0].data = [(json["rows"][0]["NUM1"]), (json["rows"][0]["NUM2"]), (json["rows"][0]["NUM3"])];
- window.DefectA3.update();
- }
- });
- $.get("rpt.ashx?m=pie4", function (data) {
- var json = JSON.parse(data);
- if (json["success"] == true) {
- window.DefectA4.data.datasets[0].data = [(json["rows"][0]["NUM1"]), (json["rows"][0]["NUM2"]), (json["rows"][0]["NUM3"])];
- window.DefectA4.update();
- }
- });
- $.get("rpt.ashx?m=pie5", function (data) {
- var json = JSON.parse(data);
- if (json["success"] == true) {
- window.DefectA5.data.datasets[0].data = [(json["rows"][0]["NUM1"]), (json["rows"][0]["NUM2"]), (json["rows"][0]["NUM3"])];
- window.DefectA5.update();
- }
- });
- $.get("rpt.ashx?m=pie6", function (data) {
- var json = JSON.parse(data);
- if (json["success"] == true) {
- window.DefectA6.data.datasets[0].data = [(json["rows"][0]["NUM1"]), (json["rows"][0]["NUM2"]), (json["rows"][0]["NUM3"])];
- window.DefectA6.update();
- }
- });
- $.get("rpt.ashx?m=pie7", function (data) {
- var json = JSON.parse(data);
- if (json["success"] == true) {
- window.DefectA7.data.datasets[0].data = [(json["rows"][0]["NUM1"]), (json["rows"][0]["NUM2"]), (json["rows"][0]["NUM3"])];
- window.DefectA7.update();
- }
- });
- $.get("rpt.ashx?m=pie8", function (data) {
- var json = JSON.parse(data);
- if (json["success"] == true) {
- window.DefectA8.data.datasets[0].data = [(json["rows"][0]["NUM1"]), (json["rows"][0]["NUM2"]), (json["rows"][0]["NUM3"])];
- window.DefectA8.update();
- }
- });
- $.get("rpt.ashx?m=pie9", function (data) {
- var json = JSON.parse(data);
- console.log("pie9", json);
- if (json["success"] == true) {
- window.DefectA9.data.datasets[0].data = [(json["rows"][0]["NUM1"]), (json["rows"][0]["NUM2"]), (json["rows"][0]["NUM3"])];
- window.DefectA9.update();
- }
- });
- $.get("rpt.ashx?m=pie10", function (data) {
- var json = JSON.parse(data);
- if (json["success"] == true) {
- window.DefectA10.data.datasets[0].data = [(json["rows"][0]["NUM1"]), (json["rows"][0]["NUM2"]), (json["rows"][0]["NUM3"])];
- window.DefectA10.update();
- }
- });
- $.get("rpt.ashx?m=pie11", function (data) {
- var json = JSON.parse(data);
- if (json["success"] == true) {
- window.DefectA11.data.datasets[0].data = [(json["rows"][0]["NUM1"]), (json["rows"][0]["NUM2"]), (json["rows"][0]["NUM3"])];
- window.DefectA11.update();
- }
- });
- $.get("rpt.ashx?m=pie12", function (data) {
- var json = JSON.parse(data);
- if (json["success"] == true) {
- window.DefectA12.data.datasets[0].data = [(json["rows"][0]["NUM1"]), (json["rows"][0]["NUM2"]), (json["rows"][0]["NUM3"])];
- window.DefectA12.update();
- }
- });
- $.get("rpt.ashx?m=pieCurrent", function (data) {
- var json = JSON.parse(data);
- if (json["success"] == true) {
- for (var i = 0; i < json["rows"].length; i++) {
- if (json["rows"][i]["状态"] == '1') {
- $('#currentA' + (i + 1).toString()).addClass("isGreen");
- } else if (json["rows"][i]["状态"] == '2') {
- $('#currentA' + (i + 1).toString()).addClass("isOrange");
- } else if (json["rows"][i]["状态"] == '3') {
- $('#currentA' + (i + 1).toString()).addClass("isRed");
- } else {
- $('#currentA' + (i + 1).toString()).addClass("isWhite");
- }
- }
- }
- });
- //window.DefectA1.data.datasets[0].data = [
- // randomScalingFactor(8),
- // randomScalingFactor(8)
- //];
- //window.DefectA1.update();
- //window.DefectA2.data.datasets[0].data = [
- // randomScalingFactor(8),
- // randomScalingFactor(8)
- //];
- //window.DefectA2.update();
- //window.DefectA3.data.datasets[0].data = [
- // randomScalingFactor(8),
- // randomScalingFactor(8)
- //];
- //window.DefectA3.update();
- //window.DefectA4.data.datasets[0].data = [
- // randomScalingFactor(8),
- // randomScalingFactor(8)
- //];
- //window.DefectA4.update();
- //window.DefectA5.data.datasets[0].data = [
- // randomScalingFactor(8),
- // randomScalingFactor(8)
- //];
- //window.DefectA5.update();
- //window.DefectA6.data.datasets[0].data = [
- // randomScalingFactor(8),
- // randomScalingFactor(8)
- //];
- //window.DefectA6.update();
- //window.DefectA7.data.datasets[0].data = [
- // randomScalingFactor(8),
- // randomScalingFactor(8)
- //];
- //window.DefectA7.update();
- //window.DefectA8.data.datasets[0].data = [
- // randomScalingFactor(8),
- // randomScalingFactor(8)
- //];
- //window.DefectA8.update();
- }
- function initData() {
- window.chartColors = {
- red: 'rgb(255, 99, 132)',
- orange: 'rgb(255, 159, 64)',
- yellow: 'rgb(255, 250, 86)',
- green: 'rgb(75, 192, 192)',
- blue: 'rgb(54, 162, 250)',
- purple: 'rgb(153, 102, 255)',
- grey: 'rgb(231,233,237)'
- };
- var color = Chart.helpers.color;
- window.randomScalingFactor = function (num) {
- return Math.round(Math.random() * num);
- }
- Chart.defaults.global.defaultFontColor = 'white';
- Chart.defaults.global.defaultFontSize = 16;
- Chart.defaults.global.legend.display = false;
- //测漏气设备OEE===========================================
- window.configDefectA1 = {
- data: {
- labels: ['工作时间', '等待时间', '故障时间'],
- datasets: [{
- label: 'OEE',
- backgroundColor: [
- color(window.chartColors.green).alpha(0.35).rgbString(),
- color(window.chartColors.orange).alpha(0.35).rgbString(),
- color(window.chartColors.red).alpha(0.35).rgbString()
- ],
- fill: false,
- borderColor: [
- window.chartColors.green,
- window.chartColors.orange,
- window.chartColors.red
- ],
- borderWidth: 2,
- pointRadius: 30,
- data: [0, 0, 0]
- }]
- },
- type: 'pie',
- options: {
- legend: {
- display: true
- },
- title: {
- display: false,
- text: "测漏气1"
- },
- tooltips: {
- mode: 'point',
- intersect: false
- },
- responsive: true
- }
- };
- var ctxDefectA1 = document.getElementById("canvasDefectA1").getContext("2d");
- window.DefectA1 = new Chart(ctxDefectA1, configDefectA1);
- //===================================================
- //测漏气设备OEE===========================================
- window.configDefectA2 = {
- data: {
- labels: ['工作时间', '等待时间', '故障时间'],
- datasets: [{
- label: 'OEE',
- backgroundColor: [
- color(window.chartColors.green).alpha(0.35).rgbString(),
- color(window.chartColors.orange).alpha(0.35).rgbString(),
- color(window.chartColors.red).alpha(0.35).rgbString()
- ],
- fill: false,
- borderColor: [
- window.chartColors.green,
- window.chartColors.orange,
- window.chartColors.red
- ],
- borderWidth: 2,
- pointRadius: 30,
- data: [0, 0, 0]
- }]
- },
- type: 'pie',
- options: {
- legend: {
- display: true
- },
- title: {
- display: false,
- text: "测漏气2"
- },
- tooltips: {
- mode: 'point',
- intersect: false
- },
- responsive: true
- }
- };
- var ctxDefectA2 = document.getElementById("canvasDefectA2").getContext("2d");
- window.DefectA2 = new Chart(ctxDefectA2, configDefectA2);
- //===================================================
- //测漏气设备OEE===========================================
- window.configDefectA3 = {
- data: {
- labels: ['工作时间', '等待时间', '故障时间'],
- datasets: [{
- label: 'OEE',
- backgroundColor: [
- color(window.chartColors.green).alpha(0.35).rgbString(),
- color(window.chartColors.orange).alpha(0.35).rgbString(),
- color(window.chartColors.red).alpha(0.35).rgbString()
- ],
- fill: false,
- borderColor: [
- window.chartColors.green,
- window.chartColors.orange,
- window.chartColors.red
- ],
- borderWidth: 2,
- pointRadius: 30,
- data: [0, 0, 0]
- }]
- },
- type: 'pie',
- options: {
- legend: {
- display: true
- },
- title: {
- display: false,
- text: "测漏气3"
- },
- tooltips: {
- mode: 'point',
- intersect: false
- },
- responsive: true
- }
- };
- var ctxDefectA3 = document.getElementById("canvasDefectA3").getContext("2d");
- window.DefectA3 = new Chart(ctxDefectA3, configDefectA3);
- //===================================================
- //测漏气设备OEE===========================================
- window.configDefectA4 = {
- data: {
- labels: ['工作时间', '等待时间', '故障时间'],
- datasets: [{
- label: 'OEE',
- backgroundColor: [
- color(window.chartColors.green).alpha(0.35).rgbString(),
- color(window.chartColors.orange).alpha(0.35).rgbString(),
- color(window.chartColors.red).alpha(0.35).rgbString()
- ],
- fill: false,
- borderColor: [
- window.chartColors.green,
- window.chartColors.orange,
- window.chartColors.red
- ],
- borderWidth: 2,
- pointRadius: 30,
- data: [0, 0, 0]
- }]
- },
- type: 'pie',
- options: {
- legend: {
- display: true
- },
- title: {
- display: false,
- text: "测漏气4"
- },
- tooltips: {
- mode: 'point',
- intersect: false
- },
- responsive: true
- }
- };
- var ctxDefectA4 = document.getElementById("canvasDefectA4").getContext("2d");
- window.DefectA4 = new Chart(ctxDefectA4, configDefectA4);
- //===================================================
- //测漏气设备OEE===========================================
- window.configDefectA5 = {
- data: {
- labels: ['工作时间', '等待时间', '故障时间'],
- datasets: [{
- label: 'OEE',
- backgroundColor: [
- color(window.chartColors.green).alpha(0.35).rgbString(),
- color(window.chartColors.orange).alpha(0.35).rgbString(),
- color(window.chartColors.red).alpha(0.35).rgbString()
- ],
- fill: false,
- borderColor: [
- window.chartColors.green,
- window.chartColors.orange,
- window.chartColors.red
- ],
- borderWidth: 2,
- pointRadius: 30,
- data: [0, 0, 0]
- }]
- },
- type: 'pie',
- options: {
- legend: {
- display: true
- },
- title: {
- display: false,
- text: "测漏气5"
- },
- tooltips: {
- mode: 'point',
- intersect: false
- },
- responsive: true
- }
- };
- var ctxDefectA5 = document.getElementById("canvasDefectA5").getContext("2d");
- window.DefectA5 = new Chart(ctxDefectA5, configDefectA5);
- //===================================================
- //测漏气设备OEE===========================================
- window.configDefectA6 = {
- data: {
- labels: ['工作时间', '等待时间', '故障时间'],
- datasets: [{
- label: 'OEE',
- backgroundColor: [
- color(window.chartColors.green).alpha(0.35).rgbString(),
- color(window.chartColors.orange).alpha(0.35).rgbString(),
- color(window.chartColors.red).alpha(0.35).rgbString()
- ],
- fill: false,
- borderColor: [
- window.chartColors.green,
- window.chartColors.orange,
- window.chartColors.red
- ],
- borderWidth: 2,
- pointRadius: 30,
- data: [0, 0, 0]
- }]
- },
- type: 'pie',
- options: {
- legend: {
- display: true
- },
- title: {
- display: false,
- text: "测漏气6"
- },
- tooltips: {
- mode: 'point',
- intersect: false
- },
- responsive: true
- }
- };
- var ctxDefectA6 = document.getElementById("canvasDefectA6").getContext("2d");
- window.DefectA6 = new Chart(ctxDefectA6, configDefectA6);
- //===================================================
- //测漏气设备OEE===========================================
- window.configDefectA7 = {
- data: {
- labels: ['工作时间', '等待时间', '故障时间'],
- datasets: [{
- label: 'OEE',
- backgroundColor: [
- color(window.chartColors.green).alpha(0.35).rgbString(),
- color(window.chartColors.orange).alpha(0.35).rgbString(),
- color(window.chartColors.red).alpha(0.35).rgbString()
- ],
- fill: false,
- borderColor: [
- window.chartColors.green,
- window.chartColors.orange,
- window.chartColors.red
- ],
- borderWidth: 2,
- pointRadius: 30,
- data: [0, 0, 0]
- }]
- },
- type: 'pie',
- options: {
- legend: {
- display: true
- },
- title: {
- display: false,
- text: "测漏气7"
- },
- tooltips: {
- mode: 'point',
- intersect: false
- },
- responsive: true
- }
- };
- var ctxDefectA7 = document.getElementById("canvasDefectA7").getContext("2d");
- window.DefectA7 = new Chart(ctxDefectA7, configDefectA7);
- //===================================================
- //测漏气设备OEE===========================================
- window.configDefectA8 = {
- data: {
- labels: ['工作时间', '等待时间', '故障时间'],
- datasets: [{
- label: 'OEE',
- backgroundColor: [
- color(window.chartColors.green).alpha(0.35).rgbString(),
- color(window.chartColors.orange).alpha(0.35).rgbString(),
- color(window.chartColors.red).alpha(0.35).rgbString()
- ],
- fill: false,
- borderColor: [
- window.chartColors.green,
- window.chartColors.orange,
- window.chartColors.red
- ],
- borderWidth: 2,
- pointRadius: 30,
- data: [0, 0, 0]
- }]
- },
- type: 'pie',
- options: {
- legend: {
- display: true
- },
- title: {
- display: false,
- text: "测漏气8"
- },
- tooltips: {
- mode: 'point',
- intersect: false
- },
- responsive: true
- }
- };
- var ctxDefectA8 = document.getElementById("canvasDefectA8").getContext("2d");
- window.DefectA8 = new Chart(ctxDefectA8, configDefectA8);
- //===================================================
- window.configDefectA9 = {
- data: {
- labels: ['工作时间', '等待时间', '故障时间'],
- datasets: [{
- label: 'OEE',
- backgroundColor: [
- color(window.chartColors.green).alpha(0.35).rgbString(),
- color(window.chartColors.orange).alpha(0.35).rgbString(),
- color(window.chartColors.red).alpha(0.35).rgbString()
- ],
- fill: false,
- borderColor: [
- window.chartColors.green,
- window.chartColors.orange,
- window.chartColors.red
- ],
- borderWidth: 2,
- pointRadius: 30,
- data: [0, 0, 0]
- }]
- },
- type: 'pie',
- options: {
- legend: {
- display: true
- },
- title: {
- display: false,
- text: "倒水机1"
- },
- tooltips: {
- mode: 'point',
- intersect: false
- },
- responsive: true
- }
- };
- var ctxDefectA9 = document.getElementById("canvasDefectA9").getContext("2d");
- window.DefectA9 = new Chart(ctxDefectA9, configDefectA9);
- window.configDefectA10 = {
- data: {
- labels: ['工作时间', '等待时间', '故障时间'],
- datasets: [{
- label: 'OEE',
- backgroundColor: [
- color(window.chartColors.green).alpha(0.35).rgbString(),
- color(window.chartColors.orange).alpha(0.35).rgbString(),
- color(window.chartColors.red).alpha(0.35).rgbString()
- ],
- fill: false,
- borderColor: [
- window.chartColors.green,
- window.chartColors.orange,
- window.chartColors.red
- ],
- borderWidth: 2,
- pointRadius: 30,
- data: [0, 0, 0]
- }]
- },
- type: 'pie',
- options: {
- legend: {
- display: true
- },
- title: {
- display: false,
- text: "倒水机2"
- },
- tooltips: {
- mode: 'point',
- intersect: false
- },
- responsive: true
- }
- };
- var ctxDefectA10 = document.getElementById("canvasDefectA10").getContext("2d");
- window.DefectA10 = new Chart(ctxDefectA10, configDefectA10);
- window.configDefectA11 = {
- data: {
- labels: ['工作时间', '等待时间', '故障时间'],
- datasets: [{
- label: 'OEE',
- backgroundColor: [
- color(window.chartColors.green).alpha(0.35).rgbString(),
- color(window.chartColors.orange).alpha(0.35).rgbString(),
- color(window.chartColors.red).alpha(0.35).rgbString()
- ],
- fill: false,
- borderColor: [
- window.chartColors.green,
- window.chartColors.orange,
- window.chartColors.red
- ],
- borderWidth: 2,
- pointRadius: 30,
- data: [0, 0, 0]
- }]
- },
- type: 'pie',
- options: {
- legend: {
- display: true
- },
- title: {
- display: false,
- text: "倒水机3"
- },
- tooltips: {
- mode: 'point',
- intersect: false
- },
- responsive: true
- }
- };
- var ctxDefectA11 = document.getElementById("canvasDefectA11").getContext("2d");
- window.DefectA11 = new Chart(ctxDefectA11, configDefectA11);
- window.configDefectA12 = {
- data: {
- labels: ['工作时间', '等待时间', '故障时间'],
- datasets: [{
- label: 'OEE',
- backgroundColor: [
- color(window.chartColors.green).alpha(0.35).rgbString(),
- color(window.chartColors.orange).alpha(0.35).rgbString(),
- color(window.chartColors.red).alpha(0.35).rgbString()
- ],
- fill: false,
- borderColor: [
- window.chartColors.green,
- window.chartColors.orange,
- window.chartColors.red
- ],
- borderWidth: 2,
- pointRadius: 30,
- data: [0, 0, 0]
- }]
- },
- type: 'pie',
- options: {
- legend: {
- display: true
- },
- title: {
- display: false,
- text: "倒水机4"
- },
- tooltips: {
- mode: 'point',
- intersect: false
- },
- responsive: true
- }
- };
- var ctxDefectA12 = document.getElementById("canvasDefectA12").getContext("2d");
- window.DefectA12 = new Chart(ctxDefectA12, configDefectA12);
- ////试水设备OEE===========================================
- //window.configDefectB1 = {
- // data: {
- // labels: ['工作时间', '等待时间', '故障时间'],
- // datasets: [{
- // label: 'OEE',
- // backgroundColor: [
- // color(window.chartColors.green).alpha(0.35).rgbString(),
- // color(window.chartColors.orange).alpha(0.35).rgbString()
- // ],
- // fill: false,
- // borderColor: [
- // window.chartColors.green,
- // window.chartColors.orange
- // ],
- // borderWidth: 2,
- // pointRadius: 30,
- // data: [0,0,0]
- // }]
- // },
- // type: 'pie',
- // options: {
- // legend: {
- // display: true
- // },
- // title: {
- // display: false,
- // text: "试水1"
- // },
- // tooltips: {
- // mode: 'point',
- // intersect: false
- // },
- // responsive: true
- // }
- //};
- //var ctxDefectB1 = document.getElementById("canvasDefectB1").getContext("2d");
- //window.DefectB1 = new Chart(ctxDefectB1, configDefectB1);
- ////===================================================
- ////试水设备OEE===========================================
- //window.configDefectB2 = {
- // data: {
- // labels: ['工作时间', '等待时间', '故障时间'],
- // datasets: [{
- // label: 'OEE',
- // backgroundColor: [
- // color(window.chartColors.green).alpha(0.35).rgbString(),
- // color(window.chartColors.orange).alpha(0.35).rgbString()
- // ],
- // fill: false,
- // borderColor: [
- // window.chartColors.green,
- // window.chartColors.orange
- // ],
- // borderWidth: 2,
- // pointRadius: 30,
- // data: [0,0,0]
- // }]
- // },
- // type: 'pie',
- // options: {
- // legend: {
- // display: true
- // },
- // title: {
- // display: false,
- // text: "试水2"
- // },
- // tooltips: {
- // mode: 'point',
- // intersect: false
- // },
- // responsive: true
- // }
- //};
- //var ctxDefectB2 = document.getElementById("canvasDefectB2").getContext("2d");
- //window.DefectB2 = new Chart(ctxDefectB2, configDefectB2);
- ////===================================================
- ////试水设备OEE===========================================
- //window.configDefectB3 = {
- // data: {
- // labels: ['工作时间', '等待时间', '故障时间'],
- // datasets: [{
- // label: 'OEE',
- // backgroundColor: [
- // color(window.chartColors.green).alpha(0.35).rgbString(),
- // color(window.chartColors.orange).alpha(0.35).rgbString()
- // ],
- // fill: false,
- // borderColor: [
- // window.chartColors.green,
- // window.chartColors.orange
- // ],
- // borderWidth: 2,
- // pointRadius: 30,
- // data: [0,0,0]
- // }]
- // },
- // type: 'pie',
- // options: {
- // legend: {
- // display: true
- // },
- // title: {
- // display: false,
- // text: "试水3"
- // },
- // tooltips: {
- // mode: 'point',
- // intersect: false
- // },
- // responsive: true
- // }
- //};
- //var ctxDefectB3 = document.getElementById("canvasDefectB3").getContext("2d");
- //window.DefectB3 = new Chart(ctxDefectB3, configDefectB3);
- ////===================================================
- ////试水设备OEE===========================================
- //window.configDefectB4 = {
- // data: {
- // labels: ['工作时间', '等待时间', '故障时间'],
- // datasets: [{
- // label: 'OEE',
- // backgroundColor: [
- // color(window.chartColors.green).alpha(0.35).rgbString(),
- // color(window.chartColors.orange).alpha(0.35).rgbString()
- // ],
- // fill: false,
- // borderColor: [
- // window.chartColors.green,
- // window.chartColors.orange
- // ],
- // borderWidth: 2,
- // pointRadius: 30,
- // data: [0,0,0]
- // }]
- // },
- // type: 'pie',
- // options: {
- // legend: {
- // display: true
- // },
- // title: {
- // display: false,
- // text: "试水4"
- // },
- // tooltips: {
- // mode: 'point',
- // intersect: false
- // },
- // responsive: true
- // }
- //};
- //var ctxDefectB4 = document.getElementById("canvasDefectB4").getContext("2d");
- //window.DefectB4 = new Chart(ctxDefectB4, configDefectB4);
- ////===================================================
- }
- </script>
- <script src="/Plugins/chartjs-2.8.0/chart-2.8.min.js"></script>
- <script src="/Plugins/chartjs-2.8.0/chartjs-plugin-datalabels.js"></script>
- <script src="/Plugins/chartjs-2.8.0/utils.js"></script>
- <script src="/Plugins/circleChart/circleChart.min.js"></script>
- <style>
- .isGreen {
- background-color: #33bad7;
- box-shadow: 0 0 15px #13e5eb;
- }
- .isOrange {
- background-color: #dd8935;
- box-shadow: 0 0 15px orange;
- }
- .isRed {
- background-color: #cf406d;
- box-shadow: 0 0 15px #c35678;
- }
- .isWhite {
- background-color: white;
- box-shadow: 0 0 15px white;
- }
- </style>
- </body>
- </html>
|