Parcourir la source

统计功能增加及优化

wangjianguo il y a 8 ans
Parent
commit
40226f9b2f

+ 23 - 9
VisualInspection/css/statistics/personal_data_statistics.css

@@ -97,11 +97,10 @@
     width:20px;
     width:20px;
     height:50px;
     height:50px;
     float:left;
     float:left;
-    margin-left: 15px;
     line-height: 50px;
     line-height: 50px;
 }
 }
 .div-start input,.div-end input{
 .div-start input,.div-end input{
-    width:120px;
+    width:100px;
     height:30px;
     height:30px;
     border: 1px solid #ccc;
     border: 1px solid #ccc;
     font-size: 14px;
     font-size: 14px;
@@ -116,36 +115,51 @@
     line-height: 50px;
     line-height: 50px;
 }
 }
 .div-check{
 .div-check{
-    width:190px;
+    width:160px;
     height:50px;
     height:50px;
     float:left;
     float:left;
-    margin-left: 50px;
+    margin-left: 10px;
     line-height: 50px;
     line-height: 50px;
     border-radius: 4px;
     border-radius: 4px;
 }
 }
 .div-check select{
 .div-check select{
-    width:190px;
+    width:160px;
     height:30px;
     height:30px;
     border: 1px solid #ccc;
     border: 1px solid #ccc;
     border-radius: 4px;
     border-radius: 4px;
 }
 }
 .div-select{
 .div-select{
-    width:80px;
+    width:100px;
     height:50px;
     height:50px;
     float:left;
     float:left;
-    margin-left: 20px;
+    margin-left: 5px;
+    line-height: 50px;
+}
+.div-select select{
+    width:100px; 
+    height:30px;
+    border: 1px solid #ccc;
+    border-radius: 4px;
 }
 }
+
+.name1{
+    width:98px;
+    height:50px;
+    float:left;
+    margin-left: 10px;
+    line-height: 50px;
+} 
 .query{
 .query{
     width:80px;
     width:80px;
     height:50px;
     height:50px;
     float:left;
     float:left;
-    margin-left: 40px;
+    margin-left: 20px;
 }
 }
 .export{
 .export{
     width:80px;
     width:80px;
     height:50px;
     height:50px;
     float:right;
     float:right;
-    margin-right: 40px;
+    margin-right: 20px;
 }
 }
 
 
 .div-button button{
 .div-button button{

+ 17 - 5
VisualInspection/css/statistics/road_manage_statistics.css

@@ -5,7 +5,7 @@
     border:1px solid #d9d9d9;
     border:1px solid #d9d9d9;
     font-family: '宋体';
     font-family: '宋体';
     border-radius: 4px;
     border-radius: 4px;
-    font-size: 15px;
+    font-size: 12px;
 }
 }
 .row-1{
 .row-1{
     width:100%;
     width:100%;
@@ -47,6 +47,15 @@
     margin-left: 20px;
     margin-left: 20px;
     line-height: 50px;
     line-height: 50px;
 }
 }
+.div-roadManage select{
+    width:80px;
+    height:30px;
+    border: 1px solid #ccc;
+    border-radius: 4px;
+    font-size: 13px;
+    font-size: 14px;
+}
+
 .div-button{
 .div-button{
     width:80px;
     width:80px;
     height:50px;
     height:50px;
@@ -157,6 +166,13 @@
    float:left;
    float:left;
    margin-left: 20px;
    margin-left: 20px;
 }
 }
+.div-month select{
+    width: 80px;
+    height: 30px;
+    border: 1px solid #ccc;
+    border-radius: 4px; 
+    font-size: 14px;
+}
 .query-total{
 .query-total{
    width:70px;
    width:70px;
    height:20px; 
    height:20px; 
@@ -164,10 +180,6 @@
    float:right;
    float:right;
    margin-right: 20px;
    margin-right: 20px;
 }
 }
-.row-2 select{
-    width:80px;
-    height:25px;
-}
 .row-7{
 .row-7{
     width:100%;
     width:100%;
     height:40px;
     height:40px;

+ 38 - 10
VisualInspection/css/statistics/toll_station_statistics.css

@@ -5,7 +5,7 @@
     border:1px solid #d9d9d9;
     border:1px solid #d9d9d9;
     font-family: '宋体';
     font-family: '宋体';
     border-radius: 4px;
     border-radius: 4px;
-    font-size: 15px;
+    font-size: 12px;
 }
 }
 .row-1{
 .row-1{
     width:100%;
     width:100%;
@@ -54,15 +54,32 @@
     margin-left: 20px;
     margin-left: 20px;
     line-height: 50px;
     line-height: 50px;
 }
 }
-#second{
-    width:120px;
-    height:25px;
+.div-roadManage select{
+    width:80px;
+    height:30px;
+    border: 1px solid #ccc;
+    border-radius: 4px;
+    font-size: 14px;
+}
+.div-station select{
+    width:110px;
+    height:30px;
+    border: 1px solid #ccc;
+    border-radius: 4px;
+    font-size: 14px;
+}
+.div-month select{
+    width:80px;
+    height:30px;
+    border: 1px solid #ccc;
+    border-radius: 4px;
+    font-size: 14px;
 }
 }
 .div-button{
 .div-button{
     width:80px;
     width:80px;
     height:50px;
     height:50px;
     float:left;
     float:left;
-    margin-left: 20px;
+    margin-left: 10px;
 }
 }
 
 
 .div-button button{
 .div-button button{
@@ -75,6 +92,22 @@
     border-radius: 4px;
     border-radius: 4px;
     margin-top: 10px;
     margin-top: 10px;
 }
 }
+.btn-change{
+    width:60px;
+    height:40px;
+    float:right;
+}
+.view_change{
+    width:60px;
+    height:40px;
+    color: #fff;
+    background-color: #00ced1;
+    border-color: #1970fc;
+    border:1px solid transparent;
+    border-radius: 4px;
+    font-weight: bolder;
+}
+
 .row-3,.row-4,.row-6,.row-7{
 .row-3,.row-4,.row-6,.row-7{
     width:100%;
     width:100%;
     height:40px;
     height:40px;
@@ -99,7 +132,6 @@
     height:40px;
     height:40px;
     float:left;
     float:left;
     line-height: 40px;
     line-height: 40px;
-    text-align: center;
     font-weight: bold;
     font-weight: bold;
 }
 }
 .line-2{
 .line-2{
@@ -175,10 +207,6 @@
    float:right;
    float:right;
    margin-right: 20px;
    margin-right: 20px;
 }
 }
-.row-2 select{
-    width:80px;
-    height:25px;
-}
 .row-7{
 .row-7{
     width:100%;
     width:100%;
     height:40px;
     height:40px;

+ 9 - 5
VisualInspection/css/statistics/total_company_statistics.css

@@ -5,7 +5,7 @@
     border:1px solid #d9d9d9;
     border:1px solid #d9d9d9;
     font-family: '宋体';
     font-family: '宋体';
     border-radius: 4px;
     border-radius: 4px;
-    font-size: 15px;
+    font-size: 12px;
 }
 }
 .row-1{
 .row-1{
     width:100%;
     width:100%;
@@ -40,6 +40,13 @@
     margin-left: 20px;
     margin-left: 20px;
     line-height: 50px;
     line-height: 50px;
 }
 }
+.div-month select{
+    width: 80px;
+    height: 30px;
+    border: 1px solid #ccc;
+    border-radius: 4px; 
+    font-size: 14px;
+}
 .div-button{
 .div-button{
     width:80px;
     width:80px;
     height:50px;
     height:50px;
@@ -157,10 +164,7 @@
    float:right;
    float:right;
    margin-right: 20px;
    margin-right: 20px;
 }
 }
