| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565 |
- <!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/laydate/laydate.js"></script>
- <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: 200px;
- }
- 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_two {
- 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_two:hover {
- background-color: #e6d523;
- }
- .xlAdd_two {
- 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;
- }
- .xlAdd_two .list li:hover {
- background: #ebebeb;
- color: #717171;
- }
- /*树形下拉样式结束*/
- .Content_box .title {
- font-size: 24px;
- text-align: center;
- }
- .Content_box h5 {
- font-size: 16px;
- text-align: center;
- }
- .select {
- width: 200px;
- height: 32px;
- border: 1px solid rgb(229, 230, 231);
- }
- .footerDataStatistics {
- /* padding: 0 0 0 20px; */
- margin: 10px 0 0 10px;
- font-size: 18px;
- }
- .tables .th-inner {
- white-space: normal !important;
- }
- </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 class="photo x-color inputs laydate-icon" type="text" id="squeryTime" autocomplete="off" />
- 结束时间:
- <input class="photo x-color inputs laydate-icon" type="text" id="equeryTime" autocomplete="off" />
- 部门:
- <div class="inpBox">
- <input class="inps inps1">
- <input type="hidden" id="deptid" />
- <i class="xl xl_two"></i>
- <div class="addTree xlAdd_two">
- <ul id="deptTree" class="ztree"></ul>
- </div>
- </div>
- 来源:
- <select class="select" id="source"></select>
- <button class="btns search_1">查询</button>
- <a class="btns" id="exportPublicSentiments">导出</a>
- </div>
- </div>
- <div class="title" id="titleText">12345联动服务工作考核数据表</div>
- <div class="title">统计周期:<span class="statisticalPeriod"></span></div>
- <h5>一、县(市、区)联动单位</h5>
- <div style="width: 100%;padding: 10px;">
- <table id="workorderlist_1" class="tables" data-row-style="rowStyle" data-query-params="queryParams">
- </table>
- </div>
- <h5>二、市直机关联动单位一组</h5>
- <div style="width: 100%;padding: 10px;">
- <table id="workorderlist_2" class="tables" data-row-style="rowStyle" data-query-params="queryParams">
- </table>
- </div>
- <h5>三、市直机关联动单位二组</h5>
- <div style="width: 100%;padding: 10px;">
- <table id="workorderlist_3" class="tables" data-row-style="rowStyle" data-query-params="queryParams">
- </table>
- </div>
- <h5>四、公共事业企业联动单位</h5>
- <div style="width: 100%;padding: 10px;">
- <table id="workorderlist_4" class="tables" data-row-style="rowStyle" data-query-params="queryParams">
- </table>
- </div>
- <h5>总计</h5>
- <div style="width: 100%;padding: 10px;">
- <table id="workorderlist_5" class="tables" data-row-style="rowStyle" data-query-params="queryParams">
- </table>
- </div>
- <div class="footerDataStatistics">统计时段:00:00—23:59:59</div>
- </div>
- </div>
- </div>
- <script>
- var tableColumns = [
- { title: '序号', align: 'center',
- formatter: function(value, row, index) {
- return index+1
- }
- },
- { field: 'deptname', title: '联动单位', align: 'center'
-
- },
- { field: 'Undertakers', title: '承办件', align: 'center',
- formatter: function(value, row, index) {
- return handleOrderList(value, row, 0);
- }
- },
- { field: 'Undertakersrate', title: '承办率', align: 'center'},
- { field: 'Undertakersscore', title: '得分(5分)', align: 'center'},
- { field: 'signfor', title: '及时签收件', align: 'center',
- formatter: function(value, row, index) {
- return handleOrderList(value, row, 1);
- }
- },
- { field: 'oversignfor', title: '超时签收件 ', align: 'center',
- formatter: function(value, row, index) {
- return handleOrderList(value, row, 2);
- }
- },
- { field: 'signforrate', title: '及时签收率', align: 'center'},
- { field: 'signforscore', title: '得分(5分)', align: 'center'},
- { field: 'overdue', title: '按时反馈件', align: 'center',
- formatter: function(value, row, index) {
- return handleOrderList(value, row, 3);
- }
- },
- { field: 'overfeedback', title: '超时反馈件', align: 'center',
- formatter: function(value, row, index) {
- return handleOrderList(value, row, 4);
- }
- },
- { field: 'overduerate', title: '按时反馈率', align: 'center'},
- { field: 'overduescore', title: '得分(15分)', align: 'center'},
- { field: 'conclude', title: '办结件', align: 'center',
- formatter: function(value, row, index) {
- return handleOrderList(value, row, 5);
- }
- },
- { field: 'noconclude', title: '未办结件', align: 'center',
- formatter: function(value, row, index) {
- return handleOrderList(value, row, 6);
- }
- },
-
- { field: 'unsuccessfulrate', title: '办结率', align: 'center'},
- { field: 'unsuccessfulscore', title: '办结得分(10分)', align: 'center'},
- { field: 'one', title: '一次办结件', align: 'center',
- formatter: function(value, row, index) {
- return handleOrderList(value, row, 7);
- }
- },
- { field: 'noone', title: '非一次办结件', align: 'center',
- formatter: function(value, row, index) {
- return handleOrderList(value, row, 8);
- }
- },
- { field: 'onerate', title: '一次办结率', align: 'center'},
- { field: 'onescore', title: '得分(15分)', align: 'center'},
- { field: 'noexamine', title: '不计入考核件', align: 'center',
- formatter: function(value, row, index) {
- return handleOrderList(value, row, 9);
- }
- },
-
- { field: 'review', title: '评议件', align: 'center',
- formatter: function(value, row, index) {
- return handleOrderList(value, row, 10);
- }
- },
- { field: 'satisfied', title: '满意件', align: 'center',
- formatter: function(value, row, index) {
- return handleOrderList(value, row, 11);
- }
- },
- { field: 'nosatisfied', title: '不满意件', align: 'center',
- formatter: function(value, row, index) {
- return handleOrderList(value, row, 12);
- }
- },
- { field: 'satisfiedrates', title: '满意率', align: 'center'},
- { field: 'satisfiedscore', title: '得分(50分)', align: 'center'},
- { field: 'total', title: '总分', align: 'center'},
- { title: '排名', align: 'center',
- formatter: function(value, row, index) {
- return index+1
- }
- },
-
- ]
- var exportParams = {}
- var treeInputParam = {
- classInps:'.inps',
- classId:'#deptid',
- treeApi:'Department/GetDeptList',
- classAddTree:'.addTree',
- classXl:'.xl',
- treeId:'#deptTree',
- treeObj:{
- name:'F_DeptName',
- id:'F_DeptId',
- pid:'F_PartentId',
- onclick:zTreeOnClick
- }
- }
- var selectParam = {
- id:"#source",
- apiUrl:"Dictionary/GetDicValueListById",
- dataParam:{
- id:1
- }
- }
- $(document).ready(function () {
- laydate.render({
- elem: '#squeryTime',
- theme: '#00a1cb',
- type: 'datetime',
- });
- laydate.render({
- elem: '#equeryTime',
- theme: '#00a1cb',
- type: 'datetime',
- });
- initTable();
- bindtree();
- selectCommon(selectParam);
- });
- //搜索
- $(".search_1").click(function () {
- initTable();
- });
- //导出
- $('#exportPublicSentiments').click(function () {
- exportParams.isdc = true
- exportFileFun('DataAssessment/GetExamine',exportParams)
- });
- function handleOrderList(val,row,tab){
- if (row.deptname !=='合计'&&row.deptname !=='总计') {
- return '<div class="imgs" ><a class="" onclick="viewList(\'' + row.deptid + '\', \''+tab+'\')" >' + val +
- '</a></div>'
- }else{
- return val
- }
-
- }
- // 查看列表
- function viewList(deptid, tab) {
- console.log(deptid, tab)
- var deptid = encodeURIComponent(deptid)
- starttime = $("#squeryTime").val();
- endtime = $("#equeryTime").val();
- source = $("#source").val();
- source = encodeURIComponent(source);
- starttime = encodeURIComponent(starttime);
- if (endtime.length > 0 && endtime.length <= 10) {
- endtime = encodeURIComponent(endtime + " 23:59:59");
- } else {
- endtime = encodeURIComponent(endtime);
- }
-
- layer.open({
- type: 2,
- content: "./comhtml/reportOrderList.html?deptid=" + deptid + "&tab=" + tab +
- "&starttime=" + starttime + "&endtime=" + endtime+ "&source=" + source, //iframe的url,no代表不显示滚动条
- title: '考核统计分析列表',
- area: ['90%', '90%'], //宽高
- });
- }
- //表格
- function initTable() {
- var dataParams = {
- starttime: $('#squeryTime').val(),
- endtime: $('#equeryTime').val(),
- deptid: $("#deptid").val(),
- source: $("#source").val(),
- token: $.cookie("token")
- }
- exportParams = dataParams
- $.ajax({
- url: huayi.config.callcenter_url + 'DataAssessment/GetExamine',
- type: 'get',
- data: dataParams,
- dataType: "json",
- async: true,
- success: function (returnValue) {
- //异步获取数据
- //debugger;
- var resultData = returnValue.rows;
- var resultData_1 = []
- var resultData_2 = []
- var resultData_3 = []
- var resultData_4 = []
- var resultData_5 = []
- $(".statisticalPeriod").text(returnValue.strdate + " 至 " + returnValue.edate)
- $("#titleText").text("12345联动服务工作" + returnValue.month + "月份考核数据表")
- resultData.forEach(function (v, i) {
- if (v.category === 1) {
- resultData_1.push(v)
- } else if (v.category === 2) {
- resultData_2.push(v)
- } else if (v.category === 3) {
- resultData_3.push(v)
- } else if (v.category === 4) {
- resultData_4.push(v)
- }else {
- resultData_5.push(v)
- }
- })
- $('#workorderlist_1').bootstrapTable('load', resultData_1);
- $('#workorderlist_2').bootstrapTable('load', resultData_2);
- $('#workorderlist_3').bootstrapTable('load', resultData_3);
- $('#workorderlist_4').bootstrapTable('load', resultData_4);
- $('#workorderlist_5').bootstrapTable('load', resultData_5);
-
- }
- });
- $('#workorderlist_1').bootstrapTable('destroy').bootstrapTable({
- striped: true,
- pagination: false,
- columns:tableColumns
- });
- $('#workorderlist_2').bootstrapTable('destroy').bootstrapTable({
- striped: true,
- pagination: false,
- columns:tableColumns
- });
- $('#workorderlist_3').bootstrapTable('destroy').bootstrapTable({
- striped: true,
- pagination: false,
- columns:tableColumns
- });
- $('#workorderlist_4').bootstrapTable('destroy').bootstrapTable({
- striped: true,
- pagination: false,
- columns:tableColumns
- });
- $('#workorderlist_5').bootstrapTable('destroy').bootstrapTable({
- striped: true,
- pagination: false,
- columns:tableColumns
- });
- }
- // 树形下拉开始
- function bindtree() {
- $.getJSON(
- huayi.config.callcenter_url + treeInputParam.treeApi, {
- token: $.cookie("token")
- },
- function (result) {
- if (result.state.toLowerCase() == "success") {
- $.fn.zTree.init($(treeInputParam.treeId), setting, result.data);
- }
- }
- );
- }
-
- $(treeInputParam.classInps).focus(function () {
- $(this).siblings(treeInputParam.classAddTree).css("display", "block");
- });
- $(treeInputParam.classXl).click(function () {
- var xl = $(this).siblings(treeInputParam.classXl);
- if (xl.css("display") == "block") {
- xl.css("display", "none");
- } else {
- xl.css("display", "block");
- }
- });
- $(treeInputParam.classAddTree).mouseleave(function () {
- $(this).css("display", "none");
- });
- //获取所属部门
- var setting = {
- data: {
- key: {
- name: treeInputParam.treeObj.name,
- },
- simpleData: {
- enable: true,
- idKey: treeInputParam.treeObj.id,
- pIdKey: treeInputParam.treeObj.pid,
- rootPId: -1,
- },
- },
- callback: {
- onClick: treeInputParam.treeObj.onclick,
- },
- };
- function zTreeOnClick(event, treeId, treeNode) {
- $(treeInputParam.classInps).val(treeNode[treeInputParam.treeObj.name]);
- $(treeInputParam.classId).val(treeNode[treeInputParam.treeObj.id]);
- }
- // 树形下拉结束
- // 下拉框
- function selectCommon(obj) {
- var resultParam
- var dataParam = {
- token: $.cookie("token")
- }
- if (obj.dataParam) {
- resultParam = Object.assign(dataParam, obj.dataParam)
- }else{
- resultParam = dataParam
- }
- $(obj.id).empty();
- $(obj.id).append(
- '<option selected="selected" value="">请选择</option>'
- );
- $.getJSON(
- huayi.config.callcenter_url +
- obj.apiUrl, resultParam,
- function (data) {
- if (data.state.toLowerCase() == "success") {
- var content = data.data;
- $(content).each(function (i, n) {
- $(
- "<option value='" +
- n.F_ValueId +
- "'>" +
- n.F_Value +
- "</option>"
- ).appendTo($(obj.id));
- });
- }
- }
- );
- }
- //下拉框结束
- // 导出列表
- function exportFileFun(api, params) {
- var url = huayi.config.callcenter_url + api;
- if(typeof(params) !== "object") {
- return
- }
- delete params.page
- delete params.pagesize
- delete params.pageindex
- Object.keys(params).forEach(function(key, index) {
- if(!params[key]){
- params[key] = ""
- }
- if (index === 0) {
- url += `?${key}=${params[key]}`
- } else {
- url += `&${key}=${params[key]}`
- }
- })
- window.location.href = url;
- }
- //导出列表结束
- </script>
- </body>
- </html>
|