var myCharttineng = echarts.init(document.getElementById('tineng')); var myChartjineng = echarts.init(document.getElementById('jineng')); var myCharttime = echarts.init(document.getElementById('timescore')); $(function () { window.onresize = function () { myCharttineng.resize(); myChartjineng.resize(); myCharttime.resize(); }; }); var option_tinneg = { //backgroundColor: "#e9e9e9", title: { text: '{a|0}{c|%}', x: 'center', y: 'center', textStyle: { rich: { a: { fontSize: 18, color: '#ffffff' }, c: { fontSize: 18, color: '#ffffff', // padding: [5,0] } } } }, series: [{ name: '及格率', type: 'pie', radius: ['58%', '45%'], silent: true, clockwise: true, startAngle: 90, z: 0, zlevel: 0, label: { normal: { position: "center", } }, data: [{ value: 0, name: "", itemStyle: { normal: { color: { // 完成的圆环的颜色 colorStops: [{ offset: 0, color: '#4FADFD' // 0% 处的颜色 }, { offset: 1, color: '#28E8FA' // 100% 处的颜色 }] }, } } }, { value: 100 - 0, name: "", label: { normal: { show: false } }, itemStyle: { normal: { color: "#07233a" } } } ] } ] }; myCharttineng.setOption(option_tinneg) var option_jinneg = { //backgroundColor: "#e9e9e9", title: { text: '{a|0}{c|%}', x: 'center', y: 'center', textStyle: { rich: { a: { fontSize: 18, color: '#ffffff' }, c: { fontSize: 18, color: '#ffffff', // padding: [5,0] } } } }, series: [{ name: '及格率', type: 'pie', radius: ['58%', '45%'], silent: true, clockwise: true, startAngle: 90, z: 0, zlevel: 0, label: { normal: { position: "center", } }, data: [{ value: 0, name: "", itemStyle: { normal: { color: { // 完成的圆环的颜色 colorStops: [{ offset: 0, color: '#4FADFD' // 0% 处的颜色 }, { offset: 1, color: '#28E8FA' // 100% 处的颜色 }] }, } } }, { value: 100 - 0, name: "", label: { normal: { show: false } }, itemStyle: { normal: { color: "#07233a" } } } ] } ] }; myChartjineng.setOption(option_jinneg) var option_time = { //title: { // text: '近期训练成绩统计图', // textStyle: { // color: '#fff' // } //}, tooltip: { trigger: 'axis', }, legend: { data: [], trigger: 'axis', textStyle: { color: '#fff', } }, grid: { left: '3%', right: '4%', bottom: '3%', containLabel: true }, toolbox: { feature: { saveAsImage: {} } }, xAxis: { type: 'category', boundaryGap: false, axisLabel: { color: '#fff', }, data: ['1月', '2月', '3月', '4月', '5月', '6月', '7月', '8月', '9月', '10月', '11月', '12月'], axaxisLine: { lineStyle: { color: '#ffffff' } }, }, yAxis: { type: 'value', max: 100, axisLabel: { color: '#fff', }, axisLine: { lineStyle: { color: '#ffffff' } } }, series: [ ] }; myCharttime.setOption(option_time, true)