error提示

This commit is contained in:
2023-05-30 14:33:51 +08:00
3 changed files with 470 additions and 463 deletions

View File

@@ -127,6 +127,180 @@ export default {
this.setEchart06()
},
methods: {
setEchart01 () {
let value = Number(this.finishRate1)
let title = '%'
let text = '完成率'
let option = {
title: [
{
text: '{a|' + value + '}{b|' + title + '}\n{c|' + text + '}',
x: 'center',
y: 'center',
textStyle: {
rich: {
a: {
fontSize: 26,
color: '#00D9FF',
fontFamily: 'SourceHanSansCN',
foontWeight: '700'
},
b: {
fontSize: 16,
color: '#ffffff',
fontFamily: 'SourceHanSansCN',
foontWeight: '700',
padding: [10, 0, 0, 3]
},
c: {
color: '#FFFFFF',
fontSize: 13,
fontWeight: '700',
fontFamily: 'SourceHanSansCN',
padding: [10, 0, 0, 0]
}
}
}
}
],
polar: {
radius: ['75%', '83%'],
center: ['50%', '50%']
},
angleAxis: {
max: 100,
show: false
},
radiusAxis: {
type: 'category',
show: true,
axisLabel: {
show: false
},
axisLine: {
show: false
},
axisTick: {
show: false
}
},
series: [
{name: '',
type: 'bar',
roundCap: true,
showBackground: true,
backgroundStyle: {
color: '#0a2543'
},
data: [value],
coordinateSystem: 'polar',
itemStyle: {
normal: {
color: '#00dfff'
}
}
}
]
}
let echart = document.getElementById('echart_d01')
// if (this.myCharts01 !== '') {
// this.myCharts01.dispose()
// }
if (echart !== null) {
this.myCharts01 = this.$echarts.init(echart)
this.myCharts01.setOption(option)
window.addEventListener('resize', () => {
this.myCharts01.resize()
})
}
},
setEchart02 () {
let value = Number(this.finishRate2)
let title = '%'
let text = '完成率'
let option = {
title: [
{
text: '{a|' + value + '}{b|' + title + '}\n{c|' + text + '}',
x: 'center',
y: 'center',
textStyle: {
rich: {
a: {
fontSize: 26,
color: '#00D9FF',
fontFamily: 'SourceHanSansCN',
foontWeight: '700'
},
b: {
fontSize: 16,
color: '#ffffff',
fontFamily: 'SourceHanSansCN',
foontWeight: '700',
padding: [10, 0, 0, 3]
},
c: {
color: '#FFFFFF',
fontSize: 13,
fontWeight: '700',
fontFamily: 'SourceHanSansCN',
padding: [10, 0, 0, 0]
}
}
}
}
],
polar: {
radius: ['75%', '83%'],
center: ['50%', '50%']
},
angleAxis: {
max: 100,
show: false
},
radiusAxis: {
type: 'category',
show: true,
axisLabel: {
show: false
},
axisLine: {
show: false
},
axisTick: {
show: false
}
},
series: [
{name: '',
type: 'bar',
roundCap: true,
showBackground: true,
backgroundStyle: {
color: '#0a2543'
},
data: [value],
coordinateSystem: 'polar',
itemStyle: {
normal: {
color: '#00dfff'
}
}
}
]
}
let echart = document.getElementById('echart_d02')
// if (this.myCharts02 !== '') {
// this.myCharts02.dispose()
// }
if (echart !== null) {
this.myCharts02 = this.$echarts.init(echart)
this.myCharts02.setOption(option)
window.addEventListener('resize', () => {
this.myCharts02.resize()
})
}
},
setEchart03 () {
let date = []
let data1 = []
@@ -171,8 +345,8 @@ export default {
textStyle: {
color: '#8FABBF',
fontSize: 16
},
rotate: 50
}
// rotate: 50
},
data: date
},
@@ -418,8 +592,8 @@ export default {
textStyle: {
color: '#8FABBF',
fontSize: 16
},
rotate: 50
}
// rotate: 50
},
data: date
},
@@ -736,180 +910,6 @@ export default {
window.addEventListener('resize', () => {
this.myCharts10.resize()
})
},
setEchart01 () {
let value = Number(this.finishRate1)
let title = '%'
let text = '完成率'
let option = {
title: [
{
text: '{a|' + value + '}{b|' + title + '}\n{c|' + text + '}',
x: 'center',
y: 'center',
textStyle: {
rich: {
a: {
fontSize: 26,
color: '#00D9FF',
fontFamily: 'SourceHanSansCN',
foontWeight: '700'
},
b: {
fontSize: 16,
color: '#ffffff',
fontFamily: 'SourceHanSansCN',
foontWeight: '700',
padding: [10, 0, 0, 3]
},
c: {
color: '#FFFFFF',
fontSize: 13,
fontWeight: '700',
fontFamily: 'SourceHanSansCN',
padding: [10, 0, 0, 0]
}
}
}
}
],
polar: {
radius: ['75%', '83%'],
center: ['50%', '50%']
},
angleAxis: {
max: 100,
show: false
},
radiusAxis: {
type: 'category',
show: true,
axisLabel: {
show: false
},
axisLine: {
show: false
},
axisTick: {
show: false
}
},
series: [
{name: '',
type: 'bar',
roundCap: true,
showBackground: true,
backgroundStyle: {
color: '#0a2543'
},
data: [value],
coordinateSystem: 'polar',
itemStyle: {
normal: {
color: '#00dfff'
}
}
}
]
}
let echart = document.getElementById('echart_d01')
// if (this.myCharts01 !== '') {
// this.myCharts01.dispose()
// }
if (echart !== null) {
this.myCharts01 = this.$echarts.init(echart)
this.myCharts01.setOption(option)
window.addEventListener('resize', () => {
this.myCharts01.resize()
})
}
},
setEchart02 () {
let value = Number(this.finishRate2)
let title = '%'
let text = '完成率'
let option = {
title: [
{
text: '{a|' + value + '}{b|' + title + '}\n{c|' + text + '}',
x: 'center',
y: 'center',
textStyle: {
rich: {
a: {
fontSize: 26,
color: '#00D9FF',
fontFamily: 'SourceHanSansCN',
foontWeight: '700'
},
b: {
fontSize: 16,
color: '#ffffff',
fontFamily: 'SourceHanSansCN',
foontWeight: '700',
padding: [10, 0, 0, 3]
},
c: {
color: '#FFFFFF',
fontSize: 13,
fontWeight: '700',
fontFamily: 'SourceHanSansCN',
padding: [10, 0, 0, 0]
}
}
}
}
],
polar: {
radius: ['75%', '83%'],
center: ['50%', '50%']
},
angleAxis: {
max: 100,
show: false
},
radiusAxis: {
type: 'category',
show: true,
axisLabel: {
show: false
},
axisLine: {
show: false
},
axisTick: {
show: false
}
},
series: [
{name: '',
type: 'bar',
roundCap: true,
showBackground: true,
backgroundStyle: {
color: '#0a2543'
},
data: [value],
coordinateSystem: 'polar',
itemStyle: {
normal: {
color: '#00dfff'
}
}
}
]
}
let echart = document.getElementById('echart_d02')
// if (this.myCharts02 !== '') {
// this.myCharts02.dispose()
// }
if (echart !== null) {
this.myCharts02 = this.$echarts.init(echart)
this.myCharts02.setOption(option)
window.addEventListener('resize', () => {
this.myCharts02.resize()
})
}
}
}
}