-.row-2 select{
-    width:80px;
-    height:25px;
-}
+
 .row-7{
 .row-7{
     width:100%;
     width:100%;
     height:40px;
     height:40px;

+ 11 - 10
VisualInspection/js/statistics/assess_ranking.js

@@ -62,17 +62,18 @@ function getEmployeeInfosClick(url,param,start_score,end_score){
         for(var i=0;i<data.length;i++){
         for(var i=0;i<data.length;i++){
             var score = 1000-filterByZeroHandle(average(data[i]).toFixed(2),'0');
             var score = 1000-filterByZeroHandle(average(data[i]).toFixed(2),'0');
             var flag=judgeParamFilter(data, i,score, start_score,end_score)
             var flag=judgeParamFilter(data, i,score, start_score,end_score)
-            console.log("职位是是:"+flag)
             if(flag){
             if(flag){
-                strTbody+="<tr><td width='67px;'>"+(count+1)+"</td><td width='87px;'>"+data[i].user.fee_station_name+"</td>"
-                +"<td width='67px;'>"+data[i].user.truename+"</td><td width='67px;'>"+data[i].user.position_name+"</td>"
-                +"<td width='87px;'>"+data[i].user.workno+"</td><td width='58px;'>"+ getItemScore(data[i], '环境') +"</td>"
-                +"<td width='58px;'>"+getItemScore(data[i], '仪容仪表')+"</td><td width='58px;'>"+getItemScore(data[i], '表情')+"</td>"
-                +"<td width='58px;'>"+getItemScore(data[i], '动作')+"</td><td width='58px;'>"+getItemScore(data[i], '文明用语')+"</td>"
-                +"<td width='58px;'>"+ getItemScore(data[i], '工作纪律') +"</td><td width='58px'>"+getItemScore(data[i], '便民服务')+"</td><td width='58px'>"
-                +getItemScore(data[i], '安全管理')+"</td><td width='58px;'>"+data[i].check_all_score+"</td>"
-                +"<td width='67px;'>"+filter(data[i].checked_num,'0')+"</td><td width='67px;'>"+filterByZeroHandle(average(data[i]).toFixed(2),'0')+"</td>"
-                +"<td width='55px;'>"+score+"</td><td width='58px;'>"+"</td><td width='58px;'>"+"</td></tr>";
+                strTbody+="<tr><td width='4%;'>"+(count+1)+"</td><td width='6%;'>"+data[i].user.fee_station_name+"</td>"
+                +"<td width='6%;'>"+data[i].user.truename+"</td><td width='6%;'>"+data[i].user.position_name+"</td>"
+                +"<td width='6%;'>"+data[i].user.workno+"</td><td width='4%;'>"+data[i].company_ranking+"</td>"
+                +"<td width='4%;'>"+data[i].center_ranking+"</td><td width='4%;'>"+data[i].fee_station_ranking
+                +"</td><td width='4%;'>"+ getItemScore(data[i], '环境') +"</td>"
+                +"<td width='4%;'>"+getItemScore(data[i], '仪容仪表')+"</td><td width='4%;'>"+getItemScore(data[i], '表情')+"</td>"
+                +"<td width='4%;'>"+getItemScore(data[i], '动作')+"</td><td width='4%;'>"+getItemScore(data[i], '文明用语')+"</td>"
+                +"<td width='4%;'>"+ getItemScore(data[i], '工作纪律') +"</td><td width='4%'>"+getItemScore(data[i], '便民服务')+"</td><td width='4%;'>"
+                +getItemScore(data[i], '安全管理')+"</td><td width='4%;'>"+data[i].check_all_score+"</td>"
+                +"<td width='4%;'>"+filter(data[i].checked_num,'0')+"</td><td width='4%;'>"+filterByZeroHandle(average(data[i]).toFixed(2),'0')+"</td>"
+                +"<td width='4%;'>"+score+"</td><td width='4%;'>"+"</td><td width='4%;'>"+"</td></tr>";
                 count++;
                 count++;
             }
             }
         }
         }

+ 48 - 9
VisualInspection/js/statistics/check_workload_statistics.js

@@ -37,10 +37,10 @@ $(function(){
 		var cols = [
 		var cols = [
 					{width: 40,height:60, text: '序号', flex: true, colClass: 'text-center',field:'num'},
 					{width: 40,height:60, text: '序号', flex: true, colClass: 'text-center',field:'num'},
                     {width: 40,height:60, text: '稽查人员', flex: true,colClass: '',field:'checkman_name' },
                     {width: 40,height:60, text: '稽查人员', flex: true,colClass: '',field:'checkman_name' },
-                    {width: 100,height:60, text: '任务名称', flex: true,colClass: '',field:'start_date' },
-					{width: 100,height:60, text: '时间段', flex: true,colClass: '',field:'start_date' },
+                    {width: 100,height:60, text: '任务名称', flex: true,colClass: '',field:'check_task_name' },
+					{width: 100,height:60, text: '时间段', flex: true,colClass: '',field:'check_task_time_name' },
                     {width: 40,height:60, text: '考核人员', flex: true,colClass: '',field:'checked_name' },
                     {width: 40,height:60, text: '考核人员', flex: true,colClass: '',field:'checked_name' },
-                    {width: 40,height:60, text: '考核部门', flex: true,colClass: '',field:'feeStationName' },
+                    {width: 60,height:60, text: '考核部门', flex: true,colClass: '',field:'feeStationName' },
 					{width: 40,height:60, text: '扣分数',  flex: true, colClass: '',field:'score'},
 					{width: 40,height:60, text: '扣分数',  flex: true, colClass: '',field:'score'},
 					{width: 100,height:60, text: '考核项',  flex: true, colClass: '',sort: 'down',field:'name'},
 					{width: 100,height:60, text: '考核项',  flex: true, colClass: '',sort: 'down',field:'name'},
 					{width: 100,height:60, text: '扣分凭证', type: 'imagedd', flex: true, hide:hide,field:'pics'},
 					{width: 100,height:60, text: '扣分凭证', type: 'imagedd', flex: true, hide:hide,field:'pics'},
@@ -58,13 +58,13 @@ $(function(){
 		var cols = [
 		var cols = [
 					{width: 40,height:60, text: '序号', type: 'number', flex: true, colClass: 'text-center',field: 'num'},
 					{width: 40,height:60, text: '序号', type: 'number', flex: true, colClass: 'text-center',field: 'num'},
 					{width: 40,height:60, text: '稽查人员', type: 'string', flex: true, sort: 'down',field: 'checkman_name'},
 					{width: 40,height:60, text: '稽查人员', type: 'string', flex: true, sort: 'down',field: 'checkman_name'},
-                    {width: 100,height:60, text: '任务名称', type: 'string', flex: true, sort: 'down',field: 'name'},
-                    {width: 100,height:60, text: '时间段', type: 'string', flex: true, sort: 'down',field: 'name'},
+                    {width: 100,height:60, text: '任务名称', type: 'string', flex: true, sort: 'down',field: 'check_task_name'},
+                    {width: 100,height:60, text: '时间段', type: 'string', flex: true, sort: 'down',field: 'check_task_time_name'},
                     {width: 40,height:60, text: '考核人员', type: 'string', flex: true, sort: 'down',field: 'checked_name'},
                     {width: 40,height:60, text: '考核人员', type: 'string', flex: true, sort: 'down',field: 'checked_name'},
-                    {width: 40,height:60, text: '考核部门', type: 'string', flex: true, sort: 'down',field: 'feeStationName'},
-					{width: 40,height:60, text: '扣分数', type: 'string', flex: true, field: 'checked_person_name'},
-					{width: 100,height:60, text: '考核项', type: 'string', flex: true, sort: 'down',field: 'checked_dept_name'},
-					{width: 100,height:60, text: '扣分凭证', type: 'imagedd', flex: true, field: 'checkman_name'},
+                    {width: 60,height:60, text: '考核部门', type: 'string', flex: true, sort: 'down',field: 'feeStationName'},
+					{width: 40,height:60, text: '扣分数', type: 'string', flex: true, field: 'score'},
+					{width: 100,height:60, text: '考核项', type: 'string', flex: true, sort: 'down',field: 'name'},
+					{width: 100,height:60, text: '扣分凭证', type: 'imagedd', flex: true, field: 'pics'},
 		] ;
 		] ;
 	}
 	}
 
 
@@ -83,6 +83,7 @@ $(function(){
 		var user_id = $("#select-personal").val(); 
 		var user_id = $("#select-personal").val(); 
         // 表格
         // 表格
         initAppealPage(start_date,end_date,user_id);
         initAppealPage(start_date,end_date,user_id);
+		checkman_info(start_date,end_date,user_id);
 	});
 	});
     
     
     /**
     /**
@@ -103,11 +104,49 @@ $(function(){
                 var user_id = $("#select-personal").val(); 
                 var user_id = $("#select-personal").val(); 
                 // 初始化表格
                 // 初始化表格
                 initAppealPage(start_date,end_date,user_id);
                 initAppealPage(start_date,end_date,user_id);
+				checkman_info(start_date,end_date,user_id);
         },function(error){
         },function(error){
         	return "" ;
         	return "" ;
     	});
     	});
     }
     }
     select_personal();
     select_personal();
+	
+	/**
+	 * 稽查人员信息
+	 * @param {*} start_date 
+	 * @param {*} end_date 
+	 * @param {*} user_id 
+	 */
+	function checkman_info(start_date,end_date,user_id){
+		var param = {
+					"start_date": start_date,
+					"end_date": end_date,
+					"checkman_id":user_id
+					}
+		post_common_service("statistics/checkman/info",param,function(data){
+            if(data.length!=0){
+				console.log(data.all_check_minute)
+				$(".all_check_personal").text(data.all_checkman);
+				$(".all_check_task").text(data.all_task_num);
+				$(".all_check_minute").text(Math.floor(data.all_check_minute/60) + "小时" + (data.all_check_minute%60) + "分");
+				$(".all_checkman").text(data.all_checked_num);
+				$(".all_check_score").text(data.all_checked_score);
+				$(".check_score_avg").text(filter(data.all_checked_score,data.all_checked_num,0));
+            }else{
+            }
+        },function(error){
+        	return "" ;
+    	});
+    }
+
+	function filter(num,num1,num2){
+		if(num1 == 0){
+			return num2;
+		}else{
+			return (num/num1).toFixed(2);
+		}
+	}
+	
 
 
 
 
 });
 });

+ 65 - 13
VisualInspection/js/statistics/personal_data_statistics.js

@@ -22,9 +22,9 @@ var end_date = $(".div-end input").val()+" 23:59:59";
 $(function(){
 $(function(){
 
 
 //*************************************数据表格******************************************
 //*************************************数据表格******************************************
-	function initAppealPage(start_date,end_date) {
+	function initAppealPage(start_date,end_date,user_id) {
 		initQueryParams();
 		initQueryParams();
-		queryAppeal(start_date,end_date);
+		queryAppeal(start_date,end_date,user_id);
     }
     }
 
 
 	function initQueryParams() {
 	function initQueryParams() {
@@ -35,7 +35,7 @@ $(function(){
 		}
 		}
 	}
 	}
 
 
-	function queryAppeal(start_date,end_date){
+	function queryAppeal(start_date,end_date,user_id){
 		var data = {
 		var data = {
 			"start_date":start_date,
 			"start_date":start_date,
 				"end_date":end_date,
 				"end_date":end_date,
@@ -48,7 +48,7 @@ $(function(){
 		
 		
 		var cols = [
 		var cols = [
 					{width: 50, text: '序号', flex: true, colClass: 'text-center',field:'num'},
 					{width: 50, text: '序号', flex: true, colClass: 'text-center',field:'num'},
-					{width: 100, text: '时间段', flex: true,colClass: '',field:'start_date' },
+					{width: 100, text: '时间段', flex: true,colClass: '',field:'check_task_time_name' },
 					{width: 60, text: '扣分数',  flex: true, colClass: '',field:'score'},
 					{width: 60, text: '扣分数',  flex: true, colClass: '',field:'score'},
 					{width: 100, text: '考核项',  flex: true, colClass: '',sort: 'down',field:'name'},
 					{width: 100, text: '考核项',  flex: true, colClass: '',sort: 'down',field:'name'},
 					{width: 100, text: '扣分凭证', type: 'imagedd', flex: true, hide:hide,field:'pics'},
 					{width: 100, text: '扣分凭证', type: 'imagedd', flex: true, hide:hide,field:'pics'},
@@ -65,15 +65,14 @@ $(function(){
 	function queryUnAssignedTable(){
 	function queryUnAssignedTable(){
 			var cols = [
 			var cols = [
 					{width: 50, text: '序号', type: 'number', flex: true, colClass: 'text-center',field: 'num'},
 					{width: 50, text: '序号', type: 'number', flex: true, colClass: 'text-center',field: 'num'},
-					{width: 100, text: '时间段', type: 'string', flex: true, sort: 'down',field: 'start_date'},
+					{width: 100, text: '时间段', type: 'string', flex: true, sort: 'down',field: 'check_task_time_name'},
 					{width: 60, text: '扣分数', type: 'string', flex: true, field: 'score'},
 					{width: 60, text: '扣分数', type: 'string', flex: true, field: 'score'},
 					{width: 100, text: '考核项', type: 'string', flex: true, sort: 'down',field: 'name'},
 					{width: 100, text: '考核项', type: 'string', flex: true, sort: 'down',field: 'name'},
 					{width: 100, text: '扣分凭证', type: 'imagedd', flex: true, field: 'pics'},
 					{width: 100, text: '扣分凭证', type: 'imagedd', flex: true, field: 'pics'},
 						] ;
 						] ;
 	}
 	}
 
 
-    // 表格
-	initAppealPage(start_date,end_date);
+    
 
 
 //*************************************画图******************************************
 //*************************************画图******************************************
 
 
@@ -81,6 +80,7 @@ $(function(){
 	echart();
 	echart();
 
 
 	$(".query button").click(function(){
 	$(".query button").click(function(){
+        var user_id = $("#select-personal").val();
 		var start_date = $(".div-start input").val()+" 00:00:00";
 		var start_date = $(".div-start input").val()+" 00:00:00";
 		var end_date = $(".div-end input").val()+" 23:59:59";
 		var end_date = $(".div-end input").val()+" 23:59:59";
 		var startStr = start_date.replace(/-/g, '/');
 		var startStr = start_date.replace(/-/g, '/');
@@ -91,14 +91,18 @@ $(function(){
 			tip("开始时间不能比结束时间大");
 			tip("开始时间不能比结束时间大");
 			return;
 			return;
 		}
 		}
+		if($("#select-personal").text()==''){
+             tip("请选择收费站");
+			 return;
+		}
 		// 查询图一
 		// 查询图一
 		init_personal_score_statistics("statistics/one/person/year/info",user_id);
 		init_personal_score_statistics("statistics/one/person/year/info",user_id);
 		// 查询图二
 		// 查询图二
 		init_personal_check_type("statistics/one/person/checkedItem/info",user_id,start_date,end_date);
 		init_personal_check_type("statistics/one/person/checkedItem/info",user_id,start_date,end_date);
+		// 表格
+	    initAppealPage(start_date,end_date,user_id);
 		// 加载图配置
 		// 加载图配置
 		echart();
 		echart();
-		// 表格
-	    initAppealPage(start_date,end_date);
 	});
 	});
     /**
     /**
 	 * 初始化图一
 	 * 初始化图一
@@ -113,7 +117,7 @@ $(function(){
 		}
 		}
 		initRqueset(url,param,1);
 		initRqueset(url,param,1);
 	}
 	}
-	init_personal_score_statistics("statistics/one/person/year/info",user_id);
+	
 
 
     /**
     /**
 	 * 初始化图二
 	 * 初始化图二
@@ -128,7 +132,7 @@ $(function(){
 		}
 		}
 		initRqueset(url,param,2);
 		initRqueset(url,param,2);
 	}
 	}
-	init_personal_check_type("statistics/one/person/checkedItem/info",user_id,start_date,end_date);
+	
     
     
 	/**
 	/**
 	 * 请求
 	 * 请求
@@ -170,7 +174,7 @@ $(function(){
 					if(months.indexOf(parseInt(data[i].mth.substr(5)))){
 					if(months.indexOf(parseInt(data[i].mth.substr(5)))){
 						// 指定位置插入值
 						// 指定位置插入值
 						array_year_score.splice(parseInt(data[i].mth.substr(5))-1,0,
 						array_year_score.splice(parseInt(data[i].mth.substr(5))-1,0,
-						(1000-(filter_handler(data[i].all_check_score,data[i].checked_num,data[i].people_num,0)).toFixed(1)));
+						(1000-(filter_handler(data[i].all_check_score,data[i].checked_num,data[i].people_num,0)).toFixed(2)));
 					}
 					}
 				}
 				}
 		    }else{
 		    }else{
@@ -189,6 +193,54 @@ $(function(){
 		}
 		}
 	}
 	}
 
 
+	$("#select-personal").click(function(){
+		if($("#select-personal").text()==''){
+             tip("请选择收费站");
+			 return;
+		}
+	});
+	// 收费站下拉框
+	setFeSelect("#select-dept");
+	/**
+	 * 部门人员下拉框
+	 */
+	function setSecond(){ 
+        var select_road = $("#select-dept").val();
+		var sec = document.getElementById('select-personal');
+		var tempStr = ''
+		var param = {
+			 "organid":select_road
+		}
+		post_common_service("user/getFsUserList",param,function(data){
+			if(data.length!=0){
+				for(var i=0;i<data.length;i++){
+					for(var j=33;j<=53;j++){
+						if(select_road==j){
+							tempStr += "<option value="+data[i].id+">"+data[i].truename+"</option>";  
+						}
+					}
+				sec.innerHTML=tempStr;
+				}
+			}else{
+				sec.innerHTML='';	
+			}
+            var start_date = $(".div-start input").val()+" 00:00:00";
+            var end_date = $(".div-end input").val()+" 23:59:59";
+            var user_id = $("#select-personal").val();
+			// 页面初始化
+            initAppealPage(start_date,end_date,user_id);
+            init_personal_score_statistics("statistics/one/person/year/info",user_id);
+            init_personal_check_type("statistics/one/person/checkedItem/info",user_id,start_date,end_date);
+		},function(error){
+        	return "" ;
+    	});
+    }
+	$("#select-dept").change(function(){
+		setSecond();
+	});
+
+	
+
 	 /**
 	 /**
 	 * 除数为0处理
 	 * 除数为0处理
 	 * @param {*} num 
 	 * @param {*} num 
@@ -290,7 +342,7 @@ $(function(){
 			option = {
 			option = {
 				tooltip : {
 				tooltip : {
 					trigger: 'item',
 					trigger: 'item',
-					formatter: "{a} <br/>{b} : {c} ({d}%)"
+					formatter:  "个人服务检查问题占比 <br/>{b} : {d}%"
 				},
 				},
 				toolbox: {
 				toolbox: {
 					show : true,
 					show : true,

+ 76 - 41
VisualInspection/js/statistics/road_manage_statistics.js

@@ -27,6 +27,11 @@
 		var people_points;
 		var people_points;
 		var rank_pre;
 		var rank_pre;
 		var rank_suf;
 		var rank_suf;
+		var min_year;
+		var min_station;
+		var min_pre
+		var min_suff;
+		var flag = true;
 $(function(){
 $(function(){
     // 显示当前月份
     // 显示当前月份
 	$(".div-month select").val(month);
 	$(".div-month select").val(month);
@@ -34,8 +39,7 @@ $(function(){
 	$(".div-button button").click(function(){	
 	$(".div-button button").click(function(){	
 		var select_month = $(".div-month select").val();
 		var select_month = $(".div-month select").val();
 		var select_road = $(".div-roadManage select").val();
 		var select_road = $(".div-roadManage select").val();
-		// 查询图一
-		init_company_year_assess("statistics/score/year/info",select_road);
+		flag = false;
 		// 查询图二
 		// 查询图二
 		init_company_points_assess("statistics/lost/score/rate",select_month+'',select_road);
 		init_company_points_assess("statistics/lost/score/rate",select_month+'',select_road);
 		// 查询图三
 		// 查询图三
@@ -154,7 +158,13 @@ $(function(){
 	 * 初始化图七
 	 * 初始化图七
 	 */
 	 */
     function init_each_people_points(url,mon,select_road){
     function init_each_people_points(url,mon,select_road){
-		var prev_mth = (mon-1)+'';		
+		var yearPre = year;
+		if(mon==1){
+			prev_mth = 12+'';
+			yearPre = yearPre-1;
+		}else{
+		var prev_mth = (mon-1)+'';	
+		}	
 		if(mon.length==1){
 		if(mon.length==1){
 			mon = "0" +mon;
 			mon = "0" +mon;
 		}
 		}
@@ -163,7 +173,7 @@ $(function(){
 		}
 		}
 		var param = {
 		var param = {
 			"mth":year + "/" + mon,
 			"mth":year + "/" + mon,
-			"prev_mth": year + "/" + prev_mth,
+			"prev_mth": yearPre + "/" + prev_mth,
 			"dept_id":select_road,
 			"dept_id":select_road,
 			"queryType":1
 			"queryType":1
 		};
 		};
@@ -214,24 +224,28 @@ $(function(){
 		if(type == 1){
 		if(type == 1){
 			array_year_score.length = 0;
 			array_year_score.length = 0;
 			months.length = 0;
 			months.length = 0;
-			if(data!=''){
-			if(data.length<12){
-				for(var i=0;i<12-data.length;i++){
-					// 不足月份补0
-					array_year_score.push(0);
-				}
-			}		
-			for(var i=0;i<data.length;i++){
-				if(months.indexOf(parseInt(data[i].mth.substr(5)))){
-					// 指定位置插入值
-					array_year_score.splice(parseInt(data[i].mth.substr(5))-1,0,
-					(1000-(filter_handler(data[i].all_check_score,data[i].checked_num,data[i].people_num,0)).toFixed(1)));
+		    if(data!='' && data.length!=0){
+				if(data.length<12){
+					for(var i=0;i<12-data.length;i++){
+						// 不足月份补0
+						array_year_score.push(0);
+					}
+					}		
+				for(var i=0;i<data.length;i++){
+					if(months.indexOf(parseInt(data[i].mth.substr(5)))){
+						// 指定位置插入值
+						array_year_score.splice(parseInt(data[i].mth.substr(5))-1,0,
+						(1000-(filter_handler(data[i].all_check_score,data[i].checked_num,data[i].people_num,0))));
+					}
 				}
 				}
-			}
 			}else{
 			}else{
 					array_year_score.length = 0;
 					array_year_score.length = 0;
 					months.length = 0;
 					months.length = 0;
-			}	
+			}
+			if(eval("Math.min(" + array_year_score.toString() + ")")==0)
+			min_year = 0;
+			else
+			min_year = 	eval("Math.min(" + array_year_score.toString() + ")").toFixed(0)-10;	
 		}else if(type == 2){
 		}else if(type == 2){
 			array_points.length=0;
 			array_points.length=0;
 				if(data!=''){
 				if(data!=''){
@@ -246,39 +260,51 @@ $(function(){
 		}else if(type == 3){
 		}else if(type == 3){
 			array_allStation_score.length=0;
 			array_allStation_score.length=0;
 			array_allStation.length=0;
 			array_allStation.length=0;
-            for(var i=0;i<data.length;i++){
-				if(data!=''){
+			if(data!='' && data.length!=0){
+				for(var i=0;i<data.length;i++){
 					array_allStation.push(data[i].feeStationName.substr(0,data[i].feeStationName.length-3));
 					array_allStation.push(data[i].feeStationName.substr(0,data[i].feeStationName.length-3));
-					array_allStation_score.push((1000-(filter_handler(data[i].all_check_score,data[i].checked_num,data[i].people_num,0)).toFixed(1)));
-				}else{
-					array_allStation_score.length=0;
-			        array_allStation.length=0;	
+					array_allStation_score.push((1000-(filter_handler(data[i].all_check_score,data[i].checked_num,data[i].people_num,0))));
 				}
 				}
-	        }
+			}else{
+				array_allStation_score.length=0;
+				array_allStation.length=0;	
+			}
+			    if(eval("Math.min(" + array_allStation_score.toString() + ")")==0)
+				min_station = 0;
+				else
+				min_station = 	eval("Math.min(" + array_allStation_score.toString() + ")").toFixed(0)-10;
 		}else if(type == 4){
 		}else if(type == 4){
 			array_score_order.length=0;
 			array_score_order.length=0;
 			array_score_data.length=0;
 			array_score_data.length=0;
-				if(data!=''){
+				if(data!='' && data.length!=0){
 					for(var i=0;i<data.length;i++){
 					for(var i=0;i<data.length;i++){
 						array_score_order.push(data[i].user.truename+"\n"+"("+data[i].user.fee_station_name.substr(0,data[i].user.fee_station_name.length-3)+")");
 						array_score_order.push(data[i].user.truename+"\n"+"("+data[i].user.fee_station_name.substr(0,data[i].user.fee_station_name.length-3)+")");
-						array_score_data.push((1000-filter(data[i].all_check_score,data[i].checked_num,0)).toFixed(1));
+						array_score_data.push((1000-filter(data[i].all_check_score,data[i].checked_num,0)));
 				    }
 				    }
 				 }else{
 				 }else{
 					array_score_order.length=0;
 					array_score_order.length=0;
 			        array_score_data.length=0;	
 			        array_score_data.length=0;	
 				}
 				}
+				if(eval("Math.min(" + array_score_data.toString() + ")")==0)
+				min_pre = 0;
+				else
+				min_pre = eval("Math.min(" + array_score_data.toString() + ")").toFixed(0)-10;
 	    }else if(type == 5){
 	    }else if(type == 5){
 			array_score_last.length=0;
 			array_score_last.length=0;
 			array_get_score.length=0;
 			array_get_score.length=0;
-				if(data!=''){
+				if(data!='' && data.length!=0){
 					for(var i=0;i<data.length;i++){
 					for(var i=0;i<data.length;i++){
 						array_score_last.push(data[i].user.truename+"\n"+"("+data[i].user.fee_station_name.substr(0,data[i].user.fee_station_name.length-3)+")");
 						array_score_last.push(data[i].user.truename+"\n"+"("+data[i].user.fee_station_name.substr(0,data[i].user.fee_station_name.length-3)+")");
-						array_get_score.push((1000-filter(data[i].all_check_score,data[i].checked_num,0)).toFixed(1));
+						array_get_score.push((1000-filter(data[i].all_check_score,data[i].checked_num,0)));
 				    }
 				    }
 				 }else{
 				 }else{
 					array_score_last.length=0;
 					array_score_last.length=0;
 			        array_get_score.length=0;	
 			        array_get_score.length=0;	
 				}
 				}
+				if(eval("Math.min(" + array_get_score.toString() + ")")==0)
+				min_suff = 0;
+				else
+				min_suff = eval("Math.min(" + array_get_score.toString() + ")").toFixed(0)-10;
 	    }else if(type == 6){
 	    }else if(type == 6){
 			array_check_type.length=0;
 			array_check_type.length=0;
                 if(data.length != 0){
                 if(data.length != 0){
@@ -292,7 +318,13 @@ $(function(){
 			array_points_name.length=0;
 			array_points_name.length=0;
 			array_points_pre.length=0;
 			array_points_pre.length=0;
 			arrar_points_month.length=0;
 			arrar_points_month.length=0;
-			data_each_people_points(data);
+			if(data!='' && data.Pmth.length!=0 || data.Tmth.length!=0){
+			   data_each_people_points(data);
+			}else{
+				array_points_name.length=0;
+				array_points_pre.length=0;
+				arrar_points_month.length=0;
+			}   
 		}
 		}
 	}
 	}
 
 
@@ -310,7 +342,7 @@ $(function(){
 				if(Tmth.length > 0){
 				if(Tmth.length > 0){
 					for(var j= 0; j< Tmth.length;j++){
 					for(var j= 0; j< Tmth.length;j++){
 						if(name[i] == Tmth[j].name && Tmth[j].all_check_score != null){
 						if(name[i] == Tmth[j].name && Tmth[j].all_check_score != null){
-							Ttemp[i] = Tmth[j].all_check_score;
+							Ttemp[i] = filter_handler(Tmth[j].all_check_score,Tmth[j].checked_num,Tmth[j].people_num,0);
 							break;
 							break;
 						}else{
 						}else{
 							Ttemp[i] = 0;
 							Ttemp[i] = 0;
@@ -322,7 +354,7 @@ $(function(){
 				if(Pmth.length > 0){
 				if(Pmth.length > 0){
 					for(var m= 0; m< Pmth.length;m++){
 					for(var m= 0; m< Pmth.length;m++){
 						if(name[i] == Pmth[m].name && Pmth[m].all_check_score != null){
 						if(name[i] == Pmth[m].name && Pmth[m].all_check_score != null){
-							Ptemp[i] = Pmth[m].all_check_score;
+							Ptemp[i] = filter_handler(Pmth[m].all_check_score,Pmth[m].checked_num,Pmth[m].people_num,0);
 							break;
 							break;
 						}else{
 						}else{
 							Ptemp[i] = 0;
 							Ptemp[i] = 0;
@@ -363,7 +395,7 @@ $(function(){
 		if(num1 == 0 || num2 == 0){
 		if(num1 == 0 || num2 == 0){
 			return num4;
 			return num4;
 		}else{
 		}else{
-			return (num/num1)/num2;
+			return ((num/num1)/num2).toFixed(2);
 		}
 		}
 	}
 	}
 
 
@@ -371,7 +403,7 @@ $(function(){
 		if(num1 == 0){
 		if(num1 == 0){
 			return num2;
 			return num2;
 		}else{
 		}else{
-			return (num/num1);
+			return (num/num1).toFixed(2);
 		}
 		}
 	}
 	}
     
     
@@ -392,7 +424,9 @@ $(function(){
 		],
 		],
 	function (ec) {
 	function (ec) {
 			// 基于准备好的dom,初始化echarts图表
 			// 基于准备好的dom,初始化echarts图表
+			if(flag){
 			year_assess = ec.init(document.getElementById('roadManager-year-assess')); 
 			year_assess = ec.init(document.getElementById('roadManager-year-assess')); 
+		    }
 			points_assess = ec.init(document.getElementById('roadManager-points-assess'));
 			points_assess = ec.init(document.getElementById('roadManager-points-assess'));
 		    score_rank = ec.init(document.getElementById('tollStation-score-rank'));
 		    score_rank = ec.init(document.getElementById('tollStation-score-rank'));
 			rank_pre = ec.init(document.getElementById('people-rank-pre'));
 			rank_pre = ec.init(document.getElementById('people-rank-pre'));
@@ -430,7 +464,7 @@ $(function(){
 					yAxis : [
 					yAxis : [
 						{
 						{
 							type : 'value',
 							type : 'value',
-							min : 700 ,
+							min : min_year ,
 						    max : 1000,
 						    max : 1000,
 							axisLabel : {
 							axisLabel : {
 								formatter: '{value}'
 								formatter: '{value}'
@@ -468,7 +502,7 @@ $(function(){
 			option = {
 			option = {
 				tooltip : {
 				tooltip : {
 					trigger: 'item',
 					trigger: 'item',
-					formatter: "{a} <br/>{b} : {c} ({d}%)"
+					formatter:  "道管中心考核扣分占比 <br/>{b} : {d}%"
 				},
 				},
 				toolbox: {
 				toolbox: {
 					show : true,
 					show : true,
@@ -525,7 +559,7 @@ $(function(){
 				yAxis : [
 				yAxis : [
 					{
 					{
 						type : 'value',
 						type : 'value',
-						min : 900 ,
+						min : min_station ,
 						max : 1000
 						max : 1000
 					}
 					}
 				],
 				],
@@ -583,7 +617,7 @@ $(function(){
 				yAxis : [
 				yAxis : [
 					{
 					{
 						type : 'value',
 						type : 'value',
-						min : 900 ,
+						min : min_pre ,
 						max : 1000
 						max : 1000
 					}
 					}
 				],
 				],
@@ -648,7 +682,7 @@ $(function(){
 				yAxis : [
 				yAxis : [
 					{
 					{
 						type : 'value',
 						type : 'value',
-						min : 900 ,
+						min : min_suff ,
 						max : 1000
 						max : 1000
 					}
 					}
 				],
 				],
@@ -690,7 +724,7 @@ $(function(){
 			option = {
 			option = {
 				tooltip : {
 				tooltip : {
 					trigger: 'item',
 					trigger: 'item',
-					formatter: "{a} <br/>{b} : {c} ({d}%)"
+					formatter:  "温馨服务检查占比 <br/>{b} : {d}%"
 				},
 				},
 				toolbox: {
 				toolbox: {
 					show : true,
 					show : true,
@@ -733,7 +767,8 @@ $(function(){
 				trigger: 'axis'
 				trigger: 'axis'
 			},
 			},
 			grid:{
 			grid:{
-                    width:420  // 图表宽度
+                    width:470,  // 图表宽度
+					x:60
                 },
                 },
 			legend: {
 			legend: {
 				data:['上月','本月']
 				data:['上月','本月']

+ 255 - 60
VisualInspection/js/statistics/toll_station_statistics.js

@@ -15,12 +15,21 @@
 		var array_score_data = new Array();
 		var array_score_data = new Array();
 		var array_five_name = new Array();
 		var array_five_name = new Array();
 		var array_five_score = new Array();
 		var array_five_score = new Array();
+		var array_five_name_back = new Array();
+		var array_five_score_back = new Array();
 		var year_assess;
 		var year_assess;
 		var points_assess;
 		var points_assess;
 		var check_type;
 		var check_type;
 		var people_points;
 		var people_points;
 		var score_rank;
 		var score_rank;
 		var rank_assess;
 		var rank_assess;
+		var rank_assess_back;
+		var min_year;
+		var min_five;
+		var min_five_back;
+		var min_score;
+		var flag = true;
+		var change_echart = 1;
 $(function(){     
 $(function(){     
 	setSecond();
 	setSecond();
     // 显示当前月份
     // 显示当前月份
@@ -29,20 +38,21 @@ $(function(){
 	$(".div-button button").click(function(){	
 	$(".div-button button").click(function(){	
 		var select_month = $(".div-month select").val();
 		var select_month = $(".div-month select").val();
 		var select_station = $(".div-station select").val();
 		var select_station = $(".div-station select").val();
-		// 查询图一
-		init_tollStation_year_assess("statistics/score/year/info",select_station);
+		flag = false;
+		// 加载图配置
+		echart();
 		// 查询图二
 		// 查询图二
 		init_company_points_assess("statistics/lost/score/rate",select_month+'',select_station);
 		init_company_points_assess("statistics/lost/score/rate",select_month+'',select_station);
         // 查询图三
         // 查询图三
-		init_progress_rank_assess("statistics/fs/up/five",month+'',select_station)
+		init_progress_rank_assess("statistics/fs/up/five",select_month+'',select_station)
         // 查询图四
         // 查询图四
 		init_people_score_rank("statistics/stuff/score/info",select_month+'',select_station);
 		init_people_score_rank("statistics/stuff/score/info",select_month+'',select_station);
         // 查询图五
         // 查询图五
 		init_server_check_type("statistics/lost/itemscore/rate",select_month+"",select_station);
 		init_server_check_type("statistics/lost/itemscore/rate",select_month+"",select_station);
         // 查询图六
         // 查询图六
 		init_each_people_points("statistics/lost/twice/itemscore/rate",select_month+"",select_station);
 		init_each_people_points("statistics/lost/twice/itemscore/rate",select_month+"",select_station);
-		// 加载图配置
-		echart();
+
+		init_backward_rank_assess("statistics/fs/up/five",select_month+'',select_station);
 	});
 	});
 
 
 	// 加载图配置
 	// 加载图配置
@@ -78,10 +88,16 @@ $(function(){
 	}
 	}
 
 
 	/**
 	/**
-	 * 初始化图三
+	 * 初始化图三 前5名
 	 */
 	 */
 	function init_progress_rank_assess(url,mon,select_station){
 	function init_progress_rank_assess(url,mon,select_station){
-		var prev_mth = (mon-1)+'';		
+		var yearPre = year;
+		if(mon==1){
+			prev_mth = 12+'';
+			yearPre = yearPre-1;
+		}else{
+		var prev_mth = (mon-1)+'';	
+		}	
 		if(mon.length==1){
 		if(mon.length==1){
 			mon = "0" +mon;
 			mon = "0" +mon;
 		}
 		}
@@ -91,7 +107,7 @@ $(function(){
 		var param = {
 		var param = {
 			"mth":year + "/" + mon,
 			"mth":year + "/" + mon,
 			"dept_id":select_station,
 			"dept_id":select_station,
-			"prev_mth": year + "/" + prev_mth,
+			"prev_mth": yearPre + "/" + prev_mth,
 			"order_type":0
 			"order_type":0
 		};
 		};
 		initRqueset(url,param,3);
 		initRqueset(url,param,3);
@@ -133,7 +149,13 @@ $(function(){
 	 * 初始化图六
 	 * 初始化图六
 	 */
 	 */
     function init_each_people_points(url,mon,select_station){
     function init_each_people_points(url,mon,select_station){
-		var prev_mth = (mon-1)+'';		
+		var yearPre = year;
+		if(mon==1){
+			prev_mth = 12+'';
+			yearPre = yearPre-1;
+		}else{
+		var prev_mth = (mon-1)+'';	
+		}	
 		if(mon.length==1){
 		if(mon.length==1){
 			mon = "0" +mon;
 			mon = "0" +mon;
 		}
 		}
@@ -142,12 +164,38 @@ $(function(){
 		}
 		}
 		var param = {
 		var param = {
 			"mth":year + "/" + mon,
 			"mth":year + "/" + mon,
-			"prev_mth": year + "/" + prev_mth,
+			"prev_mth": yearPre + "/" + prev_mth,
 			"dept_id":select_station,
 			"dept_id":select_station,
-			"queryType":1
+			"queryType":2
 		};
 		};
 		initRqueset(url,param,6);
 		initRqueset(url,param,6);
 	}
 	}
+
+	/**
+	 * 图切换后5名
+	 */
+	function init_backward_rank_assess(url,mon,select_station){
+		var yearPre = year;
+		if(mon==1){
+			prev_mth = 12+'';
+			yearPre = yearPre-1;
+		}else{
+		var prev_mth = (mon-1)+'';	
+		}	
+		if(mon.length==1){
+			mon = "0" +mon;
+		}
+		if(prev_mth.length==1){
+			prev_mth = "0" + prev_mth;
+		}
+		var param = {
+			"mth":year + "/" + mon,
+			"dept_id":select_station,
+			"prev_mth": yearPre + "/" + prev_mth,
+			"order_type":1
+		};
+		initRqueset(url,param,7);
+	} 
 	
 	
 
 
 	/**
 	/**
@@ -169,6 +217,7 @@ $(function(){
 				// 画图
 				// 画图
 				rank_assess.setOption(progress_rank_assess());
 				rank_assess.setOption(progress_rank_assess());
 			}else if(type == 4){
 			}else if(type == 4){
+				console.log(array_score_order+"hello"+array_score_data);
 				// 画图
 				// 画图
 				score_rank.setOption(people_score_rank());
 				score_rank.setOption(people_score_rank());
 			}else if(type == 5){
 			}else if(type == 5){
@@ -177,6 +226,9 @@ $(function(){
 			}else if(type == 6){
 			}else if(type == 6){
 				// 画图
 				// 画图
 				people_points.setOption(each_people_points());
 				people_points.setOption(each_people_points());
+			}else if(type == 7){
+				// 画图
+				rank_assess_back.setOption(backward_rank_assess());
 			}
 			}
 		},function(error){
 		},function(error){
         	return "" ;
         	return "" ;
@@ -192,24 +244,28 @@ $(function(){
 		if(type == 1){
 		if(type == 1){
 			array_year_score.length = 0;
 			array_year_score.length = 0;
 			months.length = 0;
 			months.length = 0;
-			if(data!=''){
-			if(data.length<12){
-				for(var i=0;i<12-data.length;i++){
-					// 不足月份补0
-					array_year_score.push(0);
-				}
-			}		
+			if(data!='' && data.length!=0){
+				if(data.length<12){
+					for(var i=0;i<12-data.length;i++){
+						// 不足月份补0
+						array_year_score.push(0);
+					}
+				}		
 			for(var i=0;i<data.length;i++){
 			for(var i=0;i<data.length;i++){
 				if(months.indexOf(parseInt(data[i].mth.substr(5)))){
 				if(months.indexOf(parseInt(data[i].mth.substr(5)))){
 					// 指定位置插入值
 					// 指定位置插入值
 					array_year_score.splice(parseInt(data[i].mth.substr(5))-1,0,
 					array_year_score.splice(parseInt(data[i].mth.substr(5))-1,0,
-					(1000-(filter_handler(data[i].all_check_score,data[i].checked_num,data[i].people_num,0)).toFixed(1)));
+					(1000-(filter_handler(data[i].all_check_score,data[i].checked_num,data[i].people_num,0))));
 				}
 				}
 			}
 			}
 			}else{
 			}else{
 					array_year_score.length = 0;
 					array_year_score.length = 0;
 					months.length = 0;
 					months.length = 0;
-			}	
+			}
+			if(eval("Math.min(" + array_year_score.toString() + ")")==0)
+			min_year = 0;
+			else
+			min_year = 	eval("Math.min(" + array_year_score.toString() + ")").toFixed(0)-10;		
 		}else if(type == 2){
 		}else if(type == 2){
 			array_points.length=0;
 			array_points.length=0;
 				if(data!=''){
 				if(data!=''){
@@ -223,27 +279,35 @@ $(function(){
 		}else if(type == 3){
 		}else if(type == 3){
 			array_five_name.length=0;
 			array_five_name.length=0;
 			array_five_score.length=0;
 			array_five_score.length=0;
-			if(data!=''){
+			if(data!='' && data.length!=0){
 				for(var i=0;i<data.length;i++){
 				for(var i=0;i<data.length;i++){
 					array_five_name.push(data[i].user.truename);
 					array_five_name.push(data[i].user.truename);
 					array_five_score.push(data[i].ranking_change);
 					array_five_score.push(data[i].ranking_change);
 				}
 				}
-				}else{
+			}else{
 					array_five_name.length=0;
 					array_five_name.length=0;
 			        array_five_score.length=0;
 			        array_five_score.length=0;
-			    }
+			}
+			if(eval("Math.min(" + array_five_score.toString() + ")")==0)
+			min_five = 0;
+			else
+			min_five = 	eval("Math.min(" + array_five_score.toString() + ")").toFixed(0)-1;	
 		}else if(type == 4){
 		}else if(type == 4){
-		array_score_order.length=0;
-		array_score_data.length=0;
-			if(data!=''){
+			array_score_order.length=0;
+			array_score_data.length=0;
+			if(data!='' && data.length!=0){
 				for(var i=0;i<data.length;i++){
 				for(var i=0;i<data.length;i++){
 					array_score_order.push(data[i].user.truename);
 					array_score_order.push(data[i].user.truename);
-					array_score_data.push((1000-filter(data[i].all_check_score,data[i].checked_num,0)).toFixed(1));
+					array_score_data.push((1000-filter(data[i].all_check_score,data[i].checked_num,0)));
 				}
 				}
-				}else{
+			}else{
 					array_score_order.length=0;
 					array_score_order.length=0;
 					array_score_data.length=0;	
 					array_score_data.length=0;	
-			    }
+			}
+			if(eval("Math.min(" + array_score_data.toString() + ")")==0)
+			min_score = 0;
+			else
+			min_score = eval("Math.min(" + array_score_data.toString() + ")").toFixed(0)-10;
 		}else if(type == 5){
 		}else if(type == 5){
 		array_check_type.length=0;
 		array_check_type.length=0;
 				if(data.length != 0){
 				if(data.length != 0){
@@ -254,10 +318,38 @@ $(function(){
 					array_check_type.length=0;	
 					array_check_type.length=0;	
 				}
 				}
 		}else if(type == 6){
 		}else if(type == 6){
-		array_points_name.length=0;
-		array_points_pre.length=0;
-		arrar_points_month.length=0;
-		data_each_people_points(data);
+			array_points_name.length=0;
+			array_points_pre.length=0;
+			arrar_points_month.length=0;
+		if(data!='' && data.Pmth.length!=0 || data.Tmth.length!=0){
+			data_each_people_points(data);
+		}else{
+			array_points_name.length=0;
+			array_points_pre.length=0;
+			arrar_points_month.length=0;
+		}
+		}else if(type == 7){
+			array_five_name_back.length=0;
+			array_five_score_back.length=0;
+			if(data!=''){
+				for(var i=0;i<data.length;i++){
+					array_five_name_back.push(data[i].user.truename);
+					if(data[i].ranking_change<0){
+					array_five_score_back.push((data[i].ranking_change+'').substr(1));
+				}else{
+					array_five_score_back.push((data[i].ranking_change+''));
+					}
+				}
+				
+			}else{
+					array_five_name_back.length=0;
+			        array_five_score_back.length=0;
+			}
+			if(eval("Math.min(" + array_five_score_back.toString() + ")")==0){
+				min_five_back = 0;		
+			}else{
+				min_five_back = eval("Math.min(" + array_five_score_back.toString() + ")").toFixed(0)-1;
+			}
 		}
 		}
 	}
 	}
   
   
@@ -275,7 +367,7 @@ $(function(){
 				if(Tmth.length > 0){
 				if(Tmth.length > 0){
 					for(var j= 0; j< Tmth.length;j++){
 					for(var j= 0; j< Tmth.length;j++){
 						if(name[i] == Tmth[j].name && Tmth[j].all_check_score != null){
 						if(name[i] == Tmth[j].name && Tmth[j].all_check_score != null){
-							Ttemp[i] = Tmth[j].all_check_score;
+							Ttemp[i] = filter_handler(Tmth[j].all_check_score,Tmth[j].checked_num,Tmth[j].people_num,0);
 							break;
 							break;
 						}else{
 						}else{
 							Ttemp[i] = 0;
 							Ttemp[i] = 0;
@@ -287,7 +379,7 @@ $(function(){
 				if(Pmth.length > 0){
 				if(Pmth.length > 0){
 					for(var m= 0; m< Pmth.length;m++){
 					for(var m= 0; m< Pmth.length;m++){
 						if(name[i] == Pmth[m].name && Pmth[m].all_check_score != null){
 						if(name[i] == Pmth[m].name && Pmth[m].all_check_score != null){
-							Ptemp[i] = Pmth[m].all_check_score;
+							Ptemp[i] = filter_handler(Pmth[m].all_check_score,Pmth[m].checked_num,Pmth[m].people_num,0);
 							break;
 							break;
 						}else{
 						}else{
 							Ptemp[i] = 0;
 							Ptemp[i] = 0;
@@ -316,7 +408,7 @@ $(function(){
 				}
 				}
 			}
 			}
 	    }
 	    }
-		
+
     /**
     /**
 	 * 根据道管中心获取收费站列表(下拉框)
 	 * 根据道管中心获取收费站列表(下拉框)
 	 */
 	 */
@@ -346,17 +438,47 @@ $(function(){
 				sec.innerHTML='';	
 				sec.innerHTML='';	
 			}
 			}
 			var select_station = $("#second").val();
 			var select_station = $("#second").val();
+			var select_month = $(".div-month select").val();
+			echart();
 			// 页面初始化
 			// 页面初始化
 			init_tollStation_year_assess("statistics/score/year/info",select_station);
 			init_tollStation_year_assess("statistics/score/year/info",select_station);
-			init_company_points_assess("statistics/lost/score/rate",month+'',select_station);
-			init_progress_rank_assess("statistics/fs/up/five",month+'',select_station)
-			init_people_score_rank("statistics/stuff/score/info",month+'',select_station);
-			init_server_check_type("statistics/lost/itemscore/rate",month+"",select_station);
-			init_each_people_points("statistics/lost/twice/itemscore/rate",month+"",select_station);
+			init_company_points_assess("statistics/lost/score/rate",select_month+'',select_station);
+			init_progress_rank_assess("statistics/fs/up/five",select_month+'',select_station)
+			init_people_score_rank("statistics/stuff/score/info",select_month+'',select_station);
+			init_server_check_type("statistics/lost/itemscore/rate",select_month+"",select_station);
+			init_each_people_points("statistics/lost/twice/itemscore/rate",select_month+"",select_station);
+			//init_backward_rank_assess("statistics/fs/up/five",select_month+'',select_station)
 		},function(error){
 		},function(error){
         	return "" ;
         	return "" ;
     	});
     	});
     }
     }
+
+	/**
+	 * 进步前5名后退步前五名切换
+	 */
+	$(".view_change").click(function(){
+		    var select_station = $("#second").val();
+			var select_month = $(".div-month select").val();
+		if(change_echart==1){
+			$("#progress span").text("考核退步Top5排行榜");
+			$("#progress-rank-assess").css("display","none");
+			$("#backward-rank-assess").css("display","block");
+			//flag=false;
+			echart_change();	
+			init_backward_rank_assess("statistics/fs/up/five",select_month+'',select_station);
+			change_echart = 2
+			
+		}else if(change_echart==2){
+			$("#progress span").text("考核进步Top5排行榜");
+			$("#progress-rank-assess").css("display","block");
+			$("#backward-rank-assess").css("display","none");
+			//init_progress_rank_assess("statistics/fs/up/five",select_month+'',select_station);
+			// document.getElementById("progress-rank-assess").style.display="";
+			// document.getElementById("progress-rank-assess-back").style.display="none";
+			change_echart = 1
+		}
+		
+	});	
 	
 	
     /**
     /**
 	 * 除数为0处理
 	 * 除数为0处理
@@ -369,7 +491,7 @@ $(function(){
 		if(num1 == 0 || num2 == 0){
 		if(num1 == 0 || num2 == 0){
 			return num3;
 			return num3;
 		}else{
 		}else{
-			return (num/num1)/num2;
+			return ((num/num1)/num2).toFixed(2);
 		}
 		}
 	}
 	}
 
 
@@ -377,7 +499,7 @@ $(function(){
 		if(num1 == 0){
 		if(num1 == 0){
 			return num2;
 			return num2;
 		}else{
 		}else{
-			return (num/num1);
+			return (num/num1).toFixed(2);
 		}
 		}
 	}
 	}
 
 
@@ -396,15 +518,35 @@ $(function(){
 			'echarts/chart/bar',
 			'echarts/chart/bar',
 			'echarts/chart/pie'
 			'echarts/chart/pie'
 		],
 		],
-		function (ec) {
-				// 基于准备好的dom,初始化echarts图表
-				year_assess = ec.init(document.getElementById('tollStation-year-assess')); 
-				points_assess = ec.init(document.getElementById('tollStation-points-assess'));
-				rank_assess = ec.init(document.getElementById('progress-rank-assess'));
-				score_rank = ec.init(document.getElementById('people-score-rank'));
-				check_type = ec.init(document.getElementById('server-check-type'));
-				people_points = ec.init(document.getElementById('each-people-points'));
-				}
+			function (ec) {
+					// 基于准备好的dom,初始化echarts图表
+					if(flag){
+						year_assess = ec.init(document.getElementById('tollStation-year-assess'));
+					} 
+						points_assess = ec.init(document.getElementById('tollStation-points-assess'));
+						rank_assess = ec.init(document.getElementById('progress-rank-assess'));
+						score_rank = ec.init(document.getElementById('people-score-rank'));
+						check_type = ec.init(document.getElementById('server-check-type'));
+						people_points = ec.init(document.getElementById('each-people-points'));
+						rank_assess_back = ec.init(document.getElementById('backward-rank-assess'));
+			}
+	    ); 
+	}
+
+	function echart_change(){
+        require.config({
+            paths: {
+                echarts: '/js/lib/echarts/build/dist'
+            }
+        }); 
+	    require(
+		[
+			'echarts',
+			'echarts/chart/bar'
+		],
+			function (ec) {
+				rank_assess_back = ec.init(document.getElementById('backward-rank-assess'));
+			}
 	    ); 
 	    ); 
 	}
 	}
 			/**
 			/**
@@ -434,7 +576,7 @@ $(function(){
 					yAxis : [
 					yAxis : [
 						{
 						{
 							type : 'value',
 							type : 'value',
-							min : 700 ,
+							min : min_year ,
 						    max : 1000,
 						    max : 1000,
 							axisLabel : {
 							axisLabel : {
 								formatter: '{value}'
 								formatter: '{value}'
@@ -472,7 +614,7 @@ $(function(){
 			option = {
 			option = {
 				tooltip : {
 				tooltip : {
 					trigger: 'item',
 					trigger: 'item',
-					formatter: "{a} <br/>{b} : {c} ({d}%)"
+					formatter:  "收费站考核扣分占比 <br/>{b} : {d}%"
 				},
 				},
 				toolbox: {
 				toolbox: {
 					show : true,
 					show : true,
@@ -508,7 +650,7 @@ $(function(){
 		}
 		}
 
 
         /**
         /**
-		 * 图三 
+		 * 图三 前5名 
 		 */
 		 */
 		function progress_rank_assess(){
 		function progress_rank_assess(){
 			option = {
 			option = {
@@ -531,7 +673,8 @@ $(function(){
 				],
 				],
 				yAxis : [
 				yAxis : [
 					{
 					{
-						type : 'value'
+						type : 'value',
+						min : min_five
 					}
 					}
 				],
 				],
 				series : [
 				series : [
@@ -554,10 +697,60 @@ $(function(){
 					return option;
 					return option;
 	   }
 	   }
 
 
+	   /**
+		 * 图三 后5名
+		 */
+		function backward_rank_assess(){
+			option = {
+				color : [ '#00ced1' ],// 条形图颜色
+				tooltip : {
+					trigger: 'axis'
+				},
+				grid:{
+                    width:420  // 图表宽度
+                },
+				legend: {
+					data:['退步名次']
+				},
+				calculable : true,
+				xAxis : [
+					{
+						type : 'category',
+						data : array_five_name_back
+					}
+				],
+				yAxis : [
+					{
+						type : 'value',
+						min : min_five_back
+					}
+				],
+				series : [
+					{
+						name:'退步名次',
+						type:'bar',
+						data: array_five_score_back,
+					    itemStyle: {
+						normal: {
+							label: {
+								show: true,
+								position: 'insideTop'
+							}
+						}
+					},  						
+					}   
+				]
+			};
+                    		
+					return option;
+	   }
+
+
         /**
         /**
 		 * 图四
 		 * 图四
 		 */
 		 */
 		function people_score_rank(){
 		function people_score_rank(){
+			console.log(array_score_order+"-----"+array_score_data)
 					option = {
 					option = {
 				color : [ '#00ced1' ],// 条形图颜色
 				color : [ '#00ced1' ],// 条形图颜色
 				tooltip : {
 				tooltip : {
@@ -565,7 +758,8 @@ $(function(){
 				},
 				},
 				grid:{
 				grid:{
                     width:1010,  // 图表宽度
                     width:1010,  // 图表宽度
-					x:40
+					x:40,
+					x2:2,
                 },
                 },
 				legend: {
 				legend: {
 					data:['平均分']
 					data:['平均分']
@@ -580,7 +774,7 @@ $(function(){
 				yAxis : [
 				yAxis : [
 					{
 					{
 						type : 'value',
 						type : 'value',
-						min : 900 ,
+						min : min_score ,
 						max : 1000
 						max : 1000
 					}
 					}
 				],
 				],
@@ -616,7 +810,7 @@ $(function(){
 			option = {
 			option = {
 				tooltip : {
 				tooltip : {
 					trigger: 'item',
 					trigger: 'item',
-					formatter: "{a} <br/>{b} : {c} ({d}%)"
+					formatter:  "温馨服务检查占比 <br/>{b} : {d}%"
 				},
 				},
 				toolbox: {
 				toolbox: {
 					show : true,
 					show : true,
@@ -659,7 +853,8 @@ $(function(){
 				trigger: 'axis'
 				trigger: 'axis'
 			},
 			},
 			grid:{
 			grid:{
-                    width:420  // 图表宽度
+                    width:470,  // 图表宽度
+					x:60
                 },
                 },
 			legend: {
 			legend: {
 				data:['上月','本月']
 				data:['上月','本月']

+ 58 - 25
VisualInspection/js/statistics/total_company_statistics.js

@@ -19,14 +19,17 @@
 		var stationAll_rank;
 		var stationAll_rank;
 		var check_type;
 		var check_type;
 		var people_points;
 		var people_points;
+		var flag = true;
+		var min_year;
+		var min_road;
+		var min_allStation;
 $(function(){
 $(function(){
 	// 显示当前月份
 	// 显示当前月份
 	$(".div-month select").val(month);
 	$(".div-month select").val(month);
 
 
 	$(".query-company").click(function(){	
 	$(".query-company").click(function(){	
 		var select_month = $(".div-month select").val();
 		var select_month = $(".div-month select").val();
-		// 查询图一
-		init_company_year_assess();
+		flag = false;
 		// 查询图二
 		// 查询图二
 		init_company_points_assess("statistics/lost/score/rate",select_month+'');
 		init_company_points_assess("statistics/lost/score/rate",select_month+'');
 		// 查询图三
 		// 查询图三
@@ -118,7 +121,13 @@ $(function(){
 	 * 初始化图六
 	 * 初始化图六
 	 */
 	 */
     function init_each_people_points_six(url,mon){
     function init_each_people_points_six(url,mon){
-		var prev_mth = (mon-1)+'';		
+		var yearPre = year;
+		if(mon==1){
+			prev_mth = 12+'';
+			yearPre = yearPre-1;
+		}else{
+		var prev_mth = (mon-1)+'';	
+		}	
 		if(mon.length==1){
 		if(mon.length==1){
 			mon = "0" +mon;
 			mon = "0" +mon;
 		}
 		}
@@ -127,7 +136,7 @@ $(function(){
 		}
 		}
 		var param = {
 		var param = {
 			"mth":year + "/" + mon,
 			"mth":year + "/" + mon,
-			"prev_mth": year + "/" + prev_mth,
+			"prev_mth": yearPre + "/" + prev_mth,
 			"queryType":0
 			"queryType":0
 		};
 		};
 		initRqueset(url,param,6);
 		initRqueset(url,param,6);
@@ -177,24 +186,28 @@ $(function(){
 		if(type == 1){
 		if(type == 1){
 			array_year_score.length = 0;
 			array_year_score.length = 0;
 			months.length = 0;
 			months.length = 0;
-			if(data!=''){
+			if(data!='' && data.length!=0){
 			if(data.length<12){
 			if(data.length<12){
 				for(var i=0;i<12-data.length;i++){
 				for(var i=0;i<12-data.length;i++){
 					// 不足月份补0
 					// 不足月份补0
 					array_year_score.push(0);
 					array_year_score.push(0);
 				}
 				}
 			}		
 			}		
-			for(var i=0;i<data.length;i++){
-				if(months.indexOf(parseInt(data[i].mth.substr(5)))){
-					// 指定位置插入值
-					array_year_score.splice(parseInt(data[i].mth.substr(5))-1,0,
-					(1000-(filter_handler(data[i].all_check_score,data[i].checked_num,data[i].people_num,0)).toFixed(1)));
+				for(var i=0;i<data.length;i++){
+					if(months.indexOf(parseInt(data[i].mth.substr(5)))){
+						// 指定位置插入值
+						array_year_score.splice(parseInt(data[i].mth.substr(5))-1,0,
+						(1000-(filter_handler(data[i].all_check_score,data[i].checked_num,data[i].people_num,0))));
+					}
 				}
 				}
-			}
 			}else{
 			}else{
 					array_year_score.length = 0;
 					array_year_score.length = 0;
 					months.length = 0;
 					months.length = 0;
-			}	
+			}
+			if(eval("Math.min(" + array_year_score.toString() + ")")==0)
+			min_year = 0;
+			else
+			min_year = 	eval("Math.min(" + array_year_score.toString() + ")").toFixed(0)-10;
 		}else if(type == 2){
 		}else if(type == 2){
 			array_points.length=0;
 			array_points.length=0;
 			    if(data!=''){
 			    if(data!=''){
@@ -211,24 +224,32 @@ $(function(){
 			for(var i=0;i<data.length;i++){
 			for(var i=0;i<data.length;i++){
 				if(data!=''){
 				if(data!=''){
 					array_road.push(data[i].feeStationName);
 					array_road.push(data[i].feeStationName);
-					array_road_score.push((1000-(filter_handler(data[i].all_check_score,data[i].checked_num,data[i].people_num,0)).toFixed(1)));
+					array_road_score.push((1000-(filter_handler(data[i].all_check_score,data[i].checked_num,data[i].people_num,0))));
 		        }else{
 		        }else{
 					array_road.length=0;
 					array_road.length=0;
 			        array_road_score.length=0;	
 			        array_road_score.length=0;	
 				}	
 				}	
 		    }
 		    }
+			    if(eval("Math.min(" + array_road_score.toString() + ")")==0)
+				min_road = 0;
+				else
+				min_road = 	eval("Math.min(" + array_road_score.toString() + ")").toFixed(0)-10;
 		}else if(type == 4){
 		}else if(type == 4){
 			array_allStation_score.length=0;
 			array_allStation_score.length=0;
 			array_allStation.length=0;
 			array_allStation.length=0;
             for(var i=0;i<data.length;i++){
             for(var i=0;i<data.length;i++){
-				if(data!=''){
+				if(data!='' && data.length!=0){
 					array_allStation.push(data[i].feeStationName.substr(0,data[i].feeStationName.length-3));
 					array_allStation.push(data[i].feeStationName.substr(0,data[i].feeStationName.length-3));
-					array_allStation_score.push((1000-(filter_handler(data[i].all_check_score,data[i].checked_num,data[i].people_num,0)).toFixed(1)));
+					array_allStation_score.push((1000-(filter_handler(data[i].all_check_score,data[i].checked_num,data[i].people_num,0))));
 				}else{
 				}else{
 					array_allStation_score.length=0;
 					array_allStation_score.length=0;
 			        array_allStation.length=0;	
 			        array_allStation.length=0;	
 				}
 				}
 	        }
 	        }
+			    if(eval("Math.min(" + array_allStation_score.toString() + ")")==0)
+				min_allStation = 0;
+				else
+				min_allStation = eval("Math.min(" + array_allStation_score.toString() + ")").toFixed(0)-10;
 		}else if(type == 5){
 		}else if(type == 5){
 			array_check_type = [];
 			array_check_type = [];
                 if(data.length != 0){
                 if(data.length != 0){
@@ -242,7 +263,13 @@ $(function(){
 			array_points_name.length=0;
 			array_points_name.length=0;
 			array_points_pre.length=0;
 			array_points_pre.length=0;
 			arrar_points_month.length=0;
 			arrar_points_month.length=0;
-			data_each_people_points(data);
+			if(data!='' && data.Pmth.length!=0 || data.Tmth.length!=0){
+			  	data_each_people_points(data);
+			}else{
+				array_points_name.length=0;
+				array_points_pre.length=0;
+				arrar_points_month.length=0;
+			}   
 		}
 		}
 	}
 	}
 
 
@@ -260,7 +287,7 @@ $(function(){
 				if(Tmth.length > 0){
 				if(Tmth.length > 0){
 					for(var j= 0; j< Tmth.length;j++){
 					for(var j= 0; j< Tmth.length;j++){
 						if(name[i] == Tmth[j].name && Tmth[j].all_check_score != null){
 						if(name[i] == Tmth[j].name && Tmth[j].all_check_score != null){
-							Ttemp[i] = Tmth[j].all_check_score;
+							Ttemp[i] = filter_handler(Tmth[j].all_check_score,Tmth[j].checked_num,Tmth[j].people_num,0);
 							break;
 							break;
 						}else{
 						}else{
 							Ttemp[i] = 0;
 							Ttemp[i] = 0;
@@ -272,7 +299,7 @@ $(function(){
 				if(Pmth.length > 0){
 				if(Pmth.length > 0){
 					for(var m= 0; m< Pmth.length;m++){
 					for(var m= 0; m< Pmth.length;m++){
 						if(name[i] == Pmth[m].name && Pmth[m].all_check_score != null){
 						if(name[i] == Pmth[m].name && Pmth[m].all_check_score != null){
-							Ptemp[i] = Pmth[m].all_check_score;
+							Ptemp[i] = filter_handler(Pmth[m].all_check_score,Pmth[m].checked_num,Pmth[m].people_num,0);
 							break;
 							break;
 						}else{
 						}else{
 							Ptemp[i] = 0;
 							Ptemp[i] = 0;
@@ -313,7 +340,7 @@ $(function(){
 		if(num1 == 0 || num2 == 0){
 		if(num1 == 0 || num2 == 0){
 			return num4;
 			return num4;
 		}else{
 		}else{
-			return (num/num1)/num2;
+			return ((num/num1)/num2).toFixed(2);
 		}
 		}
 	}
 	}
 	
 	
@@ -337,7 +364,9 @@ $(function(){
 			],
 			],
 		function (ec) {
 		function (ec) {
 				// 基于准备好的dom,初始化echarts图表
 				// 基于准备好的dom,初始化echarts图表
-				year_assess = ec.init(document.getElementById('company-year-assess')); 
+				if(flag){
+					year_assess = ec.init(document.getElementById('company-year-assess')); 
+				}
 				points_assess = ec.init(document.getElementById('company-points-assess'));
 				points_assess = ec.init(document.getElementById('company-points-assess'));
 				score_rank = ec.init(document.getElementById('roadManager-score-rank'));
 				score_rank = ec.init(document.getElementById('roadManager-score-rank'));
 				stationAll_rank = ec.init(document.getElementById('company-stationAll-rank'));
 				stationAll_rank = ec.init(document.getElementById('company-stationAll-rank'));
@@ -375,7 +404,7 @@ $(function(){
 					yAxis : [
 					yAxis : [
 						{
 						{
 							type : 'value',
 							type : 'value',
-							min : 900 ,
+							min : min_year ,
 						    max : 1000,
 						    max : 1000,
 							axisLabel : {
 							axisLabel : {
 								formatter: '{value}'
 								formatter: '{value}'
@@ -413,7 +442,7 @@ $(function(){
 			option = {
 			option = {
 				tooltip : {
 				tooltip : {
 					trigger: 'item',
 					trigger: 'item',
-					formatter: "{a} <br/>{b} : {c} ({d}%)"
+					formatter:  "公司考核扣分占比 <br/>{b} : {d}%"
 				},
 				},
 				toolbox: {
 				toolbox: {
 					show : true,
 					show : true,
@@ -468,7 +497,7 @@ $(function(){
 				yAxis : [
 				yAxis : [
 					{
 					{
 						type : 'value',
 						type : 'value',
-						min : 900 ,
+						min : min_road ,
 						max : 1000
 						max : 1000
 					}
 					}
 				],
 				],
@@ -519,7 +548,7 @@ $(function(){
 				yAxis : [
 				yAxis : [
 					{
 					{
 						type : 'value',
 						type : 'value',
-						min : 900 ,
+						min : min_allStation ,
 						max : 1000
 						max : 1000
 					}
 					}
 				],
 				],
@@ -555,7 +584,7 @@ $(function(){
 			option = {
 			option = {
 				tooltip : {
 				tooltip : {
 					trigger: 'item',
 					trigger: 'item',
-					formatter: "{a} <br/>{b} : {c} ({d}%)"
+					formatter:  "温馨服务检查占比 <br/>{b} : {d}%"
 				},
 				},
 				toolbox: {
 				toolbox: {
 					show : true,
 					show : true,
@@ -597,6 +626,10 @@ $(function(){
 			tooltip : {
 			tooltip : {
 				trigger: 'axis'
 				trigger: 'axis'
 			},
 			},
+			grid:{
+                    width:470,  // 图表宽度
+					x:60
+                },
 			legend: {
 			legend: {
 				data:['上月','本月']
 				data:['上月','本月']
 			},
 			},

+ 2 - 1
VisualInspection/view/statistics/check_workload_statistics.html

@@ -18,7 +18,8 @@
     <div class="row-3">
     <div class="row-3">
        <table class="table table-bordered" style="text-align:center;">
        <table class="table table-bordered" style="text-align:center;">
            <tr><td>总稽查人数</td><td>总稽查任务数</td><td>总稽查时长</td><td>考核人员数量</td><td>总扣分数</td><td>平均人次扣分数</td></tr>
            <tr><td>总稽查人数</td><td>总稽查任务数</td><td>总稽查时长</td><td>考核人员数量</td><td>总扣分数</td><td>平均人次扣分数</td></tr>
-           <tr><td>15</td><td>150</td><td>1小时20分</td><td>20</td><td>3000</td><td>200</td></tr>
+           <tr><td class="all_check_personal"></td><td class="all_check_task"></td><td class="all_check_minute"></td>
+               <td class="all_checkman"></td><td class="all_check_score"></td><td class="check_score_avg"></td></tr>
        </table>
        </table>
     </div>
     </div>
 
 

+ 22 - 16
VisualInspection/view/statistics/emp_ranking.html

@@ -55,16 +55,19 @@
                     <table border="1" width="100%"  align="center">
                     <table border="1" width="100%"  align="center">
                         <thead class="table-thead" align="center">
                         <thead class="table-thead" align="center">
                             <tr>
                             <tr>
-                            <th rowspan="2" width="67px;">序号</th><th rowspan="2" width="87px">站名</th><th rowspan="2" width="67px">姓名</th>
-                            <th rowspan="2" width="67px">岗位</th><th rowspan="2" width="87px">工号</th><th colspan="9" height="40px">考核扣分</th>
-                            <th rowspan="2" width="67px">受检次数</th><th rowspan="2" width="67px">平均扣分(千分制)</th><th rowspan="2" width="55px">得分</th>
-                            <th rowspan="2" width="58px">服务评价</th><th rowspan="2"  width="58px">备注</th>
+                            <th rowspan="2" width="4%;">序号</th><th rowspan="2" width="6%">站名</th>
+                            <th rowspan="2" width="6%">姓名</th><th rowspan="2" width="6%">岗位</th>
+                            <th rowspan="2" width="7%">工号</th><th rowspan="2" width="4%">公司排名</th>
+                            <th rowspan="2" width="4%">道管排名</th><th rowspan="2" width="4%">收费站排名</th>
+                            <th colspan="9" height="40px">考核扣分</th><th rowspan="2" width="4%">受检次数</th>
+                            <th rowspan="2" width="4%">平均扣分(千分制)</th><th rowspan="2" width="4%">得分</th>
+                            <th rowspan="2" width="4%">服务评价</th><th rowspan="2" width="4%">备注</th>
                             </tr>
                             </tr>
                             <tr> 
                             <tr> 
-                            <th width="58px">环境卫生</th><th width="58px">仪容仪表</th><th width="58px">表情</th>
-                            <th width="58px">收费动作</th><th width="58px">文明用语</th><th width="58px">工作纪律</th>
-                            <th width="58px">便民服务</th><th width="58px">安全管理</th>
-                            <th width="58px">扣分合计</th>
+                            <th width="4%">环境卫生</th><th width="4%">仪容仪表</th><th width="4%">表情</th>
+                            <th width="4%">收费动作</th><th width="4%">文明用语</th><th width="4%">工作纪律</th>
+                            <th width="4%">便民服务</th><th width="4%">安全管理</th>
+                            <th width="4%">扣分合计</th>
                             </tr>
                             </tr>
                         </thead>
                         </thead>
                     </table>
                     </table>
@@ -74,16 +77,19 @@
                  <table style="border-top:0;" border="1" width="100%"  align="center">
                  <table style="border-top:0;" border="1" width="100%"  align="center">
                     <thead class="table-thead" style="height:0;" align="center">
                     <thead class="table-thead" style="height:0;" align="center">
                         <tr style="display:none;">
                         <tr style="display:none;">
-                            <th rowspan="2" width="67px;">序号</th><th rowspan="2" width="87px">站名</th><th rowspan="2" width="67px">姓名</th>
-                            <th rowspan="2" width="67px">岗位</th><th rowspan="2" width="87px">工号</th><th colspan="9" height="40px">考核扣分</th>
-                            <th rowspan="2" width="67px">受检次数</th><th rowspan="2" width="67px">平均扣分(千分制)</th><th rowspan="2" width="55px">得分</th>
-                            <th rowspan="2" width="58px">服务评价</th><th rowspan="2"  width="58px">备注</th>
+                            <th rowspan="2" width="4%;">序号</th><th rowspan="2" width="6%">站名</th>
+                            <th rowspan="2" width="6%">姓名</th><th rowspan="2" width="6%">岗位</th>
+                            <th rowspan="2" width="7%">工号</th><th rowspan="2" width="4%">公司排名</th>
+                            <th rowspan="2" width="4%">道管排名</th><th rowspan="2" width="4%">收费站排名</th>
+                            <th colspan="9" height="40px">考核扣分</th><th rowspan="2" width="4%">受检次数</th>
+                            <th rowspan="2" width="4%">平均扣分(千分制)</th><th rowspan="2" width="4%">得分</th>
+                            <th rowspan="2" width="4%">服务评价</th><th rowspan="2" width="4%">备注</th>
                         </tr>
                         </tr>
                         <tr style="display:none;"> 
                         <tr style="display:none;"> 
-                            <th width="58px">环境卫生</th><th width="58px">仪容仪表</th><th width="58px">表情</th>
-                            <th width="58px">收费动作</th><th width="58px">文明用语</th><th width="58px">工作纪律</th>
-                            <th width="58px">便民服务</th><th width="58px">安全管理</th>
-                            <th width="58px">扣分合计</th>
+                            <th width="4%">环境卫生</th><th width="4%">仪容仪表</th><th width="4%">表情</th>
+                            <th width="4%">收费动作</th><th width="4%">文明用语</th><th width="4%">工作纪律</th>
+                            <th width="4%">便民服务</th><th width="4%">安全管理</th>
+                            <th width="4%">扣分合计</th>
                         </tr>
                         </tr>
                     </thead>
                     </thead>
                     <tbody class="table-tbody" style="background:white; " align="center">
                     <tbody class="table-tbody" style="background:white; " align="center">

+ 8 - 6
VisualInspection/view/statistics/personal_data_statistics.html

@@ -6,8 +6,11 @@
     <div class="line-1"></div>
     <div class="line-1"></div>
     <div class="row-2">
     <div class="row-2">
         <div>
         <div>
-            <div class="name"><span>刘娟</span></div>
-            <div class="div-select div-button"><button>选择人员</button></div>
+            <!--<div class="name"><span>刘娟</span></div>
+            <div class="div-select div-button"><button>选择人员</button></div>-->
+            <div class="name1"><span>请选择收费站:</span></div>
+            <div class="div-select"><select id="select-dept"></select></button></div>
+            <div class="div-select"><select id="select-personal"></select></button></div>
             <div class="div-start"><input placeholder="请选择考核开始时间"></input></div>
             <div class="div-start"><input placeholder="请选择考核开始时间"></input></div>
             <div class="div-to"><label>-</label></div>
             <div class="div-to"><label>-</label></div>
             <div class="div-end"><input placeholder="请选择考核结束时间"></input></div>
             <div class="div-end"><input placeholder="请选择考核结束时间"></input></div>
@@ -17,7 +20,7 @@
         </div>
         </div>
     </div> 
     </div> 
     <div class="line-1"></div>
     <div class="line-1"></div>
-    <div class="row-3">
+    <!--<div class="row-3">
         <div class="dept">
         <div class="dept">
             <div style="margin-top:14px;">
             <div style="margin-top:14px;">
             <span>部门</span><br/><br/>   
             <span>部门</span><br/><br/>   
@@ -47,8 +50,7 @@
             <span style="margin-left:50px;">总扣分:</span><span>120</span>
             <span style="margin-left:50px;">总扣分:</span><span>120</span>
             <span style="margin-left:50px;">平均单项扣分:</span><span>11</span>
             <span style="margin-left:50px;">平均单项扣分:</span><span>11</span>
         </div>
         </div>
-    </div>
-    <div class="line-1"></div>
+    </div>-->
 
 
     <div class="row" style="width:100%;margin:0 auto;">
     <div class="row" style="width:100%;margin:0 auto;">
             <!-- 使用一个div来显示数据表格 -->
             <!-- 使用一个div来显示数据表格 -->
@@ -69,7 +71,7 @@
 </div>
 </div>
 <script>
 <script>
     $(document).ready(function() {
     $(document).ready(function() {
-
+        
         // 仅选择日期
         // 仅选择日期
         $(".div-start input").datetimepicker(
         $(".div-start input").datetimepicker(
         {
         {

+ 3 - 1
VisualInspection/view/statistics/toll_station_statistics.html

@@ -37,12 +37,14 @@
     <div class="border-line">
     <div class="border-line">
     <div class="row-4">
     <div class="row-4">
         <div class="col-1"><span>收费站考核扣分情况占比</span></div><div class="line-2"></div>
         <div class="col-1"><span>收费站考核扣分情况占比</span></div><div class="line-2"></div>
-        <div class="col-1"><span>考核进步Top5排行榜</span></div>
+        <div class="col-1" id="progress"><span>考核进步Top5排行榜</span><div class="btn-change"><button class="view_change">切换</button></div></div>
+        <div class="col-1" id="backward" style="display:none;"><span>考核退步Top5排行榜</span></div>
     </div>
     </div>
     <div class="row-5">
     <div class="row-5">
         <div id="tollStation-points-assess" style="width:49%;height:400px;float:left;"></div>
         <div id="tollStation-points-assess" style="width:49%;height:400px;float:left;"></div>
         <div class="line-3"></div>
         <div class="line-3"></div>
         <div id="progress-rank-assess" style="width:49%;height:400px;float:left;"></div>
         <div id="progress-rank-assess" style="width:49%;height:400px;float:left;"></div>
+        <div id="backward-rank-assess" style="display:none;width:49%;height:400px;float:left;"></div>
     </div>
     </div>
     </div>
     </div>