lazhang.html 38 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="UTF-8">
  5. <meta http-equiv="X-UA-Compatible" content="IE=Edge">
  6. <meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" name="viewport">
  7. <title>流水线管理页</title>
  8. <!-- Favicon-->
  9. <link rel="icon" href="favicon.ico" type="image/x-icon">
  10. <!-- Google Fonts -->
  11. <link href="css/cyllic.css" rel="stylesheet" type="text/css">
  12. <link href="css/mateial.css" rel="stylesheet" type="text/css">
  13. <!-- Bootstrap Core Css -->
  14. <link rel="stylesheet" href="https://cdn.bootcss.com/bootstrap/4.0.0/css/bootstrap.min.css"
  15. integrity="sha384-Gn5384xqQ1aoWXA+058RXPxPg6fy4IWvTNh0E263XmFcJlSAwiGgFAW/dAiS6JXm" crossorigin="anonymous">
  16. <!-- Waves Effect Css -->
  17. <link href="plugins/node-waves/waves.css" rel="stylesheet"/>
  18. <!-- Animation Css -->
  19. <link href="plugins/animate-css/animate.css" rel="stylesheet"/>
  20. <!-- Morris Chart Css-->
  21. <link href="plugins/morrisjs/morris.css" rel="stylesheet"/>
  22. <!-- Custom Css -->
  23. <link href="css/style.css" rel="stylesheet">
  24. <!-- AdminBSB Themes. You can choose a theme from css/themes instead of get all themes -->
  25. <link href="css/themes/all-themes.css" rel="stylesheet"/>
  26. <script src="https://cdn.bootcss.com/jquery/3.2.1/jquery.min.js"></script>
  27. <script src="https://cdn.bootcss.com/popper.js/1.12.9/umd/popper.min.js"
  28. integrity="sha384-ApNbgh9B+Y1QKtv3Rn7W3mgPxhU9K/ScQsAP7hUibX39j7fakFPskvXusvfa0b4Q"
  29. crossorigin="anonymous"></script>
  30. <script src="https://cdn.bootcss.com/bootstrap/4.0.0/js/bootstrap.min.js"
  31. integrity="sha384-JZR6Spejh4U02d8jOt6vLEHfe/JQGiRRSQQxSfFWpi1MquVdAyjUar5+76PVCmYl"
  32. crossorigin="anonymous"></script>
  33. <link rel="icon" href="https://static.jianshukeji.com/highcharts/images/favicon.ico">
  34. <meta name="viewport" content="width=device-width, initial-scale=1">
  35. <style>
  36. /* css 代码 */
  37. </style>
  38. <script src="https://img.hcharts.cn/highcharts/highcharts.js"></script>
  39. <script src="https://img.hcharts.cn/highcharts/modules/exporting.js"></script>
  40. <script src="https://img.hcharts.cn/highcharts-plugins/highcharts-zh_CN.js"></script>
  41. <script src="https://img.hcharts.cn/highcharts/themes/dark-unica.js"></script>
  42. <script language="JavaScript">
  43. function startTime()
  44. {
  45. var today=new Date();//定义日期对象
  46. var yyyy = today.getFullYear();//通过日期对象的getFullYear()方法返回年
  47. var MM = today.getMonth()+1;//通过日期对象的getMonth()方法返回年
  48. var dd = today.getDate();//通过日期对象的getDate()方法返回年
  49. var hh=today.getHours();//通过日期对象的getHours方法返回小时
  50. var mm=today.getMinutes();//通过日期对象的getMinutes方法返回分钟
  51. var ss=today.getSeconds();//通过日期对象的getSeconds方法返回秒
  52. // 如果分钟或小时的值小于10,则在其值前加0,比如如果时间是下午3点20分9秒的话,则显示15:20:09
  53. MM=checkTime(MM);
  54. dd=checkTime(dd);
  55. mm=checkTime(mm);
  56. ss=checkTime(ss);
  57. var day; //用于保存星期(getDay()方法得到星期编号)
  58. if(today.getDay()==0) day = "星期日 "
  59. if(today.getDay()==1) day = "星期一 "
  60. if(today.getDay()==2) day = "星期二 "
  61. if(today.getDay()==3) day = "星期三 "
  62. if(today.getDay()==4) day = "星期四 "
  63. if(today.getDay()==5) day = "星期五 "
  64. if(today.getDay()==6) day = "星期六 "
  65. document.getElementById('nowDateTimeSpan').innerHTML=yyyy+"-"+MM +"-"+ dd +" " + hh+":"+mm+":"+ss+" " + day;
  66. setTimeout('startTime()',1000);//每一秒中重新加载startTime()方法
  67. }
  68. function checkTime(i)
  69. {
  70. if (i<10){
  71. i="0" + i;
  72. }
  73. return i;
  74. }
  75. </script>
  76. </head>
  77. <body class="theme-black" style="background-color: #17253f !important;" onload="startTime()">
  78. <nav class="navbar" style="background-color: red">
  79. <div class="container-fluid">
  80. <div class="navbar-header">
  81. <a class="navbar-brand" href="index.html">工厂产能监控系统</a>
  82. </div>
  83. <div style="color: #ffffff"><img src="images/logo.jpg" style="width: 10%"> 深圳市度彼电子有限公司——</div>
  84. <font color="#ffffff"><span id="nowDateTimeSpan"></span></font>
  85. </div>
  86. <!-- <div class="collapse navbar-collapse" id="navbar-collapse">
  87. <ul class="nav navbar-nav navbar-right">
  88. <!-- Call Search -->
  89. <!-- <li><a href="javascript:void(0);" class="js-search" data-close="true"><i class="material-icons">search</i></a></li>
  90. <!-- #END# Call Search -->
  91. <!-- Notifications -->
  92. <!-- <li class="dropdown">
  93. <a href="javascript:void(0);" class="dropdown-toggle" data-toggle="dropdown" role="button">
  94. <i class="material-icons">notifications</i>
  95. <span class="label-count">7</span>
  96. </a>
  97. <ul class="dropdown-menu">
  98. <li class="header">NOTIFICATIONS</li>
  99. <li class="body">
  100. <div class="slimScrollDiv" style="position: relative; overflow: hidden; width: auto; height: 254px;"><ul class="menu" style="overflow: hidden; width: auto; height: 254px;">
  101. <li>
  102. <a href="javascript:void(0);" class=" waves-effect waves-block">
  103. <div class="icon-circle bg-light-green">
  104. <i class="material-icons">person_add</i>
  105. </div>
  106. <div class="menu-info">
  107. <h4>12 new members joined</h4>
  108. <p>
  109. <i class="material-icons">access_time</i> 14 mins ago
  110. </p>
  111. </div>
  112. </a>
  113. </li>
  114. <li>
  115. <a href="javascript:void(0);" class=" waves-effect waves-block">
  116. <div class="icon-circle bg-cyan">
  117. <i class="material-icons">add_shopping_cart</i>
  118. </div>
  119. <div class="menu-info">
  120. <h4>4 sales made</h4>
  121. <p>
  122. <i class="material-icons">access_time</i> 22 mins ago
  123. </p>
  124. </div>
  125. </a>
  126. </li>
  127. <li>
  128. <a href="javascript:void(0);" class=" waves-effect waves-block">
  129. <div class="icon-circle bg-red">
  130. <i class="material-icons">delete_forever</i>
  131. </div>
  132. <div class="menu-info">
  133. <h4><b>Nancy Doe</b> deleted account</h4>
  134. <p>
  135. <i class="material-icons">access_time</i> 3 hours ago
  136. </p>
  137. </div>
  138. </a>
  139. </li>
  140. <li>
  141. <a href="javascript:void(0);" class=" waves-effect waves-block">
  142. <div class="icon-circle bg-orange">
  143. <i class="material-icons">mode_edit</i>
  144. </div>
  145. <div class="menu-info">
  146. <h4><b>Nancy</b> changed name</h4>
  147. <p>
  148. <i class="material-icons">access_time</i> 2 hours ago
  149. </p>
  150. </div>
  151. </a>
  152. </li>
  153. <li>
  154. <a href="javascript:void(0);" class=" waves-effect waves-block">
  155. <div class="icon-circle bg-blue-grey">
  156. <i class="material-icons">comment</i>
  157. </div>
  158. <div class="menu-info">
  159. <h4><b>John</b> commented your post</h4>
  160. <p>
  161. <i class="material-icons">access_time</i> 4 hours ago
  162. </p>
  163. </div>
  164. </a>
  165. </li>
  166. <li>
  167. <a href="javascript:void(0);" class=" waves-effect waves-block">
  168. <div class="icon-circle bg-light-green">
  169. <i class="material-icons">cached</i>
  170. </div>
  171. <div class="menu-info">
  172. <h4><b>John</b> updated status</h4>
  173. <p>
  174. <i class="material-icons">access_time</i> 3 hours ago
  175. </p>
  176. </div>
  177. </a>
  178. </li>
  179. <li>
  180. <a href="javascript:void(0);" class=" waves-effect waves-block">
  181. <div class="icon-circle bg-purple">
  182. <i class="material-icons">settings</i>
  183. </div>
  184. <div class="menu-info">
  185. <h4>Settings updated</h4>
  186. <p>
  187. <i class="material-icons">access_time</i> Yesterday
  188. </p>
  189. </div>
  190. </a>
  191. </li>
  192. </ul><div class="slimScrollBar" style="background: rgba(0, 0, 0, 0.5); width: 4px; position: absolute; top: 0px; opacity: 0.4; display: block; border-radius: 0px; z-index: 99; right: 1px;"></div><div class="slimScrollRail" style="width: 4px; height: 100%; position: absolute; top: 0px; display: none; border-radius: 0px; background: rgb(51, 51, 51); opacity: 0.2; z-index: 90; right: 1px;"></div></div>
  193. </li>
  194. <li class="footer">
  195. <a href="javascript:void(0);" class=" waves-effect waves-block">View All Notifications</a>
  196. </li>
  197. </ul>
  198. </li>
  199. <!-- #END# Notifications -->
  200. <!-- Tasks -->
  201. <!-- <li class="dropdown">
  202. <a href="javascript:void(0);" class="dropdown-toggle" data-toggle="dropdown" role="button">
  203. <i class="material-icons">flag</i>
  204. <span class="label-count">9</span>
  205. </a>
  206. <ul class="dropdown-menu">
  207. <li class="header">TASKS</li>
  208. <li class="body">
  209. <div class="slimScrollDiv" style="position: relative; overflow: hidden; width: auto; height: 254px;"><ul class="menu tasks" style="overflow: hidden; width: auto; height: 254px;">
  210. <li>
  211. <a href="javascript:void(0);" class=" waves-effect waves-block">
  212. <h4>
  213. Footer display issue
  214. <small>32%</small>
  215. </h4>
  216. <div class="progress">
  217. <div class="progress-bar bg-pink" role="progressbar" aria-valuenow="85" aria-valuemin="0" aria-valuemax="100" style="width: 32%">
  218. </div>
  219. </div>
  220. </a>
  221. </li>
  222. <li>
  223. <a href="javascript:void(0);" class=" waves-effect waves-block">
  224. <h4>
  225. Make new buttons
  226. <small>45%</small>
  227. </h4>
  228. <div class="progress">
  229. <div class="progress-bar bg-cyan" role="progressbar" aria-valuenow="85" aria-valuemin="0" aria-valuemax="100" style="width: 45%">
  230. </div>
  231. </div>
  232. </a>
  233. </li>
  234. <li>
  235. <a href="javascript:void(0);" class=" waves-effect waves-block">
  236. <h4>
  237. Create new dashboard
  238. <small>54%</small>
  239. </h4>
  240. <div class="progress">
  241. <div class="progress-bar bg-teal" role="progressbar" aria-valuenow="85" aria-valuemin="0" aria-valuemax="100" style="width: 54%">
  242. </div>
  243. </div>
  244. </a>
  245. </li>
  246. <li>
  247. <a href="javascript:void(0);" class=" waves-effect waves-block">
  248. <h4>
  249. Solve transition issue
  250. <small>65%</small>
  251. </h4>
  252. <div class="progress">
  253. <div class="progress-bar bg-orange" role="progressbar" aria-valuenow="85" aria-valuemin="0" aria-valuemax="100" style="width: 65%">
  254. </div>
  255. </div>
  256. </a>
  257. </li>
  258. <li>
  259. <a href="javascript:void(0);" class=" waves-effect waves-block">
  260. <h4>
  261. Answer GitHub questions
  262. <small>92%</small>
  263. </h4>
  264. <div class="progress">
  265. <div class="progress-bar bg-purple" role="progressbar" aria-valuenow="85" aria-valuemin="0" aria-valuemax="100" style="width: 92%">
  266. </div>
  267. </div>
  268. </a>
  269. </li>
  270. </ul><div class="slimScrollBar" style="background: rgba(0, 0, 0, 0.5); width: 4px; position: absolute; top: 0px; opacity: 0.4; display: block; border-radius: 0px; z-index: 99; right: 1px;"></div><div class="slimScrollRail" style="width: 4px; height: 100%; position: absolute; top: 0px; display: none; border-radius: 0px; background: rgb(51, 51, 51); opacity: 0.2; z-index: 90; right: 1px;"></div></div>
  271. </li>
  272. <li class="footer">
  273. <a href="javascript:void(0);" class=" waves-effect waves-block">View All Tasks</a>
  274. </li>
  275. </ul>
  276. </li>
  277. <!-- #END# Tasks -->
  278. <!-- <li class="pull-right"><a href="javascript:void(0);" class="js-right-sidebar" data-close="true"><i class="material-icons">more_vert</i></a></li>
  279. </ul>
  280. </div> -->
  281. </nav>
  282. <section style="margin-top: 100px;color: #ffffff" style-height="30-1">
  283. <div style="width: 38%;float: left">
  284. <div class="text-center">本拉产能统计</div>
  285. <table class="table table-bordered text-center" style="color: #ffffff">
  286. <thead>
  287. <tr>
  288. <th scope="col">#</th>
  289. <th scope="col">First</th>
  290. <th scope="col">Last</th>
  291. <th scope="col">Handle</th>
  292. </tr>
  293. </thead>
  294. <tbody id="rank-one">
  295. <tr>
  296. <th scope="row">1</th>
  297. <td>Mark</td>
  298. <td>Otto</td>
  299. <td>@mdo</td>
  300. </tr>
  301. <tr>
  302. <th scope="row">2</th>
  303. <td>Jacob</td>
  304. <td>Thornton</td>
  305. <td>@fat</td>
  306. </tr>
  307. <tr>
  308. <th scope="row">3</th>
  309. <td>Larry</td>
  310. <td>the Bird</td>
  311. <td>@twitter</td>
  312. </tr>
  313. </tbody>
  314. </table>
  315. </div>
  316. <div style="width: 60%;float: right">
  317. <div class="text-center">本厂今日生产能手榜</div>
  318. <table class="table table-bordered text-center" style="color: #ffffff">
  319. <thead>
  320. <tr >
  321. <th scope="col" colspan="2">First</th>
  322. <th scope="col" colspan="2">Handle</th>
  323. </tr>
  324. </thead>
  325. <tbody>
  326. <tr>
  327. <th scope="row">1</th>
  328. <td>Mark</td>
  329. <td>Otto</td>
  330. <td>@mdo</td>
  331. </tr>
  332. <tr>
  333. <th scope="row">2</th>
  334. <td>Jacob</td>
  335. <td>Thornton</td>
  336. <td>@fat</td>
  337. </tr>
  338. <tr>
  339. <th scope="row">3</th>
  340. <td>Larry</td>
  341. <td>the Bird</td>
  342. <td>@twitter</td>
  343. </tr>
  344. </tbody>
  345. </table>
  346. </div>
  347. </section>
  348. <!--<nav class="navbar navbar-expand-lg navbar-light bg-light" style-height="10">-- >
  349. <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarTogglerDemo01" aria-controls="navbarTogglerDemo01" aria-expanded="false" aria-label="Toggle navigation">
  350. <span class="navbar-toggler-icon"></span>
  351. </button>
  352. <div class="collapse navbar-collapse" id="navbarTogglerDemo01">
  353. <a class="navbar-brand" href="#">Hidden brand</a>
  354. <ul class="navbar-nav mr-auto mt-2 mt-lg-0">
  355. <li class="nav-item active">
  356. <a class="nav-link" href="#">生产线<span>1</span>号 </a>
  357. </li>
  358. <li class="nav-item">
  359. <a class="nav-link" href="#"><span id="clockt"></span></a>
  360. </li>
  361. <li class="nav-item">
  362. <a class="nav-link disabled" href="#">Disabled</a>
  363. </li>
  364. </ul>
  365. <form class="form-inline my-2 my-lg-0">
  366. <input class="form-control mr-sm-2" type="search" placeholder="Search" aria-label="Search">
  367. <button class="btn btn-outline-success my-2 my-sm-0" type="submit">下班</button>
  368. <div class="dropdown">
  369. <button class="btn btn-default dropdown-toggle" type="button" id="dropdownMenu2" data-toggle="dropdown"
  370. aria-haspopup="true" aria-expanded="false" style="font-size: 0.5em">
  371. <div class="row">
  372. <div class="col-4">
  373. 拉长
  374. </div>
  375. <div class="col-5">
  376. 张三
  377. </div>
  378. </div>
  379. </button>
  380. <ul class="dropdown-menu" aria-labelledby="dropdownMenu2">
  381. <li><a href="#">更改密码</a></li>
  382. <li><a href="#">退出登录</a></li>
  383. </ul>
  384. </div>
  385. </form>
  386. </div>
  387. </nav>-->
  388. <!--<section class="content" style="margin: 0 auto; margin-top: 100px;">
  389. <!--<div class="row"></div>
  390. <div class="container-fluid " style="margin-bottom: 1em;">
  391. <div class="row text-center">
  392. <div class="col-lg-3 col-md-3 col-sm-6 col-xs-12">
  393. <div class="info-box bg-green hover-expand-effect" style="margin: 0;">
  394. <div class="icon">
  395. <i class="material-icons">equalizer</i>
  396. </div>
  397. <div class="content">
  398. <div class="row text-center" style="margin: 0 auto">
  399. <div class="text" style="font-size: 1.5em;padding-top: 0.2em">合格数:</div>
  400. <div class="number" style="font-size: 3em" id="test1"></div>
  401. </div>
  402. </div>
  403. </div>
  404. </div>
  405. <div class="col-lg-3 col-md-3 col-sm-6 col-xs-12">
  406. <div class="info-box bg-red hover-expand-effect" style="margin: 0;">
  407. <div class="icon">
  408. <i class="material-icons">equalizer</i>
  409. </div>
  410. <div class="content">
  411. <div class="row text-center" style="margin: 0 auto">
  412. <div class="text" style="font-size: 1.5em;padding-top: 0.2em">不合格数:</div>
  413. <div class="number" style="font-size: 3em" id="test2"></div>
  414. </div>
  415. </div>
  416. </div>
  417. </div>
  418. <div class="col-lg-3 col-md-3 col-sm-6 col-xs-12">
  419. <div class="info-box bg-lime hover-expand-effect" style="margin: 0;">
  420. <div class="icon">
  421. <i class="material-icons">brightness_low</i>
  422. </div>
  423. <div class="content">
  424. <div class="row text-center" style="margin: 0 auto">
  425. <div class="text" style="font-size: 1.5em;padding-top: 0.2em">不良率:</div>
  426. <div class="number" style="font-size: 3em" id="test3"></div>
  427. </div>
  428. </div>
  429. </div>
  430. </div>
  431. <div class="col-lg-3 col-md-3 col-sm-6 col-xs-12">
  432. <div class="info-box bg-cyan hover-zoom-effect" style="margin: 0; ">
  433. <div class="icon">
  434. <i class="material-icons">access_alarm</i>
  435. </div>
  436. <div class="content">
  437. <div class="row text-center" style="margin: 0 auto">
  438. <div class="text" style="font-size: 1.5em;padding-top: 0.2em">堆积数:</div>
  439. <div class="number" style="font-size: 3em" id="test4"></div>
  440. </div>
  441. </div>
  442. </div>
  443. </div>
  444. </div>
  445. </div> -->
  446. <!--<div class="container-fluid" style="margin-top: 0.5em;padding-top: 1em">
  447. <!-- <div class="card" style-height="30-8" style="margin: 0 auto;">
  448. --<div>
  449. <div class="" style="">
  450. <div class="table-responsive" style="width: 30%;float: left">
  451. <table class="table table-hover dashboard-task-infos">
  452. <thead>
  453. <tr style="border-bottom:3px solid black;">
  454. <th>姓名(工号)</th>
  455. <th>合格数</th>
  456. <th>不合格数</th>
  457. </tr>
  458. </thead>
  459. <tbody id="rank-one">
  460. </tbody>
  461. </table>
  462. </div>
  463. <div class="table-responsive" style="width: 30%;float: left;padding-left: 5em">
  464. <table class="table table-hover dashboard-task-infos">
  465. <thead>
  466. <tr style="border-bottom:3px solid black;">
  467. <th>姓名(工号)</th>
  468. <th>合格数</th>
  469. <th>不合格数</th>
  470. </tr>
  471. </thead>
  472. <tbody id="rank-two">
  473. </tbody>
  474. </table>
  475. </div>
  476. <div class="table-responsive" style="width: 30%;float: right">
  477. <table class="table table-hover dashboard-task-infos">
  478. <thead>
  479. <tr style="border-bottom:3px solid black;">
  480. <th>姓名(工号)</th>
  481. <th>合格数</th>
  482. <th>不合格数</th>
  483. </tr>
  484. </thead>
  485. <tbody id="rank-three">
  486. </tbody>
  487. </table>
  488. </div>
  489. </div>
  490. </div>
  491. </div> -->
  492. <section>
  493. <div class="row" style-height="50-8">
  494. <div id="graph-1"></div>
  495. </div>
  496. <div class="row " style="height: 10em"></div>
  497. <div class="row" style-height="30-2">
  498. <div id="graph-2"></div>
  499. </div>
  500. </section>
  501. <!-- Jquery Core Js -->
  502. <script src="plugins/jquery/jquery.min.js"></script>
  503. <!-- Bootstrap Core Js -->
  504. <script src="plugins/bootstrap/js/bootstrap.js"></script>
  505. <!-- Select Plugin Js -->
  506. <script src="plugins/bootstrap-select/js/bootstrap-select.js"></script>
  507. <!-- Slimscroll Plugin Js -->
  508. <script src="plugins/jquery-slimscroll/jquery.slimscroll.js"></script>
  509. <!-- Waves Effect Plugin Js -->
  510. <script src="plugins/node-waves/waves.js"></script>
  511. <!-- Jquery CountTo Plugin Js -->
  512. <script src="plugins/jquery-countto/jquery.countTo.js"></script>
  513. <!-- Morris Plugin Js -->
  514. <script src="plugins/raphael/raphael.min.js"></script>
  515. <script src="plugins/morrisjs/morris.js"></script>
  516. <!-- ChartJs -->
  517. <script src="plugins/chartjs/Chart.bundle.js"></script>
  518. <!-- Flot Charts Plugin Js -->
  519. <script src="plugins/flot-charts/jquery.flot.js"></script>
  520. <script src="plugins/flot-charts/jquery.flot.resize.js"></script>
  521. <script src="plugins/flot-charts/jquery.flot.pie.js"></script>
  522. <script src="plugins/flot-charts/jquery.flot.categories.js"></script>
  523. <script src="plugins/flot-charts/jquery.flot.time.js"></script>
  524. <!-- Sparkline Chart Plugin Js -->
  525. <script src="plugins/jquery-sparkline/jquery.sparkline.js"></script>
  526. <!-- Custom Js -->
  527. <script src="js/admin.js"></script>
  528. <!--<script src="js/pages/index.js"></script>-->
  529. <!-- Demo Js -->
  530. <script src="js/demo.js"></script>
  531. <script src="js/basic.js"></script>
  532. <script>
  533. var timeday=new Array("今日" ,"昨日" ,"本周" ,"本月");
  534. function getSpotHtml(htmlbody, i) {
  535. htmlbody += "<tr>";
  536. htmlbody += `<tr>
  537. <td>${timeday[i]}</td>
  538. <td>${hispass[i]}</td>
  539. <td>${hisfail[i]}</td>
  540. <td>${hisrate[i]}</td>
  541. </tr>`;
  542. htmlbody += "</tr>";
  543. return htmlbody;
  544. }
  545. /* function getSpotHtml(htmlbody, one_person, i) {
  546. htmlbody += "<tr>";
  547. htmlbody += `<tr>
  548. <td>${timeday[i]}</td>
  549. <td>${hispass[i]}</td>
  550. <td>${hisfail[i]}</td>
  551. <td>${hisrate[i]}</td>
  552. </tr>`;
  553. htmlbody += "</tr>";
  554. return htmlbody;
  555. }*/
  556. function showEachSpot() {
  557. var htmlbody = "", one_person = "";
  558. var i = 0;
  559. var triGap = 4;
  560. htmlbody = "";
  561. for (i = 0; i < triGap; i++) {
  562. htmlbody = getSpotHtml(htmlbody, i);
  563. }
  564. $("#rank-one").html(htmlbody);
  565. console.log(htmlbody);
  566. }
  567. /* function showEachSpot() {
  568. var htmlbody = "", one_person = "";
  569. var i = 0;
  570. var triGap = Math.floor(sID.length / 3) + 1;
  571. var remain = sID.length - triGap * 2;
  572. htmlbody = "";
  573. for (i = 0; i < triGap; i++) {
  574. one_person = namedata[i];
  575. htmlbody = getSpotHtml(htmlbody, one_person, i);
  576. }
  577. $("#rank-one").html(htmlbody);
  578. htmlbody = "";
  579. for (i = 0; i < triGap; i++) {
  580. one_person = namedata[i + triGap];
  581. htmlbody = getSpotHtml(htmlbody, one_person, i + triGap);
  582. }
  583. console.log(htmlbody);
  584. $("#rank-two").html(htmlbody);
  585. htmlbody = "";
  586. for (i = 0; i < remain; i++) {
  587. one_person = namedata[i + triGap * 2];
  588. htmlbody = getSpotHtml(htmlbody, one_person, i + triGap * 2);
  589. }
  590. $("#rank-three").html(htmlbody);
  591. }*/
  592. var thisPageFlow = 1;
  593. function showChart() {
  594. var data = [];
  595. var ratedata = [];
  596. var stackmax = 0;
  597. var failmax = 0;
  598. var passdata=[];
  599. var faildata=[];
  600. for (i = 0; i < passNumber.length; i++) {
  601. if (stackmax < stackeverynum[i]) {
  602. stackmax = stackeverynum[i];
  603. }
  604. if (failmax < failrate[i]) {
  605. failmax = failrate[i];
  606. }
  607. data.push(stackeverynum[i]);
  608. ratedata.push(Math.floor(failrate[i]));
  609. passdata.push(passNumber[i]);
  610. faildata.push(failNumber[i])
  611. }
  612. showEachSpot();
  613. stackmax = Math.max(stackmax, 5);
  614. failmax = Math.max(failmax, 5);
  615. stackAndFailChart = Highcharts.chart('graph-1', {
  616. chart: {
  617. zoomType: 'xy',
  618. height: (4 / 16 * 100) + '%' // 16:9 ratio
  619. },
  620. title: {
  621. text: '各工位今日产能'
  622. },
  623. credits: {
  624. enabled: false // 禁用版权信息
  625. },
  626. exporting: {
  627. enabled: false
  628. },
  629. xAxis: [{
  630. categories: namedata,
  631. crosshair: true,
  632. title: {
  633. text: '员工',
  634. style: {
  635. fontSize: '1.5em'
  636. }
  637. },
  638. labels: {
  639. style: {
  640. fontSize: '1.5em'
  641. }
  642. }
  643. }],
  644. yAxis: [{ // Primary yAxis
  645. labels: {
  646. format: '{value}',
  647. style: {
  648. color: Highcharts.getOptions().colors[0],
  649. fontSize: '1.5em'
  650. }
  651. },
  652. min: 0,
  653. max: 10000,
  654. title: {
  655. style: {
  656. color: Highcharts.getOptions().colors[0],
  657. fontSize: '1em'
  658. }
  659. }
  660. },
  661. ],
  662. tooltip: {
  663. shared: true
  664. },
  665. legend: {
  666. layout: 'vertical',
  667. align: 'right',
  668. x: -100,
  669. verticalAlign: 'top',
  670. y: 0,
  671. floating: true,
  672. backgroundColor: (Highcharts.theme && Highcharts.theme.legendBackgroundColor) || '#FFFFFF'
  673. },
  674. series: [{
  675. name: '良品数',
  676. type: 'column',
  677. data: passdata,
  678. }, {
  679. name: '不良品数',
  680. type: 'column',
  681. data: faildata,
  682. },
  683. {
  684. name: '堆积数',
  685. type: 'column',
  686. data: data,
  687. },]
  688. });
  689. FailChart = Highcharts.chart('graph-2', {
  690. chart: {
  691. height: (4 / 16 * 100) + '%' // 16:9 ratio
  692. },
  693. title: {
  694. text: '各工位今日不良率'
  695. },
  696. credits: {
  697. enabled: false // 禁用版权信息
  698. },
  699. exporting: {
  700. enabled: false
  701. },
  702. xAxis: [{
  703. categories: namedata,
  704. crosshair: true,
  705. title: {
  706. text: '员工',
  707. style: {
  708. fontSize: '1.5em'
  709. }
  710. },
  711. labels: {
  712. style: {
  713. fontSize: '1.5em'
  714. }
  715. }
  716. }],
  717. yAxis: [ { // Secondary yAxis
  718. title: {
  719. text: '不良率',
  720. style: {
  721. color: 'red',
  722. fontSize: '1em'
  723. }
  724. },
  725. min: 0,
  726. max: 1.5 * failmax,
  727. labels: {
  728. formatter: function () {
  729. return Math.floor(this.value) + "%";
  730. },
  731. style: {
  732. color: 'red',
  733. fontSize: '20px'
  734. }
  735. },
  736. }],
  737. tooltip: {
  738. shared: true
  739. },
  740. legend: {
  741. layout: 'vertical',
  742. align: 'right',
  743. x: -120,
  744. verticalAlign: 'top',
  745. y: 0,
  746. floating: true,
  747. backgroundColor: (Highcharts.theme && Highcharts.theme.legendBackgroundColor) || '#FFFFFF'
  748. },
  749. series: [{
  750. name: '不良率',
  751. type: 'spline',
  752. data: ratedata,
  753. color: 'red',
  754. tooltip: {
  755. valueSuffix: '%'
  756. }
  757. }]
  758. });
  759. }
  760. function updateChart() {
  761. var data = [];
  762. var ratedata = [];
  763. var stackmax = 0;
  764. var failmax = 0;
  765. var passdata=[];
  766. var faildata=[];
  767. for (i = 0; i < passNumber.length; i++) {
  768. if (stackmax < stackeverynum[i]) {
  769. stackmax = stackeverynum[i];
  770. }
  771. if (failmax < failrate[i]) {
  772. failmax = failrate[i];
  773. }
  774. data.push(stackeverynum[i]);
  775. ratedata.push(Math.floor(failrate[i]));
  776. passdata.push(passNumber[i]);
  777. faildata.push(failNumber[i])
  778. }
  779. stackmax = Math.max(stackmax, 5);
  780. failmax = Math.max(failmax, 5);
  781. // https://api.hcharts.cn/highcharts#Series.addPoint;
  782. stackAndFailChart.series[0].setData(passdata);
  783. stackAndFailChart.series[1].setData(faildata);
  784. stackAndFailChart.series[2].setData(data);
  785. FailChart.series[0].setData(ratedata);
  786. showEachSpot();
  787. }
  788. var stackAndFailChart = null;
  789. var FailChart = null;
  790. $(document).ready(on_document_load);
  791. window.onresize = resizeAll;
  792. function resizeAll() {
  793. $('[style-height="10"]').height(window.innerHeight / 10);
  794. $('[style-height="20"]').each(function(one,items){$(items).height(window.innerHeight / 5)});
  795. $('[style-height="30"]').each(function(one,items){$(items).height(window.innerHeight * 0.4)});
  796. $('[style-height="40"]').height(window.innerHeight *0.4);
  797. $('[style-height="30-8"]').height(window.innerHeight * 0.4 - 220);
  798. $('[style-height="30-1"]').each(function(one,items){$(items).height(window.innerHeight * 0.3)});
  799. $('[style-height="30-2"]').each(function(one,items){$(items).height(window.innerHeight * 0.2)});
  800. var graph = $("#graph-1");
  801. graph.width(window.innerWidth - 35);
  802. graph.height(window.innerHeight / 3.333);
  803. if (graph.highcharts !== undefined) {
  804. graph.highcharts().reflow();
  805. }
  806. var graph = $("#graph-2");
  807. graph.width(window.innerWidth - 35);
  808. graph.height(window.innerHeight / 3.333);
  809. if (graph.highcharts !== undefined) {
  810. graph.highcharts().reflow();
  811. }
  812. }
  813. setInterval(function () {
  814. resizeAll();
  815. }, 5000);
  816. resizeAll();
  817. //startClock();
  818. </script>
  819. </body>
  820. </html>
  821. <!---
  822. ### SVR_BASE 类似 "http://127.0.0.1:8803" 实际上线之后是确定值,写死在HTML里的JS里面
  823. ### 各个拉实时产量数据接口地址
  824. SVR_BASE + "/server/fcWorkRaw/allFlows"
  825. ### 单个拉内,所有工位实时产量数据接口地址 e.g. 拉线ID = 2
  826. SVR_BASE + "/server/fcWorkRaw/allSpots" + "?" + "flowId=2"
  827. ### 员工上班记录API e.g. 拉线ID = 2 工位顺序 = 1 员工ID = 33404
  828. SVR_BASE + "/server/fcWorkStartend/goOnline" + "?" + "flowId=2&sequence=1&workerId=33404"
  829. ### 查询已上班员工 e.g. 拉线ID = 2
  830. SVR_BASE + "/server/fcWorkRaw/getAll" + "?" + "flowId=2"
  831. -->