修改激活不灵活的问题

This commit is contained in:
lVAL 2020-10-16 13:57:33 +08:00
parent 3122c680e4
commit 58c7914e8b
4 changed files with 20 additions and 10 deletions

View File

@ -19,12 +19,16 @@ export default {
const opt = {
name: `run-${trip.tripNo}`,
type: 'line',
legendHoverLink: false,
symbolSize: 6,
symbolSize: 1,
showAllSymbol: true,
lineStyle: {
color: '#000',
width: 1,
},
},
itemStyle: {
color: '#000',
fill: '#000'
},
markPoint: { data: [] },
data: []
};

View File

@ -19,12 +19,16 @@ export default {
const opt = {
name: `run-${trip.tripNo}`,
type: 'line',
legendHoverLink: false,
symbolSize: 6,
symbolSize: 1,
showAllSymbol: true,
lineStyle: {
color: '#000',
color: '#000',
width: 1,
},
},
itemStyle: {
color: '#000',
fill: '#000'
},
markPoint: { data: [] },
data: []
};

View File

@ -78,6 +78,7 @@ export default {
zr.on('click', this.onClick, this)
this.myChart.on('mousedown', this.onMouseDown);
this.myChart.on('mouseover', this.onMouseOver);
this.myChart.on('mouseout', this.onMouseOver);
this.myChart.on('mouseup', this.onMouseUP);
this.myChart.on('datazoom', this.onUpdatePosition);
window.addEventListener('resize', this.onUpdatePosition);
@ -90,6 +91,7 @@ export default {
zr.off('click', this.onClick);
this.myChart.off('mousedown', this.onMouseDown);
this.myChart.off('mouseover', this.onMouseOver);
this.myChart.off('mouseout', this.onMouseOver);
this.myChart.off('mouseup', this.onMouseUP);
this.myChart.off('datazoom', this.onUpdatePosition);
window.removeEventListener('resize', this.onUpdatePosition);
@ -164,8 +166,8 @@ export default {
this.myChart.setOption({
series: {
name: this.selected.seriesName,
symbolSize: 6,
showAllSymbol: 'auto',
symbolSize: 1,
showAllSymbol: true,
lineStyle: {
width: 1,
color: '#000'

View File

@ -434,8 +434,8 @@ export default {
}
},
handleCancel() {
this.setLineReset();
this.clearGraphic(['drag', 'mark']);
this.setLineReset();
this.active = -1;
this.action = '';
this.selected = null;