Нет описания

CallTime.html 5.2KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="UTF-8">
  5. <title>话务日报</title>
  6. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  7. <script src="../Script/Common/huayi.load.js"></script>
  8. <script src="../Script/Common/huayi.config.js"></script>
  9. <link rel="stylesheet" href="../js/zTree/zTreeStyle.css" />
  10. <link href="../css/WorkOrder/Search.css" rel="stylesheet">
  11. <link href="../css/init.css" rel="stylesheet" />
  12. <script src="../css/laydate/laydate.js"></script>
  13. <style>
  14. .hwbb thead tr td {
  15. background: #00a1cb;
  16. color: #fff;
  17. font-size: 14px;
  18. }
  19. #thead thead th{
  20. background: #00a0cd;
  21. color: #fff;
  22. }
  23. table thead, tbody tr {
  24. display:table;
  25. width:100%;
  26. table-layout:fixed;
  27. }
  28. .table{
  29. margin-bottom: 0;
  30. }
  31. </style>
  32. </head>
  33. <body class="gray-bg">
  34. <div class="wrapper wrapper-content animated fadeInRight">
  35. <div class="daoHang clearfix">
  36. <div class="dhLeft">
  37. <sapn><i class="syIcon"></i>位置:
  38. <a href="javaScript:;" id="ReIndex">首页</a>&gt;
  39. <a href="javaScript:;">报表管理</a>&gt;
  40. <a href="" class="nowPosition">话务日报</a>
  41. </sapn>
  42. </div>
  43. <div class="dhRight"><a href="" title="刷新"><i class="fa fa-refresh"></i></a></div>
  44. </div>
  45. <div class="Content_box">
  46. <!--待处理/-->
  47. <div class="complain Shows">
  48. <div class="toolBar clearfix">
  49. <div class="toolRight">
  50. 开始时间:
  51. <input class="photo x-color inputs laydate-icon" type="text" id="startTime" autocomplete="off" /> 结束时间:
  52. <input class="photo x-color inputs laydate-icon" type="text" id="endTime" autocomplete="off" />
  53. <a class="btns db">搜索</a>
  54. <a class="btns dbexecl">导出Execl</a>
  55. </div>
  56. </div>
  57. <div style="width: 100%;padding: 10px;">
  58. <div class="table-head">
  59. <table id="thead" class="table table-hover table-striped table-bordered table-condensed">
  60. <colgroup>
  61. <col style="width: 80px;"/>
  62. <col/>
  63. </colgroup>
  64. <thead>
  65. <tr>
  66. </tr>
  67. </thead>
  68. </table>
  69. </div>
  70. <div class="table-body">
  71. <table class="thTable hwbb table table-hover table-striped table-bordered table-condensed">
  72. <colgroup>
  73. <col style="width: 80px;"/>
  74. <col/>
  75. </colgroup>
  76. <tbody>
  77. </tbody>
  78. </table>
  79. </div>
  80. </div>
  81. </div>
  82. </div>
  83. </div>
  84. <script>
  85. $(document).ready(function(){
  86. laydate.skin('blue');
  87. laydate({
  88. elem: '#startTime',
  89. event: 'focus',
  90. istime: true,
  91. format: 'YYYY-MM-DD hh:mm:ss'
  92. });
  93. laydate({
  94. elem: '#endTime',
  95. event: 'focus',
  96. istime: true,
  97. format: 'YYYY-MM-DD hh:mm:ss'
  98. });
  99. $('.db').click(function () {
  100. GetDataList();
  101. })
  102. //导出
  103. $('.dbexecl').click(function () {
  104. dcexcel(this);
  105. })
  106. GetColumnList();
  107. GetDataList();
  108. })
  109. //加载表头
  110. function GetColumnList() {
  111. $("#thead thead tr").html('');
  112. /*请求后台*/
  113. $.ajax({
  114. type: "get",
  115. url: huayi.config.callcenter_url + "/TotalTel/GetColumnList",
  116. dataType: 'json',
  117. async: true,
  118. data: {
  119. token: $.cookie("token")
  120. },
  121. success: function(data) {
  122. /*验证请求*/
  123. if(data.state == "success") {
  124. var content = data.data;
  125. for(var i = 0; i < content.length; i++) {
  126. $("<th>" + content[i] + "</th>").appendTo($("#thead thead tr"));
  127. }
  128. }
  129. }
  130. });
  131. }
  132. //加载数据
  133. function GetDataList() {
  134. $(".hwbb tbody").html('');
  135. /*请求后台*/
  136. $.ajax({
  137. type: "get",
  138. url: huayi.config.callcenter_url + "/TotalTel/GetDataList",
  139. dataType: 'json',
  140. async: true,
  141. data: {
  142. stime: $("#startTime").val(),
  143. etime: $("#endTime").val(),
  144. token: $.cookie("token"),
  145. },
  146. success: function(data) {
  147. /*验证请求*/
  148. if(data.state == "success") {
  149. var content = data.rows;
  150. $(".tbody").html("");
  151. for(var i = 0; i < content.length; i++) {
  152. $("<tr><td>" + content[i].时间 + "</td><td>" + content[i].电话呼入次数 + "</td><td>"
  153. + content[i].电话呼出次数 + "</td><td>" + content[i].正常接听次数 + "</td><td>"
  154. + content[i].未接通次数 + "</td><td>" + content[i].主动放弃次数 + "</td><td>"
  155. + content[i].电话骚扰次数 + "</td><td>" + content[i].平均呼入时间 + "</td><td>"
  156. + content[i].峰值排队人数 + "</td><td>"+ content[i].正常呼出接听次数 + "</td></tr>").appendTo(".hwbb tbody");
  157. }
  158. }
  159. }
  160. });
  161. }
  162. function dcexcel(obj) {
  163. var url = huayi.config.callcenter_url + "/TotalTel/ExptList?token=" + $.cookie("token");
  164. url += "&stime=" + $("#startTime").val() + "&etime=" + $("#endTime").val() + "";
  165. obj.href = url;
  166. }
  167. </script>
  168. </body>
  169. </html>