项目进度先显示以前的

This commit is contained in:
2024-10-18 19:16:41 +08:00
parent d6c3a6cd34
commit 9beb5e65dd
3 changed files with 207 additions and 6 deletions
+163 -5
View File
@@ -310,7 +310,8 @@
进度统计
</div>
<div class="main">
<div id="aq-map"></div>
<%-- <div id="aq-map"></div>--%>
<div id='left_one' style="width: 100%; height: 100%;"></div>
</div>
</div>
</div>
@@ -1204,7 +1205,7 @@
</script>
<script>
<%--<script>
function line(id, xArr, data) {
// 基于准备好的dom,初始化echarts实例
var myChart = echarts.init(document.getElementById(id))
@@ -1341,7 +1342,7 @@
line('left_one', xArr1, data1)
}
</script>
</script>--%>
<script>
function category(id, xArr, series) {
// 基于准备好的dom,初始化echarts实例
@@ -1598,7 +1599,7 @@
// 安全统计
createAQTJ()
<%-- createAQTJ()
function createAQTJ() {
var two =<%=Two %>;
console.log("安全统计", two)
@@ -1775,7 +1776,7 @@
};
var myEchart = echarts.init(document.getElementById('aq-map'));
myEchart.setOption(opt);
}
}--%>
// 质量概况
<%-- let weekData = [
@@ -2188,3 +2189,160 @@
}
</script>
<script type="text/javascript">
function line(id, xArr, data) {
// 基于准备好的dom,初始化echarts实例
var myChart = echarts.init(document.getElementById(id))
// 指定图表的配置项和数据
var option = {
title: {
left: 'center',
text: ' ',
textStyle: {
color: '#fff',
fontSize: 12,
fontWeight: '300'
},
show: false
},
tooltip: {
formatter: '{a}<br />{b}: {c}%'
},
legend: {
show: true,
textStyle: {
color: '#fff'
},
left: 0
},
xAxis: {
axisTick: {
show: false
},
axisLine: {
lineStyle: {
color: 'rgba(255, 255, 255, 0.3)'
}
},
axisLabel: {
show: true,
textStyle: {
color: 'rgba(255, 255, 255, 0.8)'
}
},
type: 'category',
data: xArr
},
yAxis: {
axisTick: {
show: false
},
axisLine: {
show: false,
lineStyle: {
color: 'rgba(255, 255, 255, 0.3)'
}
},
axisLabel: {
show: true,
textStyle: {
color: 'rgba(255, 255, 255, 0.8)'
},
formatter: '{value} %'
}
},
series: data,
grid: {
top: '15%',
left: '10',
right: '10',
bottom: '0%',
containLabel: true,
backgroundColor: 'rgba(0,162,233, 0.01)',
// borderColor: 'rgba(0,162,233, 1)'
},
itemStyle: {
//color: 'rgba(200,201,10, 1)'
//normal: {
// label: {
// show: false
// }
//}
},
backgroundColor: 'rgba(0,162,233, 0.01)',
textStyle: {
color: 'rgba(255, 255, 255, 0.3)'
}
}
// 使用刚指定的配置项和数据显示图表。
myChart.setOption(option)
}
//var two = { "title": "赢得值曲线", "xFontNum": 0, "legend": null, "categories": ["2020-07", "2020-08", "2020-09", "2020-10", "2020-11", "2020-12", "2021-01", "2021-02"], "series": [{ "name": null, "type": null, "data": [5.0, 2.0, 0.0, 1.0, 4.0, 8.0, 2.0, 3.0], "dataString": null, "dataObject": null }, { "name": null, "type": null, "data": [8.0, 12.0, 4.0, 9.0, 10.0, 2.0, 3.0, 3.0], "dataString": null, "dataObject": null }, { "name": null, "type": null, "data": [12.0, 2.0, 5.0, 10.0, 3.0, 3.0, 8.0, 10.0], "dataString": null, "dataObject": null }, { "name": null, "type": null, "data": [4.0, 3.0, 14.0, 8.0, 10.0, 3.0, 5.0, 10.0], "dataString": null, "dataObject": null }], "series2": null };
var two =<%=Tree %>
var xArr1 = two.categories
var data1 = [{
name: '计划值',
type: 'bar',
//smooth: true,
data: two.series[0].data,
label: { //柱体上显示数值
show: false,//开启显示
position: 'top',//在上方显示
textStyle: {//数值样式
fontSize: '20px',
color: '#fff'
},
formatter: '{c}',
},
lineStyle: {
//color: 'rgba(200,201,10, 1)'
}
}, {
name: '实际值',
type: 'bar',
//smooth: true,
data: two.series[2].data,
label: { //柱体上显示数值
show: false,//开启显示
position: 'top',//在上方显示
textStyle: {//数值样式
fontSize: '20px',
color: '#fff'
},
formatter: '{c}',
},
}, {
name: '累计计划值',
type: 'line',
//smooth: true,
data: two.series[1].data,
label: { //柱体上显示数值
show: false,//开启显示
position: 'top',//在上方显示
textStyle: {//数值样式
fontSize: '20px',
color: '#fff'
},
formatter: '{c}',
},
lineStyle: {
//color: 'rgba(200,201,10, 1)'
}
}, {
name: '累计实际值',
type: 'line',
//smooth: true,
data: two.series[3].data,
label: { //柱体上显示数值
show: false,//开启显示
position: 'top',//在上方显示
textStyle: {//数值样式
fontSize: '20px',
color: '#fff'
},
formatter: '{c}',
},
}]
line('left_one', xArr1, data1)
</script>