| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440 |
- <!DOCTYPE html>
- <html>
- <head>
- <meta charset="UTF-8">
- <title>报表统计</title>
- <meta name="viewport" content="width=device-width, initial-scale=1.0">
- <script src="../Script/Common/huayi.load.js"></script>
- <script src="../Script/Common/huayi.config.js"></script>
- <link href="../css/WorkOrder/Search.css" rel="stylesheet">
- <link href="../css/init.css" rel="stylesheet" />
- <link rel="stylesheet" href="../js/zTree/zTreeStyle.css" />
- <script src="../js/zTree/jquery.ztree.core.js"></script>
- <style>
- table td {
- word-break: break-all;
- word-wrap: break-word;
- }
-
- .Shows {
- display: block !important;
- }
-
- .complain {
- display: none;
- }
-
- .toolLeft input {
- width: 235px;
- }
-
- th {
- padding: 5px;
- text-align: center;
- }
-
- td {
- padding: 5px;
- }
-
- .Borders {
- border: 1px solid #d7d7d7;
- }
-
- .daoHang {
- margin-bottom: 15px;
- }
-
- .inpBox {
- border: 1px solid #e5e6e7;
- height: 32px;
- width: 200px;
- display: inline-block;
- position: relative;
- vertical-align: middle;
- }
-
- .inpBox .inps1 {
- width: 100%;
- height: 30px;
- outline: none;
- border: 0;
- border-image-width: 0;
- padding: 0;
- padding-left: 3px;
- }
-
- .xl {
- display: inline-block;
- background: url(../img/dropDown.png) no-repeat;
- height: 100%;
- background-position: center center;
- width: 20px;
- position: absolute;
- right: 0;
- top: 0px;
- background-color: #f7bc8b;
- cursor: pointer;
- }
-
- .xl:hover {
- background-color: #e6d523;
- }
-
- .addTree {
- background: #fff;
- position: absolute;
- width: 100%;
- border: 1px solid darkgrey;
- right: 0;
- top: 30px;
- display: none;
- height: 350px;
- overflow-y: auto;
- z-index: 10;
- text-align: center;
- }
-
- .addTree .list li:hover {
- background: #ebebeb;
- color: #717171;
- }
-
- .remark {
- max-width: 350px;
- }
-
- .Cleans {
- display: inline-block;
- width: 20px;
- position: absolute;
- right: 21px;
- top: 8px;
- display: none;
- }
- </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="Content_box">
- <div class="complain Shows">
- <div class="toolBar clearfix">
- <div class="toolLeft">
- 交办时间范围:
- <input type="text" autocomplete="off" class="laydate-icon" id="startTime" />-
- <input type="text" autocomplete="off" class="laydate-icon" id="endTime" /> 部门:
- <div class="inpBox">
- <input class="inps inps1">
- <input type="hidden" id="deptid" />
- <i class="Cleans fa fa-close"></i>
- <i class="xl xl_two"></i>
- <div class="addTree xlAdd_two">
- <ul id="deptTree" class="ztree"></ul>
- </div>
- </div>
- 工单号:
- <input class="photo x-color inputs" type="text" id="workid" />
- <button class="btns search_1">查询</button>
- <a class="btns" id="exportPublicSentiments">导出</a>
- </div>
- </div>
- <!--data-formatter="comprehensiveScores"-->
- <!--table1-->
- <div style="width: 100%;padding: 10px;">
- <table id="publicSATable" class="tables" data-row-style="rowStyle" data-query-params="queryParams" data-pagination="true">
- <thead>
- <tr>
- <th data-field="F_WorkOrderId" data-formatter="orderDetail" data-align="center">工单号</th>
- <th data-field="DeptName" data-align="center">部门</th>
- <th data-field="total" data-align="center">交办量</th>
- </tr>
- </thead>
- <tbody class="list"></tbody>
- </table>
- </div>
- </div>
- </div>
- </div>
- <!--<script src="../js/laydate/laydate.js"></script>-->
- <script src="../css/laydate/laydate.js"></script>
- <script>
- var exportParams;
- $(document).ready(function() {
- //开始时间
- laydate({
- elem: '#startTime',
- event: 'focus',
- istoday: true,
- format: 'YYYY-MM-DD', // 分隔符可以任意定义,该例子表示只显示年月
- });
- //结束时间
- laydate({
- elem: '#endTime',
- event: 'focus',
- istoday: true,
- format: 'YYYY-MM-DD', // 分隔符可以任意定义,该例子表示只显示年月
- });
- getTimes('#squeryTime')
- initTable();
- bindtree();
- });
- //表格
- function initTable() {
- //先销毁表格
- $('#publicSATable').bootstrapTable('destroy');
- //初始化表格,动态从服务器加载数据
- // $.ajax({
- // url: huayi.config.callcenter_url + 'WorkOrderReport/GetAssignInfotReport',
- // type: 'get',
- // data: {
- // start: $('#startTime').val(),
- // end: $('#endTime').val(),
- // deptid: $("#deptid").val(),
- // workorderid: $("#workid").val(),
- // token: $.cookie("token")
- // },
- // dataType: "json",
- // async: true,
- // success: function(returnValue) {
- // //异步获取数据
- // var resultData = returnValue.rows;
- // $('#publicSATable').bootstrapTable('load', resultData);
- // }
- // });
- // $('#publicSATable').bootstrapTable('destroy').bootstrapTable({
- // pagination: true, //启动分页
- // pageSize: 10, //每页显示的记录数
- // pageNumber: 1, //当前第几页
- // pageList: [10, 20, 50, 100], //记录数可选列表
- // });
- $("#publicSATable").bootstrapTable({
- method: "get", //使用get请求到服务器获取数据
- url: huayi.config.callcenter_url + "WorkOrderReport/GetAssignInfotReport", //获取数据的Servlet地址
- contentType: "application/x-www-form-urlencoded",
- striped: true, //表格显示条纹
- pagination: true, //启动分页
- pageSize: 10, //每页显示的记录数
- pageNumber: 1, //当前第几页
- pageList: [10, 20, 50, 100], //记录数可选列表
- search: false, //是否启用查询
- showColumns: false, //显示下拉框勾选要显示的列
- showRefresh: false, //显示刷新按钮
- sidePagination: "server", //表示服务端请求
- //设置为undefined可以获取pageNumber,pageSize,searchText,sortName,sortOrder
- //设置为limit可以获取limit, offset, search, sort, order
- queryParamsType: "undefined",
- queryParams: function queryParams(params) { //设置查询参数
- var param = {
- pageIndex: params.pageNumber,
- pageSize: params.pageSize,
- start: $('#startTime').val(),
- end: $('#endTime').val(),
- deptid: $("#deptid").val(),
- workorderid: $("#workid").val(),
- token: $.cookie("token")
- };
- exportParams = param
- return param;
- },
- onLoadSuccess: function(data) { //加载成功时执行
- // layer.msg("加载成功");
- //console.log(data);
- },
- onLoadError: function() { //加载失败时执行
- //layer.msg("加载数据失败", { time: 1500, icon: 2 });
- }
- });
- }
- //搜索
- $(".search_1").click(function() {
- initTable();
- });
- $(".inps").focus(function() {
- $(this).siblings(".addTree").css("display", "block");
- });
- $(".xl").click(function() {
- var xl = $(this).siblings(".addTree");
- if(xl.css("display") == "block") {
- xl.css("display", "none");
- } else {
- xl.css("display", "block");
- }
- });
- function getTimes(dom) {
- function p(s) {
- return s < 10 ? '0' + s : s;
- }
- var currentYear = new Date().getFullYear();
- var currentMonth = new Date().getMonth() + 1;
- var currentDate = new Date().getDate();
- var prevCurrentYear = 0;
- var prevCurrentMonth = 0;
- if(currentMonth == 1) {
- prevCurrentYear = currentYear - 1;
- prevCurrentMonth = 12;
- } else {
- prevCurrentYear = currentYear;
- prevCurrentMonth = currentMonth - 1;
- }
- let hh = new Date().getHours()
- let mf = new Date().getMinutes() < 10 ? '0' + new Date().getMinutes() : new Date().getMinutes()
- let ss = new Date().getSeconds() < 10 ? '0' + new Date().getSeconds() : new Date().getSeconds()
- var data = currentYear + "-" + p(currentMonth) + "-" + '01';
- var current = currentYear + "-" + p(currentMonth);
- $(dom).val(current)
- }
- function bindtree() {
- $.getJSON(
- huayi.config.callcenter_url + "Department/GetDeptList", {
- token: $.cookie("token")
- },
- function(result) {
- if(result.state.toLowerCase() == "success") {
- $.fn.zTree.init($("#deptTree"), setting, result.data);
- }
- }
- );
- }
- //获取所属部门
- var setting = {
- data: {
- key: {
- name: "F_DeptName",
- },
- simpleData: {
- enable: true,
- idKey: "F_DeptId",
- pIdKey: "F_PartentId",
- rootPId: 0,
- },
- },
- callback: {
- onClick: zTreeOnClick,
- },
- };
- function zTreeOnClick(event, treeId, treeNode) {
- $(".inps1").val(treeNode.F_DeptName);
- $("#deptid").val(treeNode.F_DeptId);
- $(".Cleans").show();
- $('.addTree').css('display', 'none');
- }
- $(".Cleans").click(function() {
- $(".inps1").val("");
- $("#deptid").val("");
- })
- //导出
- $('#exportPublicSentiments').click(function() {
- dcexcelDispath(this);
- });
- function dcexcelDispath(obj) {
- var url = huayi.config.callcenter_url + "WorkOrderReport/GetAssignInfotReport?token=" + $.cookie("token");
- url += "&start=" + $("#startTime").val() + "&end=" + $("#endTime").val() + "&workorderid=" + $("#workid").val() + "&deptid=" + $('#deptid').val() + "&isExport=true";
- obj.href = url;
- }
- function InformationScores(val, row) {
- return '<a onclick="btn_comprehensiveScores(\'' + row.deptid + '\',\'' + 0 + '\',\'' + 0 + '\')">' + val + '</a>'
- }
- //工单实时签收率
- function recoveryrateList(val, row) {
- return '<a onclick="btn_orderView(\'' + row.deptid + '\',\'' + 1 + '\')">' + val + '</a>'
- }
- //实时退单率
- function overtimerateList(val, row) {
- return '<a onclick="btn_orderView(\'' + row.deptid + '\',\'' + 2 + '\')">' + val + '</a>'
- }
- //重复退单率
- function refundrateList(val, row) {
- return '<a onclick="btn_orderView(\'' + row.deptid + '\',\'' + 3 + '\')">' + val + '</a>'
- }
- //按时办结率
- function finishontimerateList(val, row) {
- return '<a onclick="btn_orderView(\'' + row.deptid + '\',\'' + 4 + '\')">' + val + '</a>'
- }
- //扫描件上传速率
- function scanningList(val, row) {
- return '<a onclick="btn_orderView(\'' + row.deptid + '\',\'' + 5 + '\')">' + val + '</a>'
- }
- //办件数量
- function handlingList(val, row) {
- return '<a onclick="btn_orderView(\'' + row.deptid + '\',\'' + 6 + '\')">' + val + '</a>'
- }
- function ExcellentScores(val, row) {
- return '<a onclick="btn_comprehensiveScores(\'' + row.deptid + '\',\'' + 0 + '\',\'' + 1 + '\')">' + val + '</a>'
- }
- function ImmediateScores(val, row) {
- return '<a onclick="btn_comprehensiveScores(\'' + row.deptid + '\',\'' + 0 + '\',\'' + 2 + '\')">' + val + '</a>'
- }
- function superviseScores(val, row) {
- return '<a onclick="btn_comprehensiveScores(\'' + row.deptid + '\',\'' + 1 + '\')">' + val + '</a>'
- }
- function btn_orderView(deptid, tmptype) {
- var time = $("#squeryTime").val()
- layer.open({
- type: 2,
- content: "./workListReport.html?deptid=" + deptid + '&tmptype=' + tmptype + '&dateT=' + time, //iframe的url,no代表不显示滚动条
- title: '工单列表',
- area: ['100%', '100%'], //宽高
- });
- }
- function btn_comprehensiveScores(id, state, type) {
- var time = $("#squeryTime").val()
- layer.open({
- type: 2,
- content: "../YeWu/changeComprehensiveScoresGongYi.html?id=" + id + '&state=' + state + '&dateT=' + time + '&type=' + type, //iframe的url,no代表不显示滚动条
- title: '综合考评分数',
- area: ['80%', '50%'], //宽高
- });
- }
- function orderDetail(val, row) {
- if(row.F_WorkOrderId) {
- return '<a onclick="ckxq(\'' + row.F_WorkOrderId + '\')">' + row.F_WorkOrderId + '</a>'
- }
- }
- function ckxq(str) {
- layer.open({
- type: 2,
- content: "../CommonHtml/WorkDatil.html?wid=" + str, //iframe的url,no代表不显示滚动条
- title: '工单详情',
- area: ['87%', '80%'], //宽高
- });
- }
- </script>
- </body>
- </html>
|