|
|
@@ -141,10 +141,10 @@ export default {
|
|
|
const end = item[1].splice(0, data[0].length)
|
|
|
sealingData[index] = [start, end]
|
|
|
})
|
|
|
- console.log('sealingData2', sealingData)
|
|
|
|
|
|
this[optionName] = {
|
|
|
tooltip: {
|
|
|
+ show: false,
|
|
|
trigger: 'item'
|
|
|
},
|
|
|
legend: {
|
|
|
@@ -195,8 +195,8 @@ export default {
|
|
|
right: '10%',
|
|
|
left: '5%',
|
|
|
height: '80%',
|
|
|
- top: optionName === 'option2' ? 0 : '50%',
|
|
|
- bottom: optionName === 'option2' ? '30%' : 0,
|
|
|
+ top: optionName === 'option2' ? '10%' : '50%',
|
|
|
+ bottom: optionName === 'option2' ? '0%' : 0,
|
|
|
containLabel: true
|
|
|
|
|
|
},
|
|
|
@@ -253,7 +253,7 @@ export default {
|
|
|
itemStyle: { // lenged文本
|
|
|
opacity: 1,
|
|
|
color: () => {
|
|
|
- return new echarts.graphic.LinearGradient(0, 0, 1, 0, [{
|
|
|
+ return new echarts.graphic.LinearGradient(0, 0, 1, 1, [{
|
|
|
offset: 0,
|
|
|
color: 'rgba(231, 73, 2, 0.30)' // 0% 处的颜色
|
|
|
}, {
|
|
|
@@ -266,10 +266,15 @@ export default {
|
|
|
show: true,
|
|
|
position: ['50%', -barWidth - 10],
|
|
|
fontSize: this.EchartfontSize(16),
|
|
|
- color: '#ffffff'
|
|
|
+ color: '#ffffff',
|
|
|
+ // formatter: (evt) => {
|
|
|
+ // console.log('evt', evt)
|
|
|
+ // }
|
|
|
+ formatter: (evt) => {
|
|
|
+ return data[0][0] > 0 ? evt.value : ' '
|
|
|
+ }
|
|
|
},
|
|
|
- data: data[0],
|
|
|
- show: false
|
|
|
+ data: data[0]
|
|
|
},
|
|
|
{ // gap
|
|
|
name: '',
|
|
|
@@ -304,7 +309,10 @@ export default {
|
|
|
show: true,
|
|
|
position: ['50%', -barWidth - 10],
|
|
|
fontSize: this.EchartfontSize(16),
|
|
|
- color: '#fffff'
|
|
|
+ color: '#fffff',
|
|
|
+ formatter: (evt) => {
|
|
|
+ return data[1][0] > 0 ? evt.value : ' '
|
|
|
+ }
|
|
|
},
|
|
|
data: data[1]
|
|
|
},
|
|
|
@@ -341,7 +349,10 @@ export default {
|
|
|
show: true,
|
|
|
position: ['50%', -barWidth - 10],
|
|
|
fontSize: this.EchartfontSize(16),
|
|
|
- color: '#fffff'
|
|
|
+ color: '#fffff',
|
|
|
+ formatter: (evt) => {
|
|
|
+ return data[2][0] > 0 ? evt.value : ' '
|
|
|
+ }
|
|
|
},
|
|
|
data: data[2]
|
|
|
},
|
|
|
@@ -371,7 +382,7 @@ export default {
|
|
|
color: 'rgba(237, 118, 101,.4)' // 0% 处的颜色
|
|
|
}, {
|
|
|
offset: 1,
|
|
|
- color: 'rgba(237, 118, 101, .8)' // 100% 处的颜色
|
|
|
+ color: 'rgba(237, 118, 101, .0)' // 100% 处的颜色
|
|
|
}], false)
|
|
|
}
|
|
|
},
|
|
|
@@ -545,7 +556,6 @@ export default {
|
|
|
// position: [-baseWidth - offsetWidth / this.EchartfontSize(10), -this.EchartfontSize(20)]
|
|
|
position: 'right',
|
|
|
formatter: (item) => {
|
|
|
- console.log('item', item)
|
|
|
if (optionName === 'option1') {
|
|
|
return xDataSum[1]
|
|
|
} else {
|