fix(图表): 修复柱线组合图联动跳转失效的问题

This commit is contained in:
ulleo 2024-06-14 15:40:22 +08:00
parent 47743296c8
commit c6db09dc61

View File

@ -416,15 +416,36 @@ const trackMenu = computed(() => {
if (!['multiplexing', 'viewDialog'].includes(showPosition.value)) {
let linkageCount = 0
let jumpCount = 0
chartData.value?.fields?.forEach(item => {
const sourceInfo = view.value.id + '#' + item.id
if (nowPanelTrackInfo.value[sourceInfo]) {
linkageCount++
}
if (nowPanelJumpInfo.value[sourceInfo]) {
jumpCount++
}
})
if (curView?.type?.includes('chart-mix')) {
chartData.value?.left?.fields?.forEach(item => {
const sourceInfo = view.value.id + '#' + item.id
if (nowPanelTrackInfo.value[sourceInfo]) {
linkageCount++
}
if (nowPanelJumpInfo.value[sourceInfo]) {
jumpCount++
}
})
chartData.value?.right?.fields?.forEach(item => {
const sourceInfo = view.value.id + '#' + item.id
if (nowPanelTrackInfo.value[sourceInfo]) {
linkageCount++
}
if (nowPanelJumpInfo.value[sourceInfo]) {
jumpCount++
}
})
} else {
chartData.value?.fields?.forEach(item => {
const sourceInfo = view.value.id + '#' + item.id
if (nowPanelTrackInfo.value[sourceInfo]) {
linkageCount++
}
if (nowPanelJumpInfo.value[sourceInfo]) {
jumpCount++
}
})
}
jumpCount &&
view.value?.jumpActive &&
(!mobileInPc.value || inMobile.value) &&