From 4671ea996e111143cb3697e35496cab609ff8f3f Mon Sep 17 00:00:00 2001 From: fit2cloud-chenyw Date: Thu, 17 Feb 2022 18:39:44 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E5=85=BC=E5=AE=B9=E6=8F=92=E4=BB=B6?= =?UTF-8?q?=E8=A7=86=E5=9B=BE=E6=A0=B7=E5=BC=8F=E8=AE=BE=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- frontend/src/components/AsyncComponent/index.vue | 15 +++++++++++---- .../canvas/custom-component/UserView.vue | 9 ++++++++- frontend/src/views/chart/view/ChartEdit.vue | 12 +++++++++++- frontend/src/views/system/plugin/PluginCom.vue | 10 ++++++++-- 4 files changed, 38 insertions(+), 8 deletions(-) diff --git a/frontend/src/components/AsyncComponent/index.vue b/frontend/src/components/AsyncComponent/index.vue index 09dd19ef4c..67779ffafb 100644 --- a/frontend/src/components/AsyncComponent/index.vue +++ b/frontend/src/components/AsyncComponent/index.vue @@ -1,14 +1,15 @@ diff --git a/frontend/src/components/canvas/custom-component/UserView.vue b/frontend/src/components/canvas/custom-component/UserView.vue index 6162ddc46a..947e4d7d89 100644 --- a/frontend/src/components/canvas/custom-component/UserView.vue +++ b/frontend/src/components/canvas/custom-component/UserView.vue @@ -76,7 +76,7 @@ import ChartComponent from '@/views/chart/components/ChartComponent.vue' import TableNormal from '@/views/chart/components/table/TableNormal' import LabelNormal from '../../../views/chart/components/normal/LabelNormal' import { uuid } from 'vue-uuid' - +import bus from '@/utils/bus' import { mapState } from 'vuex' import { isChange } from '@/utils/conditionUtil' import { BASE_CHART_STRING } from '@/views/chart/chart/chart' @@ -164,6 +164,9 @@ export default { sourceCustomStyleStr: null } }, + mounted() { + this.bindPluginEvent() + }, computed: { scaleCoefficient() { if (this.terminal === 'pc' && !this.mobileLayoutStatus) { @@ -354,6 +357,10 @@ export default { } }, methods: { + bindPluginEvent() { + bus.$on('plugin-chart-click', this.chartClick) + bus.$on('plugin-jump-click', this.jumpClick) + }, // 根据仪表板的缩放比例,修改视图内部参数 mergeScale() { const scale = Math.min(this.previewCanvasScale.scalePointWidth, this.previewCanvasScale.scalePointHeight) * this.scaleCoefficient diff --git a/frontend/src/views/chart/view/ChartEdit.vue b/frontend/src/views/chart/view/ChartEdit.vue index 0d94a7d8e5..916aa15627 100644 --- a/frontend/src/views/chart/view/ChartEdit.vue +++ b/frontend/src/views/chart/view/ChartEdit.vue @@ -220,7 +220,7 @@ - +
@@ -591,7 +591,15 @@ +
@@ -1238,7 +1246,9 @@ export default { bus.$on('show-rename', this.showRename) bus.$on('show-quota-edit-filter', this.showQuotaEditFilter) bus.$on('show-quota-edit-compare', this.showQuotaEditCompare) + bus.$on('show-edit-filter', this.showEditFilter) bus.$on('calc-data', this.calcData) + bus.$on('plugins-calc-style', this.calcStyle) }, initTableData(id) { if (id != null) { diff --git a/frontend/src/views/system/plugin/PluginCom.vue b/frontend/src/views/system/plugin/PluginCom.vue index fc555d3ccc..040863b621 100644 --- a/frontend/src/views/system/plugin/PluginCom.vue +++ b/frontend/src/views/system/plugin/PluginCom.vue @@ -2,6 +2,7 @@