Merge pull request #1285 from dataease/pr@dev@fix_panel-edit

fix: 修复antV视图多事件弹框点击不显示问题
This commit is contained in:
王嘉豪 2021-11-26 12:10:40 +08:00 committed by GitHub
commit 13198c7c15
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 21 deletions

View File

@ -31,7 +31,10 @@ export default {
},
methods: {
trackButtonClick() {
this.$refs.trackButton.click()
const _this = this
setTimeout(() => {
_this.$refs.trackButton.click()
}, 50)
},
trackMenuClick(menu) {
this.$emit('trackClick', menu)

View File

@ -10,7 +10,6 @@
<script>
import { baseLiquid } from '@/views/chart/chart/liquid/liquid'
// import eventBus from '@/components/canvas/utils/eventBus'
import { uuid } from 'vue-uuid'
import ViewTrackBar from '@/components/canvas/components/Editor/ViewTrackBar'
import { hexColorToRGBA } from '@/views/chart/chart/util'
@ -183,15 +182,7 @@ export default {
if (this.antVRenderStatus) {
this.myChart.render()
}
// } else {
// if (this.myChart) {
// this.antVRenderStatus = false
// this.myChart.destroy()
// }
// }
this.setBackGroundBorder()
// console.log(JSON.stringify(chart_option))
},
antVAction(param) {
@ -205,20 +196,10 @@ export default {
this.trackClick(this.trackMenu[0])
} else { //
this.trackBarStyle.left = param.x + 'px'
this.trackBarStyle.top = (param.y - 15) + 'px'
this.trackBarStyle.top = (param.y + 10) + 'px'
this.$refs.viewTrack.trackButtonClick()
}
},
// myEcharts(option) {
// //
// const chart = this.myChart
// this.setBackGroundBorder()
// setTimeout(chart.setOption(option, true), 500)
// window.onresize = function() {
// chart.resize()
// }
// },
setBackGroundBorder() {
if (this.chart.customStyle) {
const customStyle = JSON.parse(this.chart.customStyle)