diff --git a/src/views/charts/Chart.vue b/src/views/charts/Chart.vue
index a735ac4b..4ff7b115 100644
--- a/src/views/charts/Chart.vue
+++ b/src/views/charts/Chart.vue
@@ -255,6 +255,7 @@
:time-filter="timeFilter"
:chart-info="chartInfo"
:query-params="queryParams"
+ @chartDetection="chartDetection"
v-else-if="isDetectionSecurity"
@getDetectionData="getDetectionData"
>
@@ -264,6 +265,7 @@
:time-filter="timeFilter"
:chart-info="chartInfo"
:query-params="queryParams"
+ @chartDetection="chartDetection"
v-else-if="isDetectionService"
@getDetectionData="getDetectionData"
>
@@ -381,6 +383,7 @@ export default {
},
data () {
return {
+ activeTab: ''
}
},
props: {
@@ -397,8 +400,7 @@ export default {
table: Object,
timeFilter: Object,
orderPieTable: String,
- tabHandleClickType: String,
- activeTab: Number
+ tabHandleClickType: String
},
computed: {
isNoData () {
@@ -451,6 +453,9 @@ export default {
},
query (params) {
this.$emit('query', params)
+ },
+ chartDetection(type) {
+ this.activeTab = type
}
},
setup (props) {
diff --git a/src/views/charts/PanelChart.vue b/src/views/charts/PanelChart.vue
index 3285964b..ddfd2a4a 100644
--- a/src/views/charts/PanelChart.vue
+++ b/src/views/charts/PanelChart.vue
@@ -36,7 +36,6 @@
:loading="loading"
:entity="entity"
:table="table"
- :active-tab="activeTab"
:is-fullscreen="isFullscreen"
:order-pie-table="orderPieTable"
:time-filter="timeFilter"
@@ -103,8 +102,7 @@ export default {
timeFilter: Object, // 时间范围
isFullscreen: Boolean,
panelLock: Boolean,
- entity: Object,
- activeTab: Number
+ entity: Object
},
data () {
return {
diff --git a/src/views/charts/PanelChartList.vue b/src/views/charts/PanelChartList.vue
index 2cb09371..245431d6 100644
--- a/src/views/charts/PanelChartList.vue
+++ b/src/views/charts/PanelChartList.vue
@@ -32,7 +32,6 @@
:chart-info="item"
:time-filter="timeFilter"
:entity="entity"
- :active-tab="activeTab"
@groupShow="groupShow"
@showFullscreen="showFullscreen"
>
@@ -57,7 +56,6 @@
:is-fullscreen="true"
:panelLock="panelLock"
:time-filter="timeFilter"
- :active-tab="activeTab"
@showFullscreen="showFullscreen"
>
@@ -86,7 +84,6 @@ export default {
panelLock: { type: Boolean, default: true },
isGroup: Boolean,
entity: Object,
- activeTab: Number,
dataList: Array // 看板中所有图表信息
},
data () {
diff --git a/src/views/charts/charts/ChartNoData.vue b/src/views/charts/charts/ChartNoData.vue
index 832dfd76..40806192 100644
--- a/src/views/charts/charts/ChartNoData.vue
+++ b/src/views/charts/charts/ChartNoData.vue
@@ -1,5 +1,5 @@
- No data
+ No data
diff --git a/src/views/charts/charts/chartDetectionSecurity.vue b/src/views/charts/charts/chartDetectionSecurity.vue
index 925c39b0..5e8e586d 100644
--- a/src/views/charts/charts/chartDetectionSecurity.vue
+++ b/src/views/charts/charts/chartDetectionSecurity.vue
@@ -79,6 +79,7 @@ export default {
}
},
mounted () {
+ this.$emit('chartDetection', this.chartInfo.type)
this.securityCount()
}
}
diff --git a/src/views/charts/charts/chartDetectionService.vue b/src/views/charts/charts/chartDetectionService.vue
index 5d8d4196..51422816 100644
--- a/src/views/charts/charts/chartDetectionService.vue
+++ b/src/views/charts/charts/chartDetectionService.vue
@@ -77,6 +77,7 @@ export default {
}
},
mounted () {
+ this.$emit('chartDetection', this.chartInfo.type)
this.securityCount()
}
}