//var baseUrl = 'http://cgsu81beft.51xd.pub';
var baseUrl = "http://39.101.167.152:8088/shekecaiji";
var testUrl = "http://192.168.3.104:8000/jobslink-api/jkworksreport"
console.log(document.cookie)
// 获取cookie
function getCookie(cookieName) {
var cookies = document.cookie.split("; ");
for (var i = 0; i < cookies.length; i++) {
var cookie = cookies[i].split("=");
if (cookie[0] === cookieName) {
return cookie[1];
}
}
return "";
}
var allData = {"citys":[{"name":"延寿","value":[128.331644,45.451897,2],"symbolSize":20,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"临江","value":[126.918087,41.811979,2],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"嘉兴","value":[120.755486,30.746129,4],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"四平","value":[124.350398,43.16642,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"营口","value":[122.235418,40.667012,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"密云","value":[116.801346,40.35874,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"威海","value":[122.12042,37.513068,32],"symbolSize":3,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"杭州","value":[120.15507,30.274085,10],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"集安","value":[126.194031,41.125307,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"贵阳","value":[106.630154,26.647661,2],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"抚顺","value":[123.957208,41.880872,3],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"海门","value":[121.181615,31.871173,2],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"珠海","value":[113.576726,22.270715,9],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"河北","value":[114.475704,38.584854,-19],"symbolSize":2,"itemStyle":{"normal":{"color":"#58B3CC"}}},
{"name":"深圳","value":[114.057868,22.543099,14],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"黄浦","value":[121.484443,31.231763,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"蓬莱","value":[120.758848,37.810661,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"吉林","value":[126.549572,43.837883,-364],"symbolSize":14,"itemStyle":{"normal":{"color":"#58B3CC"}}},
{"name":"甘肃","value":[103.826308,36.059421,-2],"symbolSize":2,"itemStyle":{"normal":{"color":"#58B3CC"}}},
{"name":"龙井","value":[129.427066,42.766311,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"茂名","value":[110.925456,21.662999,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"丹东","value":[124.354707,40.0005,2],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"晋中","value":[112.752695,37.687024,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"浙江","value":[120.152792,30.267447,-2],"symbolSize":2,"itemStyle":{"normal":{"color":"#58B3CC"}}},
{"name":"海城","value":[122.685217,40.882377,2],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"溆浦","value":[110.594921,27.908281,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"北京","value":[116.407526,39.90403,-14],"symbolSize":2,"itemStyle":{"normal":{"color":"#58B3CC"}}},
{"name":"铁岭","value":[123.726166,42.223769,2],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"大同","value":[113.61244,40.040295,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"金坛","value":[119.597897,31.723247,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"齐齐哈尔","value":[126.661669,45.742347,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"咸阳","value":[108.708991,34.329605,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"四川","value":[104.075931,30.651652,-5],"symbolSize":2,"itemStyle":{"normal":{"color":"#58B3CC"}}},
{"name":"福田","value":[114.055036,22.52153,2],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"盘锦","value":[122.070714,41.119997,3],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"中山","value":[113.392782,22.517646,4],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"福建","value":[119.295144,26.10078,-1],"symbolSize":2,"itemStyle":{"normal":{"color":"#58B3CC"}}},
{"name":"泰顺","value":[119.717649,27.556884,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"宝山","value":[131.401589,46.577167,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"庆安","value":[127.507825,46.880102,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"海淀","value":[116.298056,39.959912,32],"symbolSize":3,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"大兴","value":[116.341395,39.726929,3],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"桦川","value":[130.719081,47.023001,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"惠州","value":[114.416196,23.111847,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"青岛","value":[120.38264,36.067082,52],"symbolSize":3,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"朝阳","value":[116.443108,39.92147,17],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"沈阳","value":[123.431475,41.805698,41],"symbolSize":3,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"菏泽","value":[115.480656,35.23375,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"南通","value":[120.894291,31.980172,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"南充","value":[106.110698,30.837793,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"双城","value":[126.312745,45.383263,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"南京","value":[118.796877,32.060255,17],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"新疆","value":[87.627704,43.793026,-2],"symbolSize":2,"itemStyle":{"normal":{"color":"#58B3CC"}}},
{"name":"成都","value":[104.066541,30.572269,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"陕西","value":[108.954239,34.265472,-2],"symbolSize":2,"itemStyle":{"normal":{"color":"#58B3CC"}}},
{"name":"黄岛","value":[120.04619,35.872664,2],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"温州","value":[120.699367,27.994267,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"石家庄","value":[114.51486,38.042307,4],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"邢台","value":[114.504844,37.070589,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"赣州","value":[114.93503,25.831829,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"义乌","value":[120.075058,29.306841,3],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"南昌","value":[115.858198,28.682892,2],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"闵行","value":[121.381709,31.112813,18],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"长宁","value":[121.424624,31.220367,7],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"道里","value":[126.616957,45.755777,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"乳山","value":[121.539765,36.919816,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"双流","value":[103.923648,30.574473,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"广州","value":[113.264435,23.129163,13],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"西城","value":[116.365868,39.912289,4],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"佳木斯","value":[130.318917,46.799923,2],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"皇姑","value":[123.44197,41.824796,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"榆树","value":[126.533146,44.840288,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"临汾","value":[111.518976,36.088005,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"上海","value":[121.473701,31.230416,44],"symbolSize":3,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"内蒙古","value":[111.765618,40.817498,-23],"symbolSize":2,"itemStyle":{"normal":{"color":"#58B3CC"}}},
{"name":"尚志","value":[128.009895,45.209586,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"湖里","value":[118.146769,24.512905,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}}
,{"name":"台州","value":[121.420757,28.656386,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"潍坊","value":[119.161756,36.706774,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"苏州","value":[120.585316,31.298886,14],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"房山","value":[116.143267,39.749144,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"即墨","value":[120.447128,36.389639,15],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"舒兰","value":[126.965607,44.406106,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"延吉","value":[129.508946,42.891255,3],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"三河","value":[117.078295,39.982718,4],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"大连","value":[121.614682,38.914003,40],"symbolSize":3,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"辉南","value":[126.046912,42.684993,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"无锡","value":[120.31191,31.49117,14],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"常州","value":[119.973987,31.810689,4],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"广西","value":[108.327546,22.815478,-1],"symbolSize":2,"itemStyle":{"normal":{"color":"#58B3CC"}}},
{"name":"泉州","value":[118.675676,24.874132,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"昌平","value":[116.231204,40.22066,4],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"海阳","value":[121.158434,36.776378,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"郑州","value":[113.625368,34.7466,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"东城","value":[116.416357,39.928353,10],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"黄骅","value":[117.330048,38.371383,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"武侯","value":[104.04339,30.641982,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"鸡东","value":[131.12408,45.260412,2],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"龙口","value":[120.477813,37.646108,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"汤原","value":[129.905072,46.730706,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"湖北","value":[114.341862,30.546498,-4],"symbolSize":2,"itemStyle":{"normal":{"color":"#58B3CC"}}},
{"name":"克拉玛依","value":[84.889207,45.579889,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"厦门","value":[118.089425,24.479834,3],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"哈尔滨","value":[126.534967,45.803775,8],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"秦皇岛","value":[119.600493,39.935385,7],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"江苏","value":[118.763232,32.061707,-1],"symbolSize":2,"itemStyle":{"normal":{"color":"#58B3CC"}}},
{"name":"常熟","value":[120.752481,31.654376,4],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"烟台","value":[121.447935,37.463822,24],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"和平","value":[117.21451,39.116949,4],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"环翠","value":[122.123444,37.501991,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"宣武门外东大街","value":[116.378888,39.899332,3],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"张家港","value":[120.553284,31.870367,4],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"临安","value":[119.724733,30.233873,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"延安","value":[109.489727,36.585455,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"天津","value":[117.200983,39.084158,28],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"城阳","value":[120.39631,36.307064,15],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"石景山","value":[116.222982,39.906611,3],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"长沙","value":[112.938814,28.228209,5],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"安徽","value":[117.284923,31.861184,-1],"symbolSize":2,"itemStyle":{"normal":{"color":"#58B3CC"}}},
{"name":"昆山","value":[120.980737,31.385598,4],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"徐汇","value":[121.436525,31.188523,2],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"东港","value":[124.152705,39.863008,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"廊坊","value":[116.683752,39.538047,4],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"鞍山","value":[122.994329,41.108647,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"海陵","value":[119.919425,32.491016,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"黑龙江","value":[126.661669,45.742347,-198],"symbolSize":8,"itemStyle":{"normal":{"color":"#58B3CC"}}},
{"name":"西藏","value":[91.117212,29.646923,-1],"symbolSize":2,"itemStyle":{"normal":{"color":"#58B3CC"}}},
{"name":"河南","value":[113.274379,34.445122,0],"symbolSize":2,"itemStyle":{"normal":{"color":"#58B3CC"}}},
{"name":"湖南","value":[112.98381,28.112444,-1],"symbolSize":2,"itemStyle":{"normal":{"color":"#58B3CC"}}},
{"name":"佛山","value":[113.121416,23.021548,2],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"珲春","value":[130.366036,42.862821,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"扬州","value":[119.412966,32.39421,5],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"日照","value":[119.526888,35.416377,2],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"唐山","value":[118.180194,39.630867,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"同江","value":[132.510919,47.642707,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"荣成","value":[122.486658,37.16516,4],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"虎林","value":[132.93721,45.762686,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"武汉","value":[114.305393,30.593099,2],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"合肥","value":[117.227239,31.820587,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"荆州","value":[112.239741,30.335165,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"丰台","value":[116.287149,39.858427,3],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"山东","value":[117.020359,36.66853,-6],"symbolSize":2,"itemStyle":{"normal":{"color":"#58B3CC"}}},
{"name":"舟山","value":[122.207216,29.985295,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"连云港","value":[119.221611,34.596653,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"西安","value":[108.940175,34.341568,3],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"济南","value":[117.12,36.651216,4],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"绵阳","value":[104.679114,31.46745,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"辽宁","value":[123.42944,41.835441,-58],"symbolSize":3,"itemStyle":{"normal":{"color":"#58B3CC"}}},
{"name":"山西","value":[112.562398,37.873532,-3],"symbolSize":2,"itemStyle":{"normal":{"color":"#58B3CC"}}},
{"name":"呼和浩特","value":[111.749181,40.842585,2],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"河西","value":[117.223372,39.109563,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"兴和","value":[113.834173,40.872301,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"重庆","value":[106.551557,29.56301,2],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"胶州","value":[120.033382,36.26468,5],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"宁波","value":[121.550357,29.874557,10],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"滨海","value":[119.820831,33.990334,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"太原","value":[112.548879,37.87059,2],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"鸡西","value":[130.969333,45.295075,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"兰山","value":[118.347707,35.051729,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"阳泉","value":[113.580519,37.856972,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"勃利","value":[130.592171,45.755063,1],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}},
{"name":"长春","value":[125.323544,43.817072,8],"symbolSize":2,"itemStyle":{"normal":{"color":"#F58158"}}}],
"moveLines":[{"fromName":"黑龙江","toName":"珠海","coords":[[126.661669,45.742347],[113.576726,22.270715]]},
{"fromName":"黑龙江","toName":"舒兰","coords":[[126.661669,45.742347],[126.965607,44.406106]]},
{"fromName":"黑龙江","toName":"大连","coords":[[126.661669,45.742347],[121.614682,38.914003]]},
{"fromName":"辽宁","toName":"集安","coords":[[123.42944,41.835441],[126.194031,41.125307]]},
{"fromName":"吉林","toName":"抚顺","coords":[[126.549572,43.837883],[123.957208,41.880872]]},
{"fromName":"山东","toName":"南京","coords":[[117.020359,36.66853],[118.796877,32.060255]]},
{"fromName":"北京","toName":"沈阳","coords":[[116.407526,39.90403],[123.431475,41.805698]]},
{"fromName":"黑龙江","toName":"环翠","coords":[[126.661669,45.742347],[122.123444,37.501991]]},
{"fromName":"天津","toName":"大连","coords":[[117.200983,39.084158],[121.614682,38.914003]]},
{"fromName":"吉林","toName":"兴和","coords":[[126.549572,43.837883],[113.834173,40.872301]]},
{"fromName":"河北","toName":"勃利","coords":[[114.475704,38.584854],[130.592171,45.755063]]},
{"fromName":"吉林","toName":"大连","coords":[[126.549572,43.837883],[121.614682,38.914003]]},
{"fromName":"吉林","toName":"沈阳","coords":[[126.549572,43.837883],[123.431475,41.805698]]},
{"fromName":"黑龙江","toName":"闵行","coords":[[126.661669,45.742347],[121.381709,31.112813]]},
{"fromName":"天津","toName":"朝阳","coords":[[117.200983,39.084158],[116.443108,39.92147]]},
{"fromName":"吉林","toName":"黄岛","coords":[[126.549572,43.837883],[120.04619,35.872664]]},
{"fromName":"内蒙古","toName":"上海","coords":[[111.765618,40.817498],[121.473701,31.230416]]},
{"fromName":"内蒙古","toName":"南京","coords":[[111.765618,40.817498],[118.796877,32.060255]]},
{"fromName":"辽宁","toName":"杭州","coords":[[123.42944,41.835441],[120.15507,30.274085]]},
{"fromName":"黑龙江","toName":"海城","coords":[[126.661669,45.742347],[122.685217,40.882377]]},
{"fromName":"吉林","toName":"西城","coords":[[126.549572,43.837883],[116.365868,39.912289]]},
{"fromName":"四川","toName":"上海","coords":[[104.075931,30.651652],[121.473701,31.230416]]},
{"fromName":"黑龙江","toName":"西城","coords":[[126.661669,45.742347],[116.365868,39.912289]]},
{"fromName":"吉林","toName":"丹东","coords":[[126.549572,43.837883],[124.354707,40.0005]]},
{"fromName":"吉林","toName":"宁波","coords":[[126.549572,43.837883],[121.550357,29.874557]]},
{"fromName":"辽宁","toName":"海淀","coords":[[123.42944,41.835441],[116.298056,39.959912]]},
{"fromName":"辽宁","toName":"青岛","coords":[[123.42944,41.835441],[120.38264,36.067082]]},
{"fromName":"吉林","toName":"苏州","coords":[[126.549572,43.837883],[120.585316,31.298886]]},
{"fromName":"黑龙江","toName":"抚顺","coords":[[126.661669,45.742347],[123.957208,41.880872]]},
{"fromName":"吉林","toName":"临安","coords":[[126.549572,43.837883],[119.724733,30.233873]]},
{"fromName":"辽宁","toName":"烟台","coords":[[123.42944,41.835441],[121.447935,37.463822]]},
{"fromName":"黑龙江","toName":"海淀","coords":[[126.661669,45.742347],[116.298056,39.959912]]},
{"fromName":"黑龙江","toName":"南昌","coords":[[126.661669,45.742347],[115.858198,28.682892]]},
{"fromName":"内蒙古","toName":"沈阳","coords":[[111.765618,40.817498],[123.431475,41.805698]]},
{"fromName":"山西","toName":"城阳","coords":[[112.562398,37.873532],[120.39631,36.307064]]},
{"fromName":"吉林","toName":"广州","coords":[[126.549572,43.837883],[113.264435,23.129163]]},
{"fromName":"上海","toName":"沈阳","coords":[[121.473701,31.230416],[123.431475,41.805698]]},
{"fromName":"四川","toName":"阳泉","coords":[[104.075931,30.651652],[113.580519,37.856972]]},
{"fromName":"河北","toName":"桦川","coords":[[114.475704,38.584854],[130.719081,47.023001]]},
{"fromName":"内蒙古","toName":"海淀","coords":[[111.765618,40.817498],[116.298056,39.959912]]},
{"fromName":"安徽","toName":"河北","coords":[[117.284923,31.861184],[114.475704,38.584854]]},
{"fromName":"辽宁","toName":"呼和浩特","coords":[[123.42944,41.835441],[111.749181,40.842585]]},
{"fromName":"广西","toName":"茂名","coords":[[108.327546,22.815478],[110.925456,21.662999]]},
{"fromName":"吉林","toName":"东城","coords":[[126.549572,43.837883],[116.416357,39.928353]]},
{"fromName":"内蒙古","toName":"盘锦","coords":[[111.765618,40.817498],[122.070714,41.119997]]},
{"fromName":"山东","toName":"哈尔滨","coords":[[117.020359,36.66853],[126.534967,45.803775]]},
{"fromName":"黑龙江","toName":"沈阳","coords":[[126.661669,45.742347],[123.431475,41.805698]]},
{"fromName":"黑龙江","toName":"丰台","coords":[[126.661669,45.742347],[116.287149,39.858427]]},
{"fromName":"四川","toName":"盘锦","coords":[[104.075931,30.651652],[122.070714,41.119997]]},
{"fromName":"黑龙江","toName":"皇姑","coords":[[126.661669,45.742347],[123.44197,41.824796]]},
{"fromName":"河北","toName":"虎林","coords":[[114.475704,38.584854],[132.93721,45.762686]]},
{"fromName":"辽宁","toName":"宝山","coords":[[123.42944,41.835441],[131.401589,46.577167]]},
{"fromName":"黑龙江","toName":"吉林","coords":[[126.661669,45.742347],[126.549572,43.837883]]},
{"fromName":"黑龙江","toName":"青岛","coords":[[126.661669,45.742347],[120.38264,36.067082]]},
{"fromName":"吉林","toName":"烟台","coords":[[126.549572,43.837883],[121.447935,37.463822]]},
{"fromName":"山东","toName":"临江","coords":[[117.020359,36.66853],[126.918087,41.811979]]},
{"fromName":"黑龙江","toName":"黄岛","coords":[[126.661669,45.742347],[120.04619,35.872664]]},
{"fromName":"吉林","toName":"石家庄","coords":[[126.549572,43.837883],[114.51486,38.042307]]},
{"fromName":"吉林","toName":"汤原","coords":[[126.549572,43.837883],[129.905072,46.730706]]},
{"fromName":"黑龙江","toName":"临江","coords":[[126.661669,45.742347],[126.918087,41.811979]]},
{"fromName":"吉林","toName":"济南","coords":[[126.549572,43.837883],[117.12,36.651216]]},
{"fromName":"吉林","toName":"太原","coords":[[126.549572,43.837883],[112.548879,37.87059]]},
{"fromName":"吉林","toName":"威海","coords":[[126.549572,43.837883],[122.12042,37.513068]]},
{"fromName":"湖北","toName":"深圳","coords":[[114.341862,30.546498],[114.057868,22.543099]]},
{"fromName":"内蒙古","toName":"荣成","coords":[[111.765618,40.817498],[122.486658,37.16516]]},
{"fromName":"辽宁","toName":"郑州","coords":[[123.42944,41.835441],[113.625368,34.7466]]},
{"fromName":"黑龙江","toName":"朝阳","coords":[[126.661669,45.742347],[116.443108,39.92147]]},
{"fromName":"吉林","toName":"昆山","coords":[[126.549572,43.837883],[120.980737,31.385598]]},
{"fromName":"吉林","toName":"双城","coords":[[126.549572,43.837883],[126.312745,45.383263]]},
{"fromName":"黑龙江","toName":"克拉玛依","coords":[[126.661669,45.742347],[84.889207,45.579889]]},
{"fromName":"辽宁","toName":"上海","coords":[[123.42944,41.835441],[121.473701,31.230416]]},
{"fromName":"吉林","toName":"海阳","coords":[[126.549572,43.837883],[121.158434,36.776378]]},
{"fromName":"吉林","toName":"宣武门外东大街","coords":[[126.549572,43.837883],[116.378888,39.899332]]},
{"fromName":"山东","toName":"海淀","coords":[[117.020359,36.66853],[116.298056,39.959912]]},
{"fromName":"内蒙古","toName":"威海","coords":[[111.765618,40.817498],[122.12042,37.513068]]},
{"fromName":"黑龙江","toName":"晋中","coords":[[126.661669,45.742347],[112.752695,37.687024]]},
{"fromName":"西藏","toName":"广州","coords":[[91.117212,29.646923],[113.264435,23.129163]]},
{"fromName":"辽宁","toName":"无锡","coords":[[123.42944,41.835441],[120.31191,31.49117]]},
{"fromName":"黑龙江","toName":"城阳","coords":[[126.661669,45.742347],[120.39631,36.307064]]},
{"fromName":"河北","toName":"丰台","coords":[[114.475704,38.584854],[116.287149,39.858427]]},
{"fromName":"黑龙江","toName":"扬州","coords":[[126.661669,45.742347],[119.412966,32.39421]]},
{"fromName":"辽宁","toName":"天津","coords":[[123.42944,41.835441],[117.200983,39.084158]]},
{"fromName":"吉林","toName":"扬州","coords":[[126.549572,43.837883],[119.412966,32.39421]]},
{"fromName":"吉林","toName":"嘉兴","coords":[[126.549572,43.837883],[120.755486,30.746129]]},
{"fromName":"河北","toName":"延寿","coords":[[114.475704,38.584854],[128.331644,45.451897]]},
{"fromName":"吉林","toName":"义乌","coords":[[126.549572,43.837883],[120.075058,29.306841]]},
{"fromName":"吉林","toName":"张家港","coords":[[126.549572,43.837883],[120.553284,31.870367]]},
{"fromName":"辽宁","toName":"贵阳","coords":[[123.42944,41.835441],[106.630154,26.647661]]},
{"fromName":"吉林","toName":"辽宁","coords":[[126.549572,43.837883],[123.42944,41.835441]]},
{"fromName":"河南","toName":"营口","coords":[[113.274379,34.445122],[122.235418,40.667012]]},
{"fromName":"吉林","toName":"合肥","coords":[[126.549572,43.837883],[117.227239,31.820587]]},
{"fromName":"黑龙江","toName":"苏州","coords":[[126.661669,45.742347],[120.585316,31.298886]]},
{"fromName":"黑龙江","toName":"榆树","coords":[[126.661669,45.742347],[126.533146,44.840288]]},
{"fromName":"吉林","toName":"常熟","coords":[[126.549572,43.837883],[120.752481,31.654376]]},
{"fromName":"吉林","toName":"乳山","coords":[[126.549572,43.837883],[121.539765,36.919816]]},
{"fromName":"四川","toName":"青岛","coords":[[104.075931,30.651652],[120.38264,36.067082]]},
{"fromName":"黑龙江","toName":"深圳","coords":[[126.661669,45.742347],[114.057868,22.543099]]},
{"fromName":"天津","toName":"东城","coords":[[117.200983,39.084158],[116.416357,39.928353]]},
{"fromName":"黑龙江","toName":"上海","coords":[[126.661669,45.742347],[121.473701,31.230416]]},
{"fromName":"天津","toName":"宁波","coords":[[117.200983,39.084158],[121.550357,29.874557]]},
{"fromName":"吉林","toName":"海门","coords":[[126.549572,43.837883],[121.181615,31.871173]]},
{"fromName":"山西","toName":"沈阳","coords":[[112.562398,37.873532],[123.431475,41.805698]]},
{"fromName":"吉林","toName":"成都","coords":[[126.549572,43.837883],[104.066541,30.572269]]},
{"fromName":"吉林","toName":"南昌","coords":[[126.549572,43.837883],[115.858198,28.682892]]},
{"fromName":"黑龙江","toName":"常州","coords":[[126.661669,45.742347],[119.973987,31.810689]]},
{"fromName":"内蒙古","toName":"兰山","coords":[[111.765618,40.817498],[118.347707,35.051729]]},
{"fromName":"吉林","toName":"河南","coords":[[126.549572,43.837883],[113.274379,34.445122]]},
{"fromName":"黑龙江","toName":"福田","coords":[[126.661669,45.742347],[114.055036,22.52153]]},
{"fromName":"吉林","toName":"常州","coords":[[126.549572,43.837883],[119.973987,31.810689]]},
{"fromName":"吉林","toName":"双流","coords":[[126.549572,43.837883],[103.923648,30.574473]]},
{"fromName":"吉林","toName":"潍坊","coords":[[126.549572,43.837883],[119.161756,36.706774]]},
{"fromName":"吉林","toName":"延安","coords":[[126.549572,43.837883],[109.489727,36.585455]]},
{"fromName":"辽宁","toName":"长春","coords":[[123.42944,41.835441],[125.323544,43.817072]]},
{"fromName":"黑龙江","toName":"南京","coords":[[126.661669,45.742347],[118.796877,32.060255]]},
{"fromName":"辽宁","toName":"和平","coords":[[123.42944,41.835441],[117.21451,39.116949]]},
{"fromName":"北京","toName":"哈尔滨","coords":[[116.407526,39.90403],[126.534967,45.803775]]},
{"fromName":"吉林","toName":"武汉","coords":[[126.549572,43.837883],[114.305393,30.593099]]},
{"fromName":"吉林","toName":"海陵","coords":[[126.549572,43.837883],[119.919425,32.491016]]},
{"fromName":"吉林","toName":"日照","coords":[[126.549572,43.837883],[119.526888,35.416377]]},
{"fromName":"吉林","toName":"台州","coords":[[126.549572,43.837883],[121.420757,28.656386]]},
{"fromName":"辽宁","toName":"厦门","coords":[[123.42944,41.835441],[118.089425,24.479834]]},
{"fromName":"黑龙江","toName":"贵阳","coords":[[126.661669,45.742347],[106.630154,26.647661]]},
{"fromName":"吉林","toName":"鞍山","coords":[[126.549572,43.837883],[122.994329,41.108647]]},
{"fromName":"辽宁","toName":"荣成","coords":[[123.42944,41.835441],[122.486658,37.16516]]},
{"fromName":"黑龙江","toName":"天津","coords":[[126.661669,45.742347],[117.200983,39.084158]]},
{"fromName":"黑龙江","toName":"河西","coords":[[126.661669,45.742347],[117.223372,39.109563]]},
{"fromName":"黑龙江","toName":"秦皇岛","coords":[[126.661669,45.742347],[119.600493,39.935385]]},
{"fromName":"吉林","toName":"荆州","coords":[[126.549572,43.837883],[112.239741,30.335165]]},
{"fromName":"黑龙江","toName":"东城","coords":[[126.661669,45.742347],[116.416357,39.928353]]}
]};
var token = getCookie("jobslink-access-token");
// $.ajaxSetup({
// headers: {
// 'Content-Type': 'application/json', // 指定请求体为JSON格式
// 'Jobslink-Auth': `bearer ${token}`
// }
// });
//测试方法
function getMapData1() {
$.ajax({
type: "GET",
url: testUrl + "/getMapData1",
headers: {
'Content-Type': 'application/json', // 指定请求体为JSON格式
'Jobslink-Auth': `bearer ${token}`
},
async: false,
success: function (res) {
// console.log(res);
// formattedDateTime = res.data;
// var text = res.data.split("-")[1];
// if (Number(text) >= 10) {
// $("#btn1").text(text + "月分析");
// } else {
// $("#btn1").text(text.substring(1, 2) + "月分析");
// }
},
});
}
// 分行业需求
function getMapData2() {
$.ajax({
type: "GET",
headers: {
'Content-Type': 'application/json', // 指定请求体为JSON格式
'Jobslink-Auth': `bearer ${token}`
},
url: testUrl + "/getMapData2",
async: false,
success: function (res) {
console.log(res)
},
});
}
function getMapData3() {
$.ajax({
type: "GET",
headers: {
'Content-Type': 'application/json', // 指定请求体为JSON格式
'Jobslink-Auth': `bearer ${token}`
},
url: testUrl + "/getMapData3",
async: false,
success: function (res) {
},
});
}
function testData4() {
$.ajax({
type: "GET",
headers: {
'Content-Type': 'application/json', // 指定请求体为JSON格式
'Jobslink-Auth': `bearer ${token}`
},
url: testUrl + "/getData1",
data: { date: '2023-10', province: '四川省' },
async: false,
success: function (res) {
},
});
}
function getIndustryData() {
console.log('6666666666666')
$.ajax({
type: "GET",
headers: {
'Content-Type': 'application/json', // 指定请求体为JSON格式
'Jobslink-Auth': `bearer ${token}`
},
url: testUrl + "/getData2",
data: { date: '2023-10', province: '四川省' },
async: false,
success: function (res) {
console.log('6666666666666')
// data1 岗位数, // data2 求职人数
console.log(res.data)
var name = res.data.name;
if(name && name.length > 0) {
for(var i = 0; i < name.length; i++) {
console.log(name[i])
}
}
},
});
}
function testData6() {
$.ajax({
type: "GET",
headers: {
'Content-Type': 'application/json', // 指定请求体为JSON格式
'Jobslink-Auth': `bearer ${token}`
},
url: testUrl + "/getData3",
data: { date: '2023-10', province: '四川省' },
async: false,
success: function (res) {
},
});
}
function testData7() {
$.ajax({
type: "GET",
headers: {
'Content-Type': 'application/json', // 指定请求体为JSON格式
'Jobslink-Auth': `bearer ${token}`
},
url: testUrl + "/getData4",
data: { date: '2023-10', province: '四川省' },
async: false,
success: function (res) {
},
});
}
function testData8() {
$.ajax({
type: "GET",
headers: {
'Content-Type': 'application/json', // 指定请求体为JSON格式
'Jobslink-Auth': `bearer ${token}`
},
url: testUrl + "/getData5",
data: { date: '2023-10', province: '四川省' },
async: false,
success: function (res) {
},
});
}
function testData9() {
$.ajax({
type: "GET",
headers: {
'Content-Type': 'application/json', // 指定请求体为JSON格式
'Jobslink-Auth': `bearer ${token}`
},
url: testUrl + "/getData6",
data: { date: '2023-10', province: '四川省' },
async: false,
success: function (res) {
},
});
}
function testData10() {
$.ajax({
type: "GET",
headers: {
'Content-Type': 'application/json', // 指定请求体为JSON格式
'Jobslink-Auth': `bearer ${token}`
},
url: testUrl + "/getData7",
data: { date: '2023-10', province: '四川省' },
async: false,
success: function (res) {
},
});
}
function testData11() {
$.ajax({
type: "GET",
headers: {
'Content-Type': 'application/json', // 指定请求体为JSON格式
'Jobslink-Auth': `bearer ${token}`
},
url: testUrl + "/getData8",
data: { date: '2023-10', province: '四川省' },
async: false,
success: function (res) {
},
});
}
//头部数据--------------------------------------
//获取当前时间
var formattedDateTime;
var showOtherFlag = false;
function getDate() {
$.ajax({
type: "GET",
url: baseUrl + "/dataNew/getDate",
async: false,
success: function (res) {
// console.log(res);
formattedDateTime = res.data;
var text = res.data.split("-")[1];
if (Number(text) >= 10) {
$("#btn1").text(text + "月分析");
} else {
$("#btn1").text(text.substring(1, 2) + "月分析");
}
},
});
}
function showOther(obj) {
if (!showOtherFlag) {
$(".echart10").hide();
$(".echart12").hide();
showOtherFlag = true;
} else {
$(".echart10").show();
$(".echart12").show();
showOtherFlag = false;
}
}
//切换toggle
function toggleView(obj) {
$(obj).siblings().removeClass("active");
$(obj).addClass("active");
var viewId = $(obj).attr("viewId");
if (viewId == "1") {
$(".mainbox1").show();
$(".mainbox2").hide();
getData8();
getData5();
getData6();
getData1();
getData2();
getData7();
getData4();
getData10();
getData12();
} else if (viewId == "2") {
$(".mainbox1").hide();
$(".mainbox2").show();
get_echart_trend1();
get_echart_trend2();
get_echart_trend3();
get_echart_trend4();
get_echart_trend5();
get_echart_trend6();
get_echart_trend7();
}
}
//左侧数据--------------------------------------
//分行业
function getData8() {
$.ajax({
type: "GET",
url: baseUrl + "/dataNew/getData8",
async: true,
data: { date: formattedDateTime },
success: function (res) {
//console.log(res);
if (res.code == "0") {
var data = res.data;
if (data.name.length > 0) {
quanGuo(data);
$(".myscroll").myScroll({
//jQuery文字无缝滚动
speed: 40, //数值越大,速度越慢
rowHeight: 26, //li的高度
});
}
}
},
});
}
function quanGuo(data) {
$("#ulBox").empty();
$(data.name).each(function (i, n) {
$("#ulBox").append(
'
' +
(i + 1) +
'' +
n +
"" +
data.data1[i] +
"" +
data.data2[i] +
""
);
});
}
//分单位
function getData5() {
$.ajax({
type: "GET",
url: testUrl + "/getData5",
headers: {
'Content-Type': 'application/json', // 指定请求体为JSON格式
'Jobslink-Auth': `bearer ${token}`
},
async: true,
data: { date: '2023-10', province: '四川省' },
success: function (res) {
//console.log(res);
if (res.code == "200") {
var myChart = echarts.init(document.getElementById("echart5"));
var option = {
title: {
// text: "分单位性质招聘需求",
subtext: "",
left: "center",
textStyle: { fontSize: 13, color: "#fff", fontWeight: 400 },
},
legend: {
left: "right",
textStyle: { color: "#fff", fontSize: 10 },
show: false,
},
tooltip: { trigger: "axis", axisPointer: { type: "shadow" } },
grid: {
left: "0",
top: "20%",
right: "5",
bottom: "5",
containLabel: true,
},
xAxis: {
nameLocation: "end",
nameGap: 7,
type: "category",
data: res.data.name,
axisLine: {
show: true,
lineStyle: {
color: "#3FC79B",
width: 1,
type: "solid",
},
},
axisTick: { show: false },
axisLabel: {
interval: 0,
rotate: 0,
textStyle: { color: "#3FC79B", fontSize: "12" },
},
},
yAxis: {
type: "value",
// name: "万人/万个",
nameGap: 0,
nameTextStyle: {
color: "#fff",
fontSize: 10,
lineHeight: 30,
height: 30,
padding: 6,
},
position: "top",
axisLabel: {
show: true,
textStyle: { color: "#3FC79B", fontSize: "12" },
},
axisTick: { show: false },
axisLine: {
show: false,
lineStyle: {
color: "#3FC79B",
width: 1,
type: "solid",
},
},
splitLine: { lineStyle: { color: "rgba(63, 199, 155, .5)" } },
},
series: [
{
type: "bar",
name: "需求人数",
barWidth: "15%",
itemStyle: {
normal: {
opacity: 1,
barBorderRadius: [10, 10, 0, 0],
color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
{ offset: 0, color: "#F28505" },
{ offset: 1, color: "#F6DC3C" },
]),
},
},
// label: {
// show: true,
// position: "top",
// distance: 5,
// fontSize: "8",
// },
data: res.data.data1,
},
// {
// type: "bar",
// name: "求职人数",
// barWidth: "15%",
// itemStyle: {
// normal: { opacity: 1, barBorderRadius: 0, color: "#36c3fd" },
// },
// label: {
// show: true,
// position: "top",
// distance: 5,
// fontSize: "8",
// },
// data: res.data.data2,
// },
],
};
console.log(option);
myChart.setOption(option);
window.addEventListener("resize", function () {
myChart.resize();
});
}
},
});
}
//分产业
function getData7() {
$.ajax({
type: "GET",
url: testUrl + "/getData7",
headers: {
'Content-Type': 'application/json', // 指定请求体为JSON格式
'Jobslink-Auth': `bearer ${token}`
},
async: true,
data: { date: '2023-10', province: '四川省' },
success: function (res) {
//console.log(res);
if (res.code == "200") {
var arr = [];
for (var i = 0; i < res.data.name.length; i++) {
var obj = {};
obj.name = res.data.name[i];
obj.value = res.data.data1[i];
arr.push(obj);
}
var myChart = echarts.init(document.getElementById("echart7"));
var option = {
legend: {
top: "bottom",
show: false,
},
toolbox: {
show: false,
feature: {
mark: { show: true },
dataView: { show: true, readOnly: false },
restore: { show: true },
saveAsImage: { show: true },
},
},
series: [
{
name: "Nightingale Chart",
type: "pie",
radius: ["20%", "60%"],
center: ["50%", "50%"],
roseType: "area",
itemStyle: {
borderRadius: 8,
},
data: arr,
},
],
};
myChart.setOption(option);
window.addEventListener("resize", function () {
myChart.resize();
});
}
},
});
}
//获取岗位数gvs和招聘人数zprs
function getData1() {
$.ajax({
type: "GET",
url: baseUrl + "/dataNew/getData1",
async: true,
data: { date: formattedDateTime },
success: function (res) {
//console.log(res);
if ((res.code = "0")) {
var xq = res.data.xq;
var qz = res.data.qz;
$(".xuqiu").text("总岗位数:" + xq + "万个");
$(".qiuzhi").text("求职总人数:" + qz + "万人");
}
},
});
}
//获取省辖市集合
function getCityListByProvinceCode(zhName, pyName, name) {
console.log(zhName, pyName, name);
window.location.href =
"detail.html?shengFen=" +
escape(zhName) +
"&abbreviation=" +
pyName +
"&shortName=" +
escape(name);
}
//获取地图数据
function getData2() {
$.ajax({
type: "GET",
url: baseUrl + "/dataNew/getData2",
async: true,
data: { date: formattedDateTime },
success: function (res) {
//console.log(res);
if (res.code == "0") {
var province = res.data;
if (province.length > 0) {
//渲染地图
var myChart = echarts.init(document.getElementById("echart2"));
var option = {
animation: false,
//鼠标浮动显示框
tooltip: {
trigger: "item",
formatter: function (params) {
if (params.name != "") {
return (
params.name +
"
需求人数:" +
params.value +
"
求职人数:" +
params.data.value1
);
} else {
return "暂无数据";
}
},
},
visualMap: {
show: false,
min: 1,
max: 300000,
inRange: { color: ["#063b9e", "#299af0", "#cae2fd"].reverse() },
textStyle: { color: "#fff" },
},
geo: {
show:true, // 是否显示
map: 'china', // 地图类型。world世界地图,china中国地图
// center:[115.97, 29.71], //当前视角的中心点,用经纬度表示
label: {
normal:{ //普通状态下的标签文本样式。(省份名称)
show: false, //是否在普通状态下显示标签。
textStyle: { // 文字设置
color: '#fff'
},
},
emphasis: { // 是否在高亮状态下显示标签。(省份名称)
show: true,
textStyle: { // 文字设置
color: '#fff'
},
}
},
roam: true, // 是否开启鼠标缩放和平移漫游。默认不开启。如果只想要开启缩放或者平移,可以设置成 'scale' 或者 'move'。设置成 true 为都开启
itemStyle: { // 地图板块区域的多边形 图形样式
normal: { // 默认板块信息
areaColor: '#58B3CC',
borderColor: '#404a59'
},
emphasis: { // 高亮版板块信息
areaColor: '#51D7FF'
}
}
},
// series: [
// {
// name: "china",
// type: "map",
// aspectScale: 0.75,
// zoom: 1.5,
// mapType: "china",
// roam: true,
// label: {
// normal: {
// show: true,
// textStyle: { color: "#fff", fontSize: "9" },
// },
// emphasis: { show: true, textStyle: { color: "#800080" } },
// },
// itemStyle: {
// normal: {
// color: "#ffeb7b",
// areaColor: "#4c60ff",
// borderColor: "#1935e1",
// },
// },
// data: province,
// },
// ],
series: [{
name: '地点',
type: 'effectScatter', // 特效散点图
coordinateSystem: 'geo', // 'cartesian2d'使用二维的直角坐标系。'geo'使用地理坐标系
zlevel: 2, // 所有图形的 zlevel 值。
rippleEffect: { //涟漪特效相关配置。
brushType: 'stroke', //波纹的绘制方式,可选 'stroke' 和 'fill'。
period:4, // 动画的时间。
scale:2.5, // 动画中波纹的最大缩放比例。
},
label: {
normal: {
show: false, //是否显示标签。
position: "inside", //标签的位置。// 绝对的像素值[10, 10],// 相对的百分比['50%', '50%'].'top','left','right','bottom','inside','insideLeft','insideRight','insideTop','insideBottom','insideTopLeft','insideBottomLeft','insideTopRight','insideBottomRight'
offset: [30, 40], //是否对文字进行偏移。默认不偏移。例如:[30, 40] 表示文字在横向上偏移 30,纵向上偏移 40。
formatter: '{b}: {c}', //标签内容格式器。模板变量有 {a}、{b}、{c},分别表示系列名,数据名,数据值。
},
emphasis: {
show: true,
position: 'right',
formatter: '{b}'
}
},
symbolSize: 2, // 标记的大小,可以设置成诸如 10 这样单一的数字,也可以用数组分开表示宽和高,例如 [20, 10] 表示标记宽为20,高为10。
showEffectOn: 'render', // 配置何时显示特效。可选:'render' 绘制完成后显示特效。'emphasis' 高亮(hover)的时候显示特效。
itemStyle: { // 图形样式,normal 是图形在默认状态下的样式;emphasis 是图形在高亮状态下的样式,比如在鼠标悬浮或者图例联动高亮时。
normal: {
color: '#46bee9'
}
},
data: allData.citys
}, {
name: '线路',
type: 'lines',
coordinateSystem: 'geo', // 'cartesian2d'使用二维的直角坐标系。'geo'使用地理坐标系
zlevel: 2,
large: true, // 是否开启大规模散点图的优化,在数据图形特别多的时候(>=5k)可以开启。开启后配合 largeThreshold 在数据量大于指定阈值的时候对绘制进行优化。缺点:优化后不能自定义设置单个数据项的样式。
effect: {
show: true,
constantSpeed: 30, // 点移动的速度
symbol: 'pin', // 图形 'circle', 'rect', 'roundRect', 'triangle', 'diamond', 'pin', 'arrow'
symbolSize: 3, // 标记的大小,可以设置成诸如 10 这样单一的数字,也可以用数组分开表示宽和高,例如 [20, 10] 表示标记宽为20,高为10。
trailLength: 0, // 线的宽度
},
lineStyle: { // 线的颜色、宽度,样式设置
normal: {
color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
offset: 0, color: '#58B3CC'
}, {
offset: 1, color: '#F58158'
}], false),
width: 1, // 线的宽度
opacity: 0.2, // 线的透明度
curveness: 0.1 // 线的完全程度
}
},
data: allData.moveLines
}]
};
myChart.setOption(option);
//地图点击事件
// var cityArr = [
// [
// "上海市",
// "河北省",
// "山西省",
// "内蒙古自治区",
// "辽宁省",
// "吉林省",
// "黑龙江省",
// "江苏省",
// "浙江省",
// "安徽省",
// "福建省",
// "江西省",
// "山东省",
// "河南省",
// "湖北省",
// "湖南省",
// "广东省",
// "广西壮族自治区",
// "海南省",
// "四川省",
// "贵州省",
// "云南省",
// "西藏自治区",
// "陕西省",
// "甘肃省",
// "青海省",
// "宁夏回族自治区",
// "新疆维吾尔自治区",
// "北京市",
// "天津市",
// "重庆市",
// "香港特别行政区",
// "澳门特别行政区",
// "台湾省",
// ],
// [
// "shanghai",
// "hebei",
// "shanxi",
// "neimenggu",
// "liaoning",
// "jilin",
// "heilongjiang",
// "jiangsu",
// "zhejiang",
// "anhui",
// "fujian",
// "jiangxi",
// "shandong",
// "henan",
// "hubei",
// "hunan",
// "guangdong",
// "guangxi",
// "hainan",
// "sichuan",
// "guizhou",
// "yunnan",
// "xizang",
// "shanxi1",
// "gansu",
// "qinghai",
// "ningxia",
// "xinjiang",
// "beijing",
// "tianjin",
// "chongqing",
// "xianggang",
// "aomen",
// "taiwan",
// ],
// ];
// myChart.on("click", function (params) {
// //点击事件
// if (params.name != "") {
// var cityName = params.data.fullName;
// var name = params.name;
// for (var i = 0, len = cityArr[0].length; i < len; i++) {
// // 查找是否有对应城市有则加载城市
// if (cityName == cityArr[0][i]) {
// getCityListByProvinceCode(cityArr[0][i], cityArr[1][i], name); // 获取得城市拼音
// return;
// }
// }
// } else {
// showDialog("暂无数据,无法查看");
// }
// //没有找到对应城市的话,那么返回到全国地图
// option.series[0].mapType = "china";
// myChart.setOption(option);
// });
window.addEventListener("resize", function () {
myChart.resize();
});
}
}
},
});
}
//分岗位招聘需求
function getData4() {
$.ajax({
type: "GET",
url: testUrl + "/getData6",
headers: {
'Content-Type': 'application/json', // 指定请求体为JSON格式
'Jobslink-Auth': `bearer ${token}`
},
async: true,
data: { date: '2023-10', province: '四川省' },
success: function (res) {
//console.log(res);
if (res.code == "200") {
// var name = [];
// var xq = [];
// var qz = [];
// for (var i = 0; i < res.data.length; i++) {
// name.push(res.data[i].name);
// xq.push(res.data[i].xq);
// qz.push(res.data[i].qz);
// }
var myChart = echarts.init(document.getElementById("echart4"));
var option = {
title: {
// text: "分岗位招聘需求",
subtext: "",
left: "center",
textStyle: { fontSize: 13, color: "#fff", fontWeight: 400 },
},
legend: {
left: "right",
textStyle: { color: "#fff", fontSize: 10 },
show: false,
},
tooltip: { trigger: "axis", axisPointer: { type: "shadow" } },
grid: {
left: "0",
top: "20%",
right: "0",
bottom: "5",
containLabel: true,
},
xAxis: {
nameLocation: "end",
nameGap: 7,
type: "category",
data: res.data.name,
axisLine: {
show: true,
lineStyle: {
color: "rgba(63, 199, 155, 1)",
width: 1,
type: "solid",
},
},
axisTick: { show: false },
axisLabel: {
interval: 0,
rotate: 0,
textStyle: { color: "rgba(63, 199, 155, 1)", fontSize: "12" },
},
},
yAxis: {
type: "value",
// name: "万人/万个",
nameGap: 0,
nameTextStyle: { color: "#fff", fontSize: 10, padding: 6 },
position: "top",
axisLabel: {
show: true,
textStyle: { color: "rgba(63, 199, 155, 1)", fontSize: "12" },
},
axisTick: { show: false },
axisLine: {
show: false,
lineStyle: {
color: "rgba(255,255,255,.9)",
width: 1,
type: "solid",
},
},
splitLine: { lineStyle: { color: "rgba(63, 199, 155, .5)" } },
},
series: [
{
type: "bar",
name: "需求人数",
barWidth: "15%",
itemStyle: {
normal: {
opacity: 1,
barBorderRadius: [10, 10, 0, 0],
color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
{ offset: 0, color: "#2F69FC " },
{ offset: 1, color: "#51D7FF" },
]),
},
},
// label: {
// show: true,
// position: "top",
// distance: 5,
// fontSize: "8",
// },
data: res.data.data1,
},
// {
// type: "bar",
// name: "求职人数",
// barWidth: "15%",
// itemStyle: {
// normal: { opacity: 1, barBorderRadius: 0, color: "#36c3fd" },
// },
// label: {
// show: true,
// position: "top",
// distance: 5,
// fontSize: "8",
// },
// data: qz,
// },
],
};
myChart.setOption(option);
window.addEventListener("resize", function () {
myChart.resize();
});
}
},
});
}
//工资水平
function getData12() {
$.ajax({
type: "GET",
url: baseUrl + "/dataNew/getData12",
async: true,
data: { date: formattedDateTime },
success: function (res) {
//console.log(res);
if (res.code == "0") {
var myChart = echarts.init(document.getElementById("echart12"));
var option = {
title: {
text: "不同薪酬区间的岗位需求",
subtext: "",
left: "center",
textStyle: { fontSize: 13, color: "#fff", fontWeight: 400 },
},
legend: { left: "left", textStyle: { color: "#fff", fontSize: 10 } },
tooltip: { trigger: "axis", axisPointer: { type: "shadow" } },
grid: {
left: "0",
top: "20%",
right: "5",
bottom: "5",
containLabel: true,
},
xAxis: {
nameLocation: "end",
nameGap: 7,
type: "category",
data: res.data.name,
axisLine: {
show: true,
lineStyle: {
color: "rgba(255,255,255,.9)",
width: 1,
type: "solid",
},
},
axisTick: { show: false },
axisLabel: {
interval: 0,
rotate: 275,
textStyle: { color: "rgba(255,255,255,.6)", fontSize: "9" },
},
},
yAxis: {
type: "value",
name: "万人/万个",
nameGap: 0,
nameTextStyle: { color: "#fff", fontSize: 10, padding: 6 },
position: "top",
axisLabel: {
show: true,
textStyle: { color: "rgba(255,255,255,.6)", fontSize: "10" },
},
axisTick: { show: false },
axisLine: {
show: true,
lineStyle: {
color: "rgba(255,255,255,.9)",
width: 1,
type: "solid",
},
},
splitLine: { lineStyle: { color: "rgba(255,255,255,.1)" } },
},
series: [
{
type: "bar",
name: "需求人数",
barWidth: "15%",
itemStyle: {
normal: { opacity: 1, barBorderRadius: 0, color: "#dd76aa" },
},
label: {
show: true,
position: "top",
distance: 5,
fontSize: "8",
},
data: res.data.data1,
},
{
type: "bar",
name: "求职人数",
barWidth: "15%",
itemStyle: {
normal: { opacity: 1, barBorderRadius: 0, color: "#36c3fd" },
},
label: {
show: true,
position: "top",
distance: 5,
fontSize: "8",
},
data: res.data.data2,
},
],
};
myChart.setOption(option);
window.addEventListener("resize", function () {
myChart.resize();
});
}
},
});
}
//获取地图数据
function getData20() {
$.ajax({
type: "GET",
url: baseUrl + "/dataNew/getData2",
async: false,
data: { date: formattedDateTime, shengfen: "四川省" },
success: function (res) {
console.log(res);
if (res.code == "0") {
var city = res.data;
if (city.length > 0) {
var myChart = echarts.init(document.getElementById("echart20"));
$.getScript("js/province/" + "deyang.js", function () {
var option = {
tooltip: {
trigger: "item",
formatter: function (params) {
if (params.name != "") {
return (
params.name +
"
需求人数:" +
params.value +
"
求职人数:" +
params.data.value1
);
} else {
return "暂无数据";
}
},
},
animation: false,
visualMap: {
show: false,
min: 1,
max: 2000000,
inRange: {
color: ["#d94e5d", "#eac736", "#50a3ba"].reverse(),
},
textStyle: { color: "#fff" },
},
geo: {},
series: [
{
name: "德阳市",
type: "map",
mapType: "德阳市",
aspectScale: 0.75,
zoom: 1.3,
roam: true,
label: {
normal: {
show: true,
textStyle: { color: "#fff", fontSize: "9" },
},
emphasis: { show: true, textStyle: { color: "#800080" } },
},
itemStyle: {
normal: {
color: "#ffeb7b",
areaColor: "#4c60ff",
borderColor: "#1935e1",
},
},
// data: city,
data: [
{name:'旌阳区', value:1099, value1: 2011},
{name:'罗江区', value:199, value1: 211},
{name:'中江县', value:699, value1: 811},
{name:'广汉市', value:321, value1: 999},
{name:'什邡市', value:6788, value1: 2567},
{name:'绵竹市', value:342, value1: 678}
]
},
],
};
myChart.setOption(option);
//地图点击事件
myChart.on("click", function (params) {
console.log(params);
console.log(params.name);
window.location.href = "detail.html?shengFen=" + escape(params.name) +
"&abbreviation=" + params.name + "&shortName=" + escape(params.name);
//点击事件
// if (params.name != "") {
// var name = params.name;
// getCityListByProvinceCode(name); // 获取得城市拼音
// return;
// } else {
// showDialog("暂无数据,无法查看");
// }
//没有找到对应城市的话,那么返回到全国地图
// option.series[0].mapType = "china";
// myChart.setOption(option);
});
window.addEventListener("resize", function () {
myChart.resize();
});
});
// }
}
}
},
});
}
//学历
function getData10() {
$.ajax({
type: "GET",
url: baseUrl + "/dataNew/getData10",
async: true,
data: { date: formattedDateTime },
success: function (res) {
//console.log(res);
if (res.code == "0") {
var myChart = echarts.init(document.getElementById("echart10"));
var option = {
title: {
text: "分学历求职人数",
subtext: "",
left: "center",
textStyle: { fontSize: 13, color: "#fff", fontWeight: 400 },
},
legend: { left: "left", textStyle: { color: "#fff", fontSize: 10 } },
tooltip: { trigger: "axis", axisPointer: { type: "shadow" } },
grid: {
left: "0",
top: "20%",
right: "5",
bottom: "5",
containLabel: true,
},
xAxis: {
nameLocation: "end",
nameGap: 7,
type: "category",
data: res.data.name,
axisLine: {
show: true,
lineStyle: {
color: "rgba(255,255,255,.9)",
width: 1,
type: "solid",
},
},
axisTick: { show: false },
axisLabel: {
interval: 0,
rotate: 275,
textStyle: { color: "rgba(255,255,255,.6)", fontSize: "9" },
},
},
yAxis: {
type: "value",
name: "万人/万个",
nameGap: 0,
nameTextStyle: { color: "#fff", fontSize: 10, padding: 6 },
position: "top",
axisLabel: {
show: true,
textStyle: { color: "rgba(255,255,255,.6)", fontSize: "10" },
},
axisTick: { show: false },
axisLine: {
show: true,
lineStyle: {
color: "rgba(255,255,255,.9)",
width: 1,
type: "solid",
},
},
splitLine: { lineStyle: { color: "rgba(255,255,255,.1)" } },
},
series: [
{
type: "bar",
name: "需求人数",
barWidth: "15%",
itemStyle: {
normal: { opacity: 1, barBorderRadius: 0, color: "#dd76aa" },
},
label: {
show: true,
position: "top",
distance: 5,
fontSize: "8",
},
data: res.data.data1,
},
{
type: "bar",
name: "求职人数",
barWidth: "15%",
itemStyle: {
normal: { opacity: 1, barBorderRadius: 0, color: "#36c3fd" },
},
label: {
show: true,
position: "top",
distance: 5,
fontSize: "8",
},
data: res.data.data2,
},
],
};
myChart.setOption(option);
window.addEventListener("resize", function () {
myChart.resize();
});
}
},
});
}
//年龄
function getData11() {
$.ajax({
type: "GET",
url: baseUrl + "/dataNew/getData11",
async: true,
data: { date: formattedDateTime },
success: function (res) {
console.log(res);
if (res.code == "0") {
var myChart = echarts.init(document.getElementById("echart11"));
var option = {
title: {
text: "分年龄招聘需求",
subtext: "",
left: "center",
textStyle: { fontSize: 13, color: "#fff", fontWeight: 400 },
},
legend: { left: "left", textStyle: { color: "#fff", fontSize: 10 } },
tooltip: { trigger: "axis", axisPointer: { type: "shadow" } },
grid: {
left: "0",
top: "20%",
right: "5",
bottom: "5",
containLabel: true,
},
xAxis: {
nameLocation: "end",
nameGap: 7,
type: "category",
data: res.data.name,
axisLine: {
show: true,
lineStyle: {
color: "rgba(255,255,255,.9)",
width: 1,
type: "solid",
},
},
axisTick: { show: false },
axisLabel: {
interval: 0,
rotate: 275,
textStyle: { color: "rgba(255,255,255,.6)", fontSize: "9" },
},
},
yAxis: {
type: "value",
name: "万人/万个",
nameGap: 0,
nameTextStyle: { color: "#fff", fontSize: 10, padding: 6 },
position: "top",
axisLabel: {
show: true,
textStyle: { color: "rgba(255,255,255,.6)", fontSize: "10" },
},
axisTick: { show: false },
axisLine: {
show: true,
lineStyle: {
color: "rgba(255,255,255,.9)",
width: 1,
type: "solid",
},
},
splitLine: { lineStyle: { color: "rgba(255,255,255,.1)" } },
},
series: [
{
type: "bar",
name: "需求人数",
barWidth: "15%",
itemStyle: {
normal: { opacity: 1, barBorderRadius: 0, color: "#dd76aa" },
},
label: {
show: true,
position: "top",
distance: 5,
fontSize: "8",
},
data: res.data.data1,
},
{
type: "bar",
name: "求职人数",
barWidth: "15%",
itemStyle: {
normal: { opacity: 1, barBorderRadius: 0, color: "#36c3fd" },
},
label: {
show: true,
position: "top",
distance: 5,
fontSize: "8",
},
data: res.data.data2,
},
],
};
myChart.setOption(option);
window.addEventListener("resize", function () {
myChart.resize();
});
}
},
});
}
//分企业规模
function getData6() {
$.ajax({
type: "GET",
url: testUrl + "/getData4",
headers: {
'Content-Type': 'application/json', // 指定请求体为JSON格式
'Jobslink-Auth': `bearer ${token}`
},
async: true,
data: { date: '2023-10', province: '四川省' },
success: function (res) {
console.log(res);
if (res.code == "200") {
var myChart = echarts.init(document.getElementById("echart6"));
var option = {
title: {
// text: "分企业规模招聘需求",
subtext: "",
left: "center",
textStyle: { fontSize: 13, color: "#fff", fontWeight: 400 },
},
legend: {
left: "right",
textStyle: { color: "#fff", fontSize: 10 },
show: false,
},
tooltip: { trigger: "axis", axisPointer: { type: "shadow" } },
grid: {
left: "0",
top: "20%",
right: "5",
bottom: "5",
containLabel: true,
},
xAxis: {
nameLocation: "end",
nameGap: 7,
type: "category",
data: res.data.name,
axisLine: {
show: true,
lineStyle: {
color: "#3FC79B",
width: 1,
type: "solid",
},
},
axisTick: { show: false },
axisLabel: {
interval: 0,
rotate: 340,
textStyle: { color: "#3FC79B", fontSize: "10" },
},
},
yAxis: {
type: "value",
nameGap: 0,
nameTextStyle: { color: "#fff", fontSize: 10, padding: 6 },
position: "top",
axisLabel: {
show: true,
textStyle: { color: "#3FC79B", fontSize: "12" },
},
axisTick: { show: false },
axisLine: {
show: true,
lineStyle: {
color: "#3FC79B",
width: 1,
type: "solid",
},
},
splitLine: { lineStyle: { color: "rgba(63, 199, 155, .5)" } },
},
series: [
{
type: "bar",
name: "需求人数",
barWidth: "15%",
itemStyle: {
normal: {
opacity: 1,
barBorderRadius: [10, 10, 0, 0],
color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
{ offset: 0, color: "#8005F2" },
{ offset: 1, color: "#2D3CFF" },
]),
},
},
data: res.data.data1,
},
],
};
myChart.setOption(option);
window.addEventListener("resize", function () {
myChart.resize();
});
}
},
});
}
function getData18() {
$.ajax({
type: "GET",
url: testUrl + "/getData3",
headers: {
'Content-Type': 'application/json', // 指定请求体为JSON格式
'Jobslink-Auth': `bearer ${token}`
},
async: true,
data: { date: '2023-10', province: '四川省' },
success: function (res) {
console.log(res);
if (res.code == "200") {
var myChart = echarts.init(document.getElementById("echart8"));
var option = {
tooltip: {
trigger: "axis",
axisPointer: {
type: "shadow",
},
},
legend: { show: false },
grid: {
left: "3%",
right: "4%",
bottom: "3%",
containLabel: true,
},
xAxis: {
type: "value",
boundaryGap: [0, 0.01],
axisLabel: {
interval: 0,
textStyle: { color: "#3FC79B", fontSize: "12" },
},
axisLine: {
show: true,
lineStyle: {
color: "#3FC79B",
width: 1,
type: "dashed",
},
},
splitLine: {
lineStyle: { color: "rgba(63, 199, 155, .5)", type: "dashed" },
},
},
yAxis: {
type: "category",
axisTick: { show: false },
data: res.data.name,
axisLabel: {
show: true,
textStyle: { color: "#0072FF", fontSize: "12" },
},
axisLine: {
show: true,
lineStyle: {
color: "#3FC79B",
width: 1,
type: "dashed",
},
},
},
series: [
{
name: "2011",
type: "bar",
barWidth: "35%",
itemStyle: {
normal: {
opacity: 1,
barBorderRadius: [0, 10, 10, 0],
color: new echarts.graphic.LinearGradient(1, 0, 0, 0, [
{ offset: 0, color: "#E54839" },
{ offset: 1, color: "#FAC56A" },
]),
},
},
data: res.data.data1,
},
],
};
myChart.setOption(option);
window.addEventListener("resize", function () {
myChart.resize();
});
}
},
});
}
$(function () {
getMapData1();
getMapData2(); // 分行业
getMapData3();
testData4();
getIndustryData();
testData6();
testData7();
testData8();
testData9();
testData10();
testData11();
getDate();
getData1();
getData2();
getData20();
getData4();
getData5();
getData6();
getData7();
getData8();
// getData9();
getData10();
getData11();
getData12();
getData18();
});
//历史数据
function get_echart_trend1() {
var fenlei = "行业";
$.ajax({
type: "GET",
url: baseUrl + "/dataNew/getData13",
data: { fenlei: fenlei },
success: function (res) {
//console.log(res);
if (res.code == "0") {
var arr = [];
for (var i = 0; i < res.data.keys.length; i++) {
var obj = {};
obj.data = res.data["qzlist" + i];
obj.type = "line";
obj.name = res.data.keys[i];
arr.push(obj);
}
for (var j = 0; j < res.data.keys.length; j++) {
var obj = {};
obj.data = res.data["xqlist" + j];
obj.type = "line";
obj.name = res.data.keys[j];
arr.push(obj);
}
var myChart = echarts.init(document.getElementById("echart_trend1"));
var option = {
tooltip: {
trigger: "axis",
axisPointer: { type: "shadow" },
position: [10, 0],
},
grid: {
left: "0",
top: "5%",
right: "5",
bottom: "0",
containLabel: true,
},
xAxis: {
nameLocation: "end",
nameGap: 7,
type: "category",
data: res.data.name,
axisLine: {
show: true,
lineStyle: {
color: "rgba(255,255,255,.9)",
width: 1,
type: "solid",
},
},
axisTick: { show: false },
axisLabel: {
interval: 0,
rotate: 0,
textStyle: { color: "rgba(255,255,255,.6)", fontSize: "10" },
},
},
yAxis: {
type: "value",
name: "",
nameGap: 0,
nameTextStyle: { color: "#fff", fontSize: 10 },
position: "top",
axisLabel: {
show: true,
textStyle: { color: "rgba(255,255,255,.6)", fontSize: "10" },
},
axisTick: { show: false },
axisLine: {
show: true,
lineStyle: {
color: "rgba(255,255,255,.9)",
width: 1,
type: "solid",
},
},
splitLine: { lineStyle: { color: "rgba(255,255,255,.1)" } },
},
series: arr,
};
myChart.setOption(option);
window.addEventListener("resize", function () {
myChart.resize();
});
}
},
});
}
function get_echart_trend2() {
var fenlei = "企业规模";
$.ajax({
type: "GET",
url: baseUrl + "/dataNew/getData13",
data: { fenlei: fenlei },
success: function (res) {
//console.log(res);
if (res.code == "0") {
var arr = [];
for (var i = 0; i < res.data.keys.length; i++) {
var obj = {};
obj.data = res.data["qzlist" + i];
obj.type = "line";
obj.name = res.data.keys[i];
arr.push(obj);
}
for (var j = 0; j < res.data.keys.length; j++) {
var obj = {};
obj.data = res.data["xqlist" + j];
obj.type = "line";
obj.name = res.data.keys[j];
arr.push(obj);
}
var myChart = echarts.init(document.getElementById("echart_trend2"));
var option = {
tooltip: {
trigger: "axis",
axisPointer: { type: "shadow" },
position: [10, 0],
},
grid: {
left: "0",
top: "5%",
right: "5",
bottom: "0",
containLabel: true,
},
xAxis: {
nameLocation: "end",
nameGap: 7,
type: "category",
data: res.data.name,
axisLine: {
show: true,
lineStyle: {
color: "rgba(255,255,255,.9)",
width: 1,
type: "solid",
},
},
axisTick: { show: false },
axisLabel: {
interval: 0,
rotate: 0,
textStyle: { color: "rgba(255,255,255,.6)", fontSize: "10" },
},
},
yAxis: {
type: "value",
name: "",
nameGap: 0,
nameTextStyle: { color: "#fff", fontSize: 10 },
position: "top",
axisLabel: {
show: true,
textStyle: { color: "rgba(255,255,255,.6)", fontSize: "10" },
},
axisTick: { show: false },
axisLine: {
show: true,
lineStyle: {
color: "rgba(255,255,255,.9)",
width: 1,
type: "solid",
},
},
splitLine: { lineStyle: { color: "rgba(255,255,255,.1)" } },
},
series: arr,
};
myChart.setOption(option);
window.addEventListener("resize", function () {
myChart.resize();
});
}
},
});
}
function get_echart_trend3() {
var fenlei = "工资水平";
$.ajax({
type: "GET",
url: baseUrl + "/dataNew/getData13",
data: { fenlei: fenlei },
success: function (res) {
console.log(res);
if (res.code == "0") {
var arr = [];
for (var i = 0; i < res.data.keys.length; i++) {
var obj = {};
obj.data = res.data["qzlist" + i];
obj.type = "line";
obj.name = res.data.keys[i];
arr.push(obj);
}
for (var j = 0; j < res.data.keys.length; j++) {
var obj = {};
obj.data = res.data["xqlist" + j];
obj.type = "line";
obj.name = res.data.keys[j];
arr.push(obj);
}
var myChart = echarts.init(document.getElementById("echart_trend3"));
var option = {
tooltip: { trigger: "axis", axisPointer: { type: "shadow" } },
grid: {
left: "0",
top: "5%",
right: "5",
bottom: "0",
containLabel: true,
},
xAxis: {
nameLocation: "end",
nameGap: 7,
type: "category",
data: res.data.name,
axisLine: {
show: true,
lineStyle: {
color: "rgba(255,255,255,.9)",
width: 1,
type: "solid",
},
},
axisTick: { show: false },
axisLabel: {
interval: 0,
rotate: 0,
textStyle: { color: "rgba(255,255,255,.6)", fontSize: "10" },
},
},
yAxis: {
type: "value",
name: "",
nameGap: 0,
nameTextStyle: { color: "#fff", fontSize: 10 },
position: "top",
axisLabel: {
show: true,
textStyle: { color: "rgba(255,255,255,.6)", fontSize: "10" },
},
axisTick: { show: false },
axisLine: {
show: true,
lineStyle: {
color: "rgba(255,255,255,.9)",
width: 1,
type: "solid",
},
},
splitLine: { lineStyle: { color: "rgba(255,255,255,.1)" } },
},
series: arr,
};
myChart.setOption(option);
window.addEventListener("resize", function () {
myChart.resize();
});
}
},
});
}
function get_echart_trend4() {
var fenlei = "产业";
$.ajax({
type: "GET",
url: baseUrl + "/dataNew/getData13",
data: { fenlei: fenlei },
success: function (res) {
console.log(res);
if (res.code == "0") {
var arr = [];
for (var i = 0; i < res.data.keys.length; i++) {
var obj = {};
obj.data = res.data["qzlist" + i];
obj.type = "bar";
obj.name = res.data.keys[i];
arr.push(obj);
}
for (var j = 0; j < res.data.keys.length; j++) {
var obj = {};
obj.data = res.data["xqlist" + j];
obj.type = "bar";
obj.name = res.data.keys[j];
arr.push(obj);
}
var myChart = echarts.init(document.getElementById("echart_trend4"));
var option = {
tooltip: {
trigger: "axis",
axisPointer: { type: "shadow" },
position: [10, 0],
},
grid: {
left: "0",
top: "5%",
right: "5",
bottom: "0",
containLabel: true,
},
xAxis: {
nameLocation: "end",
nameGap: 7,
type: "category",
data: res.data.name,
axisLine: {
show: true,
lineStyle: {
color: "rgba(255,255,255,.9)",
width: 1,
type: "solid",
},
},
axisTick: { show: false },
axisLabel: {
interval: 0,
rotate: 0,
textStyle: { color: "rgba(255,255,255,.6)", fontSize: "10" },
},
},
yAxis: {
type: "value",
name: "",
nameGap: 0,
nameTextStyle: { color: "#fff", fontSize: 10 },
position: "top",
axisLabel: {
show: true,
textStyle: { color: "rgba(255,255,255,.6)", fontSize: "10" },
},
axisTick: { show: false },
axisLine: {
show: true,
lineStyle: {
color: "rgba(255,255,255,.9)",
width: 1,
type: "solid",
},
},
splitLine: { lineStyle: { color: "rgba(255,255,255,.1)" } },
},
series: arr,
};
myChart.setOption(option);
window.addEventListener("resize", function () {
myChart.resize();
});
}
},
});
}
function get_echart_trend5() {
var fenlei = "企业规模";
$.ajax({
type: "GET",
url: baseUrl + "/dataNew/getData13",
data: { fenlei: fenlei },
success: function (res) {
console.log(res);
if (res.code == "0") {
var arr = [];
for (var i = 0; i < res.data.keys.length; i++) {
var obj = {};
obj.data = res.data["qzlist" + i];
obj.type = "bar";
obj.name = res.data.keys[i];
arr.push(obj);
}
for (var j = 0; j < res.data.keys.length; j++) {
var obj = {};
obj.data = res.data["xqlist" + j];
obj.type = "bar";
obj.name = res.data.keys[j];
arr.push(obj);
}
var myChart = echarts.init(document.getElementById("echart_trend5"));
var option = {
tooltip: {
trigger: "axis",
axisPointer: { type: "shadow" },
position: [10, 0],
},
grid: {
left: "0",
top: "5%",
right: "5",
bottom: "0",
containLabel: true,
},
xAxis: {
nameLocation: "end",
nameGap: 7,
type: "category",
data: res.data.name,
axisLine: {
show: true,
lineStyle: {
color: "rgba(255,255,255,.9)",
width: 1,
type: "solid",
},
},
axisTick: { show: false },
axisLabel: {
interval: 0,
rotate: 0,
textStyle: { color: "rgba(255,255,255,.6)", fontSize: "10" },
},
},
yAxis: {
type: "value",
name: "",
nameGap: 0,
nameTextStyle: { color: "#fff", fontSize: 10 },
position: "top",
axisLabel: {
show: true,
textStyle: { color: "rgba(255,255,255,.6)", fontSize: "10" },
},
axisTick: { show: false },
axisLine: {
show: true,
lineStyle: {
color: "rgba(255,255,255,.9)",
width: 1,
type: "solid",
},
},
splitLine: { lineStyle: { color: "rgba(255,255,255,.1)" } },
},
series: arr,
};
myChart.setOption(option);
window.addEventListener("resize", function () {
myChart.resize();
});
}
},
});
}
function get_echart_trend6() {
var fenlei = "学历";
$.ajax({
type: "GET",
url: baseUrl + "/dataNew/getData13",
data: { fenlei: fenlei },
success: function (res) {
console.log(res);
if (res.code == "0") {
var arr = [];
for (var i = 0; i < res.data.keys.length; i++) {
var obj = {};
obj.data = res.data["qzlist" + i];
obj.type = "bar";
obj.name = res.data.keys[i];
arr.push(obj);
}
for (var j = 0; j < res.data.keys.length; j++) {
var obj = {};
obj.data = res.data["xqlist" + j];
obj.type = "bar";
obj.name = res.data.keys[j];
arr.push(obj);
}
var myChart = echarts.init(document.getElementById("echart_trend6"));
var option = {
tooltip: {
trigger: "axis",
axisPointer: { type: "shadow" },
position: [10, 0],
},
grid: {
left: "0",
top: "5%",
right: "5",
bottom: "0",
containLabel: true,
},
xAxis: {
nameLocation: "end",
nameGap: 7,
type: "category",
data: res.data.name,
axisLine: {
show: true,
lineStyle: {
color: "rgba(255,255,255,.9)",
width: 1,
type: "solid",
},
},
axisTick: { show: false },
axisLabel: {
interval: 0,
rotate: 0,
textStyle: { color: "rgba(255,255,255,.6)", fontSize: "10" },
},
},
yAxis: {
type: "value",
name: "",
nameGap: 0,
nameTextStyle: { color: "#fff", fontSize: 10 },
position: "top",
axisLabel: {
show: true,
textStyle: { color: "rgba(255,255,255,.6)", fontSize: "10" },
},
axisTick: { show: false },
axisLine: {
show: true,
lineStyle: {
color: "rgba(255,255,255,.9)",
width: 1,
type: "solid",
},
},
splitLine: { lineStyle: { color: "rgba(255,255,255,.1)" } },
},
series: arr,
};
myChart.setOption(option);
window.addEventListener("resize", function () {
myChart.resize();
});
}
},
});
}
function get_echart_trend7() {
var fenlei = "岗位类型";
$.ajax({
type: "GET",
url: baseUrl + "/dataNew/getData13",
data: { fenlei: fenlei },
success: function (res) {
console.log(res);
if (res.code == "0") {
var arr = [];
for (var i = 0; i < res.data.keys.length; i++) {
var obj = {};
obj.data = res.data["qzlist" + i];
obj.type = "bar";
obj.name = res.data.keys[i];
arr.push(obj);
}
for (var j = 0; j < res.data.keys.length; j++) {
var obj = {};
obj.data = res.data["xqlist" + j];
obj.type = "bar";
obj.name = res.data.keys[j];
arr.push(obj);
}
var myChart = echarts.init(document.getElementById("echart_trend7"));
var option = {
tooltip: { trigger: "axis", axisPointer: { type: "shadow" } },
grid: {
left: "0",
top: "5%",
right: "5",
bottom: "0",
containLabel: true,
},
xAxis: {
nameLocation: "end",
nameGap: 7,
type: "category",
data: res.data.name,
axisLine: {
show: true,
lineStyle: {
color: "rgba(255,255,255,.9)",
width: 1,
type: "solid",
},
},
axisTick: { show: false },
axisLabel: {
interval: 0,
rotate: 0,
textStyle: { color: "rgba(255,255,255,.6)", fontSize: "10" },
},
},
yAxis: {
type: "value",
name: "",
nameGap: 0,
nameTextStyle: { color: "#fff", fontSize: 10 },
position: "top",
axisLabel: {
show: true,
textStyle: { color: "rgba(255,255,255,.6)", fontSize: "10" },
},
axisTick: { show: false },
axisLine: {
show: true,
lineStyle: {
color: "rgba(255,255,255,.9)",
width: 1,
type: "solid",
},
},
splitLine: { lineStyle: { color: "rgba(255,255,255,.1)" } },
},
series: arr,
};
myChart.setOption(option);
window.addEventListener("resize", function () {
myChart.resize();
});
}
},
});
}
//提示框
function showDialog(content) {
var layer = document.createElement("div");
layer.id = "layer";
var style = {
background: "rgba(0,0,0,0.3)",
position: "absolute",
zIndex: 10,
width: "160px",
height: "40px",
lineHeight: "40px",
left: "50%",
top: "50%",
marginLeft: "-100px",
marginTop: "80px",
//padding: "4px 10px",
color: "#fff",
};
for (var i in style) {
layer.style[i] = style[i];
}
if (document.getElementById("layer") == null) {
document.body.appendChild(layer);
layer.innerHTML = content;
layer.style.textAlign = "center";
layer.style.lineHeight = "40px";
setTimeout("document.body.removeChild(layer)", 3000);
}
}