| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178 |
- <!DOCTYPE html>
- <html>
- <head>
- <meta charset="UTF-8">
- <title>话务受理日周月报表</title>
- <meta name="viewport" content="width=device-width, initial-scale=1.0">
- <link href="../css/init.css" rel="stylesheet" />
- <link href="../css/Table/table1.css" rel="stylesheet" />
- <script src="../Script/Common/huayi.load.js"></script>
- <script src="../Script/Common/huayi.config.js"></script>
- <script src="../My97DatePicker/WdatePicker.js"></script>
- <script src="../css/laydate/laydate.js"></script>
- <style>
- body {
- font-family: "微软雅黑";
- font-size: 14px;
- }
- ul li {
- list-style: none;
- float: left;
- }
- .fr {
- float: right;
- }
- /*标头*/
- .th-box {
- width: 100%;
- padding: 5px;
- border-bottom: 1px solid #e7eaec;
- }
- .th-bar {
- height: 40px;
- }
- #list thead tr th{
- background: #01a1cb;
- color: #fff;
- }
- </style>
- </head>
- <body class="gray-bg">
- <div class="wrapper wrapper-content animated fadeInRight">
- <div class="daoHang clearfix">
- <div class="dhLeft">
- <sapn><i class="syIcon"></i>位置:<a href="javaScript:;" id="ReIndex">首页</a>><a href="javaScript:;">报表管理</a>><a href="" class="nowPosition">话务受理日周月报表</a></sapn>
- </div>
- <div class="dhRight">
- <a href="" title="刷新"><i class="fa fa-refresh"></i></a>
- </div>
- </div>
- <div class="th-box">
- <div class="th-bar">
- <!--<a class="sc_btn btn-info" id="moves">批量删除</a>-->
- <div class="seach-box fr">
- <ul>
- <li>开始时间:<input id="start" class="photo x-color laydate-icon" type="text" /></li>
- <li>结束时间:<input id="end" class="photo x-color laydate-icon" type="text" /></li>
- <li>
- 时间类型:
- <select style="width: 100px;" class="select_ dataType">
- <option value="0" selected="selected">日</option>
- <option value="1">周</option>
- <option value="2">月</option>
- </select>
- </li>
- <li>
- <button class="btns search">查询</button>
- <a class="btns export">导出</a>
- </li>
- </ul>
- </div>
- </div>
- </div>
- <div style="width: 100%;padding: 10px;">
- <table id="list" class="table table-hover table-striped table-bordered table-condensed">
- <thead>
- <tr>
-
- </tr>
- </thead>
- <tbody>
-
- </tbody>
- </table>
- <!--高级搜索框-->
- </div>
- </div>
-
- <script>
- $(document).ready(function () {
- var start=$('#start').val();//开始时间
- var end=$('#end').val();//结束时间
- var usercode;//工号
- var type=$('.dataType').val();//时间类型
- laydate.skin('blue');
- laydate({
- elem: '#start',
- event: 'focus'
- });
- laydate({
- elem: '#end',
- event: 'focus'
- });
- //表头
- $.ajax({
- type:"get",
- url:huayi.config.callcenter_url +"TelWOReport/GetColumnList",
- async:true,
- dataType:'json',
- data:{
- token:$.cookie("token")
- },
- success:function(data){
- var con=data.data;
- if(data.state.toLowerCase()=='success'){
- $(con).each(function(i,n){
- $('<th>'+n +'</th>').appendTo('#list thead tr')
- })
- }
- }
- });
- tableAjax(start,end,type)
- //表内数据
- function tableAjax(start,end,type){
- $('#list tbody').html('');
- $.ajax({
- type:"get",
- url:huayi.config.callcenter_url +"TelWOReport/GetTrafficReport",
- async:true,
- dataType:'json',
- data:{
- token:$.cookie("token"),
- btime:start,
- etime:end,
- type:type
- // usercode:usercode
- },
- success:function(data){
- var con=data.data;
- if(data.state.toLowerCase()=='success'){
- $(con).each(function(i,n){
- $('<tr><td>' + n.日期 + '</td><td>' + n.接听来电 + '</td><td>' + n.有效来电 + '</td><td>' + n.受理 + '</td><td>' + n.在线办结 + '</td><td>' + n.转派工单 + '</td><td>' + n.办结 + '</td></tr>').appendTo('#list tbody')
- })
- }
- }
- });
- }
- $('.search').click(function(){
- start=$('#start').val();
- end=$('#end').val();
- type=$('.dataType').val();
- tableAjax(start,end,type)
- })
- $('.export').click(function(){
- dcexcel(this);
- })
- function dcexcel(obj) {
- var url = huayi.config.callcenter_url + "TelWOReport/ExptList?token=" + $.cookie("token");
- url += "&btime=" + $("#start").val() + "&etime=" + $("#end").val()+ "&type=" + $(".dataType").val();
- obj.href = url;
- }
-
- })
-
-
- </script>
- </body>
- </html>
|