高新区管委会,以5.0标准版为基准,从双汇项目拷贝

zhiJian.html 7.4KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="utf-8">
  5. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  6. <title>质检数据报表</title>
  7. <!--[if lt IE 9]>
  8. <meta http-equiv="refresh" content="0;ie.html" />
  9. <![endif]-->
  10. <script src="Script/Common/huayi.load.js"></script>
  11. <script src="Script/Common/huayi.config.js"></script>
  12. <link rel="stylesheet" href="js/select2/css/select2.min.css" />
  13. <link rel="stylesheet" href="./css/init.css" />
  14. <style>
  15. .zxtable {
  16. font-size: 12px;
  17. }
  18. .zxt-top {
  19. background: #f3f3f4;
  20. height: 60px;
  21. padding: 10px 20px;
  22. }
  23. .topCon {
  24. float: right;
  25. margin-right: 45px;
  26. }
  27. .zxt-content {
  28. width: 95%;
  29. margin: 0 auto;
  30. }
  31. .zxt-table {
  32. overflow-x: auto;
  33. }
  34. .zxt-table table {
  35. font-size: 12px;
  36. margin-top: 20px;
  37. width: 100%;
  38. max-width: 100%;
  39. }
  40. .zxt-table table thead tr td {
  41. background: #1ab394;
  42. color: #fff;
  43. }
  44. </style>
  45. </head>
  46. <body class="gray-bg" style="background: #fefefe;">
  47. <div class="zxtable">
  48. <div class="daoHang clearfix">
  49. <div class="dhLeft">
  50. <sapn><i class="syIcon"></i>位置:<a id="ReIndex" href="javaScript:;">首页</a>&gt;<a href="javaScript:;">报表分析</a>&gt;<a href="javaScript:;">员工考核分析</a>&gt;<a href="" class="nowPosition">质检数据报表</a></sapn>
  51. </div>
  52. <div class="dhRight">
  53. <a href="#" title="刷新"><i class="fa fa-refresh"></i></a>
  54. </div>
  55. </div>
  56. <div class="zxt-top clearfix">
  57. <div class="topCon">
  58. <!--部门:
  59. <select name="" id="bumen">
  60. </select>
  61. 开始时间:
  62. <input type="text" class="laydate-icon" id="startTime" /> 结束时间:
  63. <input type="text" class="laydate-icon" id="endTime" />
  64. <button class="btns sear">搜索</button>-->
  65. <!--<button class="btn daochu ">导出Excel</button>-->
  66. <div class="form-inline th-bar clearfix">
  67. <div class="time-box form-group" >
  68. <i class="tub fa fa-calendar"></i>
  69. <input class="form-control" type="text" id="startTime" placeholder="请选择起止时间" style="width: 228px;">
  70. </div>
  71. <!--<div class="time-box form-group" >
  72. <select name="" id="bumen" class="form-control">
  73. </select>
  74. </div>-->
  75. <div class="form-group tool_bars pull-right">
  76. <button class="btns sear">搜索</button>
  77. <!--<a class="btns export">导出</a>-->
  78. </div>
  79. </div>
  80. </div>
  81. </div>
  82. <div class="zxt-content">
  83. <div class="zxt-table">
  84. <table class="table table-bordered text-center table-hover zjTable">
  85. <thead>
  86. <tr class="one"></tr>
  87. <tr class="two"></tr>
  88. <tr class="three"></tr>
  89. <tr class="four"></tr>
  90. </thead>
  91. <tbody class="tbody">
  92. </table>
  93. </div>
  94. </div>
  95. </div>
  96. <script src="./js/jquery.min.js?v=2.1.4"></script>
  97. <script src="./js/bootstrap.min.js?v=3.3.6"></script>
  98. <script src="./js/jquery.cookie.js"></script>
  99. <script src="./js/laydate/laydate.js"></script>
  100. <script src="./js/select2/js/select2.min.js"></script>
  101. <script>
  102. $(function() {
  103. var token = $.cookie("token");
  104. //日期
  105. laydate.render({
  106. elem: '#startTime',
  107. range: '~',
  108. theme: '#1ab394',
  109. });
  110. var expor;
  111. tbodyAjax();
  112. //点击搜索事件
  113. $('.sear').click(function() {
  114. tbodyAjax();
  115. })
  116. //按enter搜索
  117. document.onkeydown = function (e) { // 回车提交表单
  118. var theEvent = window.event || e;
  119. var code = theEvent.keyCode || theEvent.which || theEvent.charCode;
  120. if (code == 13) {
  121. tbodyAjax();
  122. }
  123. }
  124. //表头
  125. $.ajax({
  126. type: "get",
  127. dataType: "json",
  128. url: huayi.config.callcenter_url+"QCResult/GetColumnList?expor",
  129. async: true,
  130. data: {
  131. token:token,
  132. isext:expor
  133. },
  134. success: function(data) {
  135. var content = data.data;
  136. for(var i = 0; i < content.length; i++) {
  137. $('<td rowspan="' + content[i].Rowspan + '" colspan="' + content[i].Colspan + '">' + content[i].Qcname + '</td>').appendTo('.zjTable thead tr.one')
  138. if(content[i].Qcscore !== null) {
  139. $('<td>' + content[i].Qcscore + '</td>').appendTo('.zjTable thead tr.four')
  140. }
  141. if(content[i].Qclist !== null) {
  142. var twoCon = content[i].Qclist;
  143. //console.log(twoCon)
  144. for(var j = 0; j < twoCon.length; j++) {
  145. //console.log(twoCon[j].Qcname)
  146. $('<td rowspan="' + twoCon[j].Rowspan + '" colspan="' + twoCon[j].Colspan + '">' + twoCon[j].Qcname + '</td>').appendTo('.zjTable thead tr.two')
  147. if(twoCon[j].Qclist !== null) {
  148. var threeCon = twoCon[j].Qclist;
  149. //console.log(threeCon);
  150. for(var g = 0; g < threeCon.length; g++) {
  151. $('<td rowspan="' + threeCon[g].Rowspan + '" colspan="' + threeCon[g].Colspan + '">' + threeCon[g].Qcname + '</td>').appendTo('.zjTable thead tr.three')
  152. $('<td rowspan="' + threeCon[g].Rowspan + '" colspan="' + threeCon[g].Colspan + '">' + threeCon[g].Qcscore + '</td>').appendTo('.zjTable thead tr.four')
  153. }
  154. }
  155. }
  156. }
  157. }
  158. }
  159. });
  160. //表格数据
  161. function tbodyAjax() {
  162. var loadindex;
  163. $.ajax({
  164. type: "get",
  165. dataType: "json",
  166. url: huayi.config.callcenter_url+"QCResult/GetDataList?expor",
  167. beforeSend:function(){
  168. loadindex = layer.load()
  169. },
  170. async: true,
  171. data: {
  172. token:token,
  173. stime: $('#startTime').val() && $('#startTime').val().split(' ~ ')[0],
  174. endtime: $('#startTime').val() && $('#startTime').val().split(' ~ ')[1],
  175. //dpt:$('#bumen').val(),
  176. isext: expor
  177. },
  178. success: function(result) {
  179. var tbodyCon = result.data;
  180. $('.zjTable tbody').html('');
  181. for(var i = 0; i < tbodyCon.length; i++) {
  182. $('<tr><td>' + tbodyCon[i].QCName + '</td><td>' + tbodyCon[i].UserName + '</td><td>' + tbodyCon[i].UserCode + '</td><td>' + tbodyCon[i].ZJCount + '</td><td>'
  183. + tbodyCon[i].Q12 + '</td><td>' + tbodyCon[i].Q13 + '</td><td>' + tbodyCon[i].Q14 + '</td><td>' + tbodyCon[i].Q15 + '</td><td>' + tbodyCon[i].Q16 + '</td><td>'
  184. + tbodyCon[i].Q17 + '</td><td>' + tbodyCon[i].Q18 + '</td><td>' + tbodyCon[i].df0 + '</td><td>' + tbodyCon[i].Q19 + '</td><td>' + tbodyCon[i].Q20 + '</td><td>' + tbodyCon[i].Q21 + '</td><td>'
  185. + tbodyCon[i].Q22 + '</td><td>' + tbodyCon[i].Q23 + '</td><td>' + tbodyCon[i].Q24 + '</td><td>'+ tbodyCon[i].df1
  186. + '</td><td style="color:#e43926;font-weight: bold;">' + tbodyCon[i].AllScore + '</td></tr>').appendTo('.zjTable tbody')
  187. }
  188. }
  189. }).then(function(){layer.close(loadindex);});
  190. }
  191. // //部门下拉框
  192. //$("#bumen").select2({
  193. // width: 'resolve' ,
  194. // minimumResultsForSearch: -1,
  195. // ajax:{
  196. // type:"get",
  197. // url:huayi.config.callcenter_url+"Department/GetDeptList",
  198. // async:true,
  199. // dataType: "json",
  200. // data:function(params){
  201. // return{
  202. // token:token,
  203. // pid:params.id
  204. // }
  205. // },
  206. // processResults:function(data){
  207. // return{
  208. // results:data.data
  209. // }
  210. // },
  211. // cache: true
  212. // },
  213. // placeholder: "请选择部门",
  214. //});
  215. })
  216. </script>
  217. </body>
  218. </html>