From 08b707d45b131a8af6aaf5548d905f8a6f9f2c45 Mon Sep 17 00:00:00 2001 From: renpy Date: Fri, 1 Sep 2023 18:14:28 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A4=84=E7=90=86station=E9=A1=B5=E9=9D=A2?= =?UTF-8?q?=E5=8A=A0=E8=BD=BD=E7=9A=84loading=E5=BC=B9=E7=AA=97=E5=88=87?= =?UTF-8?q?=E6=8D=A2=E8=B7=AF=E7=94=B1=E5=90=8E=E4=BE=9D=E6=97=A7=E6=98=BE?= =?UTF-8?q?=E7=A4=BA=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/stationOperation/index.vue | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-) diff --git a/src/views/stationOperation/index.vue b/src/views/stationOperation/index.vue index 7d0b611..bb41d50 100644 --- a/src/views/stationOperation/index.vue +++ b/src/views/stationOperation/index.vue @@ -180,6 +180,17 @@ export default { ScrollContainer, DataListItem }, + watch: { + "$route": { + handler:function(val,oldVal) { + if (val.name!=="station-operation") { + this.$message.destroy() + } + }, + deep:true, + immediate:true + } + }, data() { return { activeKey: '1', @@ -191,7 +202,7 @@ export default { followedDataList: [], // 关注 markerList: [], // 地图上标记点列表 markerList_clone: [], // 地图上标记点列表 - upDateStationList: [], // 地图上标记点列表 + upDateStationList: [], // 有效率列表(显示波纹) orgStationList: [], // 地图上标记点列表 markerType: 1, // 是否绘制地图上的圆 circleRadius: 0, @@ -254,13 +265,15 @@ export default { // 查询台站数据提供率及有效率 async getDataProvisionEfficiency(arr, str) { - if (str) { + if (str && this.$route.path=="/station-operation") { this.$message.loading({ content: 'Loading station data, please wait...', key, duration: 0 }) } getAction('/stationOperation/getDataProvisionEfficiency').then(res => { if (res.success) { this.$message.destroy() - str&&this.$message.success({ content: 'Loaded!', key, duration: 2 }) + if (str && this.$route.path == "/station-operation") { + this.$message.success({ content: 'Loaded!', key, duration: 2 }) + } res.result.forEach(item => { arr.forEach(el => { if (parseInt(item.id) == el.stationId&&el.stationType!="Nuclear Facility"&&el.stationType!="NRL") {