|
|
@@ -31,7 +31,7 @@
|
|
|
$(function(){
|
|
|
setVisit();
|
|
|
// 公用方法,根据当前年月动态将13个月push数组
|
|
|
- // month_method();
|
|
|
+ month_method();
|
|
|
// 公用方法,月份下拉框
|
|
|
// select_option();
|
|
|
$.jeDate("#month_date",{
|
|
|
@@ -46,16 +46,30 @@ $(function(){
|
|
|
// 回显当前年月份
|
|
|
// $(".div-month select").val(initDate);
|
|
|
setSecond();
|
|
|
-
|
|
|
+ refresh(true);
|
|
|
$(".div-button button").click(function(){
|
|
|
- var select_month = $("month_date").val();
|
|
|
+ refresh(false);
|
|
|
+ });
|
|
|
+
|
|
|
+ // 加载图配置
|
|
|
+ // echart();
|
|
|
+
|
|
|
+ // 如果道管中心下拉框改变,点击时加载图一
|
|
|
+ $(".div-station select").change(function(){
|
|
|
+ flag = true;
|
|
|
+ });
|
|
|
+
|
|
|
+ function refresh(flag){
|
|
|
+ var select_month = $("#month_date").val();
|
|
|
var select_station = $(".div-station select").val();
|
|
|
// 加载图配置
|
|
|
- echart();
|
|
|
+ echart(flag);
|
|
|
+ echart_change();
|
|
|
+ echart_change2();
|
|
|
if(flag ==true ){
|
|
|
init_tollStation_year_assess("statistics/score/year/info",select_station);
|
|
|
}
|
|
|
- flag = false;
|
|
|
+ // flag = false;
|
|
|
|
|
|
top5_change(select_month,select_station);
|
|
|
// 查询图二
|
|
|
@@ -63,29 +77,22 @@ $(function(){
|
|
|
// 查询图四
|
|
|
init_people_score_rank("statistics/stuff/score/info",select_month+'',select_station);
|
|
|
// 查询图五
|
|
|
+ console.log(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);
|
|
|
- });
|
|
|
-
|
|
|
- // 加载图配置
|
|
|
- echart();
|
|
|
-
|
|
|
- // 如果道管中心下拉框改变,点击时加载图一
|
|
|
- $(".div-station select").change(function(){
|
|
|
- flag = true;
|
|
|
- });
|
|
|
-
|
|
|
+ }
|
|
|
/**
|
|
|
* 初始化图一
|
|
|
*/
|
|
|
function init_tollStation_year_assess(url,select_station){
|
|
|
var param = {
|
|
|
- "start_date":(year-1)+"-"+new Date().getMonth()+"-25"+" 23:00:00",
|
|
|
- "end_date":year+"-"+new Date().getMonth()+"-25"+" 23:00:00",
|
|
|
+ "start_date":(year-1)+"-"+"12-25"+" 23:00:00",
|
|
|
+ "end_date":year+"-"+"12-25"+" 23:00:00",
|
|
|
"dept_id":select_station,
|
|
|
"queryType":2
|
|
|
- }
|
|
|
+ }
|
|
|
+ console.log(param);
|
|
|
initRqueset(url,param,1);
|
|
|
}
|
|
|
|
|
|
@@ -208,7 +215,7 @@ $(function(){
|
|
|
* @param {*} type
|
|
|
*/
|
|
|
function initRqueset(url,param,type){
|
|
|
- post_common_service( url,param,function(data){
|
|
|
+ post_common_service(url,param,function(data){
|
|
|
data_array(data,type);
|
|
|
if(type == 1){
|
|
|
// 画图
|
|
|
@@ -243,6 +250,7 @@ $(function(){
|
|
|
* @param {*} type
|
|
|
*/
|
|
|
function data_array(data,type){
|
|
|
+
|
|
|
if(type == 1){
|
|
|
array_year_score.length = 0;
|
|
|
if(data!='' && data.length!=0){
|
|
|
@@ -468,7 +476,7 @@ $(function(){
|
|
|
if(roleContains("STATION")){
|
|
|
dept = getCurrentUser().organid;
|
|
|
}
|
|
|
- refresh(feeList,dept);
|
|
|
+ refreshFee(feeList,dept);
|
|
|
// var param = {
|
|
|
// "parentid":select_road
|
|
|
// }
|
|
|
@@ -479,7 +487,7 @@ $(function(){
|
|
|
// });
|
|
|
}
|
|
|
|
|
|
- function refresh(data,selectId){
|
|
|
+ function refreshFee(data,selectId){
|
|
|
var sec = document.getElementById('second');
|
|
|
var tempStr = ''
|
|
|
if(data.length!=0){
|
|
|
@@ -499,18 +507,18 @@ $(function(){
|
|
|
}else{
|
|
|
sec.innerHTML='';
|
|
|
}
|
|
|
- // 页面初始化
|
|
|
- var select_month = $("#month_date").val();
|
|
|
- var select_station = $("#second").val();
|
|
|
- echart();
|
|
|
- // 进退步top5
|
|
|
- top5_change(select_month,select_station);
|
|
|
- init_tollStation_year_assess("statistics/score/year/info",select_station);
|
|
|
- init_company_points_assess("statistics/lost/score/rate",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);
|
|
|
- flag = false;
|
|
|
+ // // 页面初始化
|
|
|
+ // var select_month = $("#month_date").val();
|
|
|
+ // var select_station = $("#second").val();
|
|
|
+ // echart();
|
|
|
+ // // 进退步top5
|
|
|
+ // top5_change(select_month,select_station);
|
|
|
+ // init_tollStation_year_assess("statistics/score/year/info",select_station);
|
|
|
+ // init_company_points_assess("statistics/lost/score/rate",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);
|
|
|
+ // flag = false;
|
|
|
}
|
|
|
/**
|
|
|
* 进步前5名后退步前五名切换
|
|
|
@@ -569,25 +577,25 @@ $(function(){
|
|
|
/**
|
|
|
* 其它图配置
|
|
|
*/
|
|
|
- function echart(){
|
|
|
- echart_config(1);
|
|
|
+ function echart(flag){
|
|
|
+ echart_config(1,flag);
|
|
|
}
|
|
|
/**
|
|
|
* 进步top5图配置
|
|
|
*/
|
|
|
function echart_change2(){
|
|
|
- echart_config(2);
|
|
|
+ echart_config(2,false);
|
|
|
}
|
|
|
/**
|
|
|
* 退步top5图配置
|
|
|
*/
|
|
|
function echart_change(){
|
|
|
- echart_config(3);
|
|
|
+ echart_config(3,false);
|
|
|
}
|
|
|
/**
|
|
|
* 图配置
|
|
|
*/
|
|
|
- function echart_config(type){
|
|
|
+ function echart_config(type,flag){
|
|
|
require.config({
|
|
|
paths: {
|
|
|
echarts: '/js/lib/echarts/build/dist'
